This example polls the chip and waits until new data is available before reading the magnetic field.
#include <iostream>
#include <chrono>
#include <thread>
#include "mag3110.hpp"
int main(int argc, char** argv)
{
cout << "DR_OS: " << static_cast<int>(dros) << endl;
cout << "Delay: " << delay << " ms" << endl;
int bx, by, bz;
while (true) {
}
return 0;
}