void EstimatorBase::printStoredMag() { printf("---------Printing mag data buffer------------\n"); for (int i = 0; i < OBS_BUFFER_LENGTH; i++) { printMag(&_mag_buffer[i]); } }
void loop() { printGyro(); // Print "G: gx, gy, gz" printAccel(); // Print "A: ax, ay, az" printMag(); // Print "M: mx, my, mz" // Print the heading and orientation for fun! // Call print attitude. The LSM9DS1's magnetometer x and y // axes are opposite to the accelerometer, so my and mx are // substituted for each other. printAttitude(imu.ax, imu.ay, imu.az, -imu.my, -imu.mx, imu.mz); Serial.println(); delay(PRINT_SPEED); }