Hi, I am using the calibrating sample code for the miniIMU-9 v3 (lsm303, L3GD20H) and got the value as follow.
min: { -2790, -2730, -3857} max: { +2864, +2344, +1722}.
Am getting int, float values, is there anyway to reduce the gain value?
I got this error message when compiling.
C:\Users\Roblox Click Here\Downloads\headtracking-from-kris-master\headtracking-from-kris-master\headtracking-from-kris\headtracking-from-kris.ino:108:40: error: cannot convert ‘int*’ to ‘float*’ for argument ‘1’ to ‘void Smoothing(float*, float*)’
A simple way to get your code to compile should be to use some intermediate float variables that you can pass (with pointers) to the Smoothing() function:
Was that program written by someone else? If so, I recommend that you try to contact the author about what version of the LSM303 library it was written for and how the calibration values were obtained. Note that versions of the library before 2.0.0 scaled the magnetometer output differently; it is basically smaller by a factor of 16, so if you are using a newer version of the library, you could try dividing all your magnetometer readings by 16.