2021-04-07 05:56 AM
Hi,
I've been trying to get the calibration values for my gyroscope using MotionGC library. I'm using the sample code available in the MotionGC starter guide but the said function return all the output values as 0. The bias_update variable is also set to 0, meaning that the sensor isn't stable, or so the guide says.
However, I'm being very careful to hold the sensor at a given position and not move it throughout the measurements.
What might be the cause of this issue?
Thanks in advance.
Kind regards,
Pedro Machado
2021-04-14 10:44 AM
Hi Pedro,
I'm not sure if it's going to solve your problem but maybe you can try to follow the settings we use in Gyroscope Calibration sample application for LSM6DSO sensor:
knobs.AccThr = 0.008f
knobs.GyroThr = 0.15f
freq = sample_freq = ACC_ODR = GYR_ODR = 50
ACC_FS = 4
GYR_FS = 2000
Regards,
Petr
2021-04-16 03:27 AM
Hi, Petr,
Thanks for the suggestions.
The output data rate that you sugested is not available for the LSM9DS1, since it only works with the gyroscope turned off, as you can see below from the drivers:
I did set to 59.5Hz since it is the closest data rate available for both accelerometer and magnetometer. I set the remaining values to the ones you indicated. Still, the issue persists and I don't really think it is because of the data rate.
2021-04-19 08:15 AM
I just remembered that there were some minor changes I had to make to the example available in the MotionGC user manual (UM2181) in order to compile it. Apparently, the arguments for some functions are indeed pointers to the variables, instead the variables themselves, as it is in the user manual, which indicates that there were changes in the libraries that were not updated to this manual. The function MotionGC_SetFrequency is a good example.
Because of this, I'm afraid that there might be something else missing in the manual that results in this issue. Is there an updated version?
2021-04-21 01:04 AM
I don't think it's related to ODR either. If you also tried the thresholds in knobs and full-scale I recommended and it didn't help, you can try to store about 10-20 seconds datalog file including timestamp and send to me. I'll try to replicate the calibration with your data on my side. Anyway if the bias_update variable is always 0 it seems your sensor is not stable enough, as you already stated. It would be nice if you would be able to try another sensor, some newer model like LSM6DSO or similar.
2021-04-21 06:20 AM
Hi, Petr,
I also tried on a different LSM9DS1 IMU to check if the previous was broken. The results were the same.
Unfortunately, I have no newer model available. Also, as I am testing in a custom designed board, I imagine it would be difficult to replace the IMU for a different model like the LSM6DSO because it should be unlikelly that the pins and eventually the PCB layout would match.
About the data logging: would you recommend a specific way to do it, or just the data (and which values)?
2021-04-28 12:52 AM
2021-05-03 05:51 AM
2021-05-05 01:48 AM
Unfortunately your datalog doesn't contain accelerometer data which are necesary for calibration too. Please update the datalog.
2021-05-06 07:05 AM
2021-05-10 01:32 AM