Calibrate the Arduino 101 to be initially vertical rather than horizontal

Hi all,

I’m thinking of mounting the Arduino board vertically while using the IMU, is there a way of changing the auto-calibration to work vertically instead of the default horizontal? I’ve attached an image to clarify what “vertical” is.

Cheers!

If you need to start the board and calibrate in that position change:

CurieIMU.autoCalibrateAccelerometerOffset(X_AXIS, 0); CurieIMU.autoCalibrateAccelerometerOffset(Y_AXIS, 0); CurieIMU.autoCalibrateAccelerometerOffset(Z_AXIS, 1);

As seen in RawImuDataSerial calibration, to:

CurieIMU.autoCalibrateAccelerometerOffset(X_AXIS, -1); CurieIMU.autoCalibrateAccelerometerOffset(Y_AXIS, 0); CurieIMU.autoCalibrateAccelerometerOffset(Z_AXIS, 0);

You can figure out any other position by: -Running the RawImuDataSerial sketch and calibrating with the board in the "normal" flat on a table, face up position. -Now turn your board so that it is in the position that you want to start and calibrate it in in future. -if you see -16xxx on an axis, you need to set the calibration target for that axis to be -1. -if you see +16xxx on an axis, you need to set the calibration target for that axis to be 1. -if you see ~0 on an axis, set that axis calibration target to be zero. -for any other position where you deal with angles other than multiples of 90degrees ... you need to set maybe 0.33 on one axis, 0.66 on another... I haven't tried that to be honest.