AppMEMS#5b: The X-CUBE-MEMS1 libraries in detail - MotionAC functions
--- More detail on MotionAC library ---
The library acquires data from the accelerometer and calculates the offset and scale factor coefficients together with the calibration quality value. Calibration can be done in two ways: dynamic calibration and 6-point calibration. The offset and scale factor coefficients are then used to compensate raw data coming from accelerometer. In particular, it features:
- offset compensation up to 0.2 g;
- scale factor compensation, in range from 0.8 to 1.2 in every direction;
- update frequency from 20 to 100 Hz.
The central function that performs the calibration is this one:
void MotionAC_Update (MAC_input_t *data_in, uint8_t *is_calibrated)
*data_in parameter is a pointer to a structure with input data + timestamp, while *is_calibrated parameter is a pointer to a value which returns 1 if calibration is done.
See below the detailed calibration process to make your app with the MotionAC effective! �?�
