2024-04-24 12:02 AM
Hello STM32 community,
I'm relatively new to STM32 development and I'm currently working with the I3G4250D Gyro Sensor on the STM32F411e-Discovery board. I've been using the stm32f411e_discovery_gyroscope.c file provided by STM32Cube to interface with the sensor.
I've managed to retrieve data from the sensor using the provided code snippet:
BSP_GYRO_GetXYZ(Buffer2);
Xval = Buffer2[0];
Yval = Buffer2[1];
Zval = Buffer2[2];
However, the output I'm getting seems to be raw data, and I'm not quite sure how to interpret it correctly. My understanding is that these values represent the raw sensor readings, but I'm unsure how to convert them into meaningful X, Y, and Z values.
Could someone please provide guidance on how to properly interpret and convert these raw values into meaningful data? Additionally, if there are any specific calibration steps or formulas that need to be applied to obtain accurate results, I would greatly appreciate any insights on that as well.
Thank you in advance for your help!
2024-05-02 01:17 AM
Hi @Duc ,
To have data in mdps you need to multiply the raw data in LSB by the sensitivity reported in the datasheet according to your FS setting:
In addition, you could also look at our PID examples.