Skip to main content
Graduate
July 28, 2021
Solved

Gyroscope sensitivity scale factor

  • July 28, 2021
  • 4 replies
  • 3896 views

Hi,

Let me know ,how to calculate the sensitivity scale factor of gyroscope sensor l3gd20 ?

From the example code I found that

#define L3G_Sensitivity_250dps  (float)114.285f    /*!< gyroscope sensitivity with 250 dps full scale [LSB/dps] */

#define L3G_Sensitivity_500dps  (float)57.1429f    /*!< gyroscope sensitivity with 500 dps full scale [LSB/dps] */

#define L3G_Sensitivity_2000dps  (float)14.285f     /*!< gyroscope sensitivity with 2000 dps full scale [LSB/dps] */

So how these sensitiivity values are obtained(i.e 114.285,57.1429 & 14.285) .

Kindly inform me.

Board - stm32f401 discovery.

Keil Ide.

Regards

Satyabrata Senapati

    This topic has been closed for replies.
    Best answer by TBomb.1

    Hi, they are just the inverse of the datasheet sensitivities:

    sensitivity 8.75 milli dps/ LSB --> 1/sensitivity = 114.285 LSB/dps

    sensitivity 17.50 milli dps/ LSB --> 1/sensitivity = 57.1429 LSB/dps

    sensitivity 70 milli dps/ LSB --> 1/sensitivity = 14.285 LSB/dps

    so you'll probably have in your code something like ROT=(1/SENSITIVITY)* (out_h*256+out_l)

    Tom

    4 replies

    Visitor II
    July 28, 2021

    Hi, sensitivities should be reported in the device datasheet, in the Mechanical characteristics table.

    https://www.st.com/resource/en/datasheet/l3gd20.pdf

    You can also check on Github In ST standard C MEMS drivers for l3gd20 --> l3gd20h_reg.c

    The conversion formulas from LSB to dps are here reported:

    float_t l3gd20h_from_fs245_to_mdps(int16_t lsb)
    {
     return ((float_t)lsb * 8.75f);
    }
     
    float_t l3gd20h_from_fs500_to_mdps(int16_t lsb)
    {
     return ((float_t)lsb * 17.50f);
    }
     
    float_t l3gd20h_from_fs2000_to_mdps(int16_t lsb)
    {
     return ((float_t)lsb * 70.0f);
    }

    Tom

    Graduate
    July 29, 2021

    Thanks .

    As per your information I got ​the sensitivity from datasheet as 250dps = 8.75,500dps = 17.50 and 2000dps = 70 and unit is mdps/digit.

    B​ut you can see these values are different than those define values which are mentioned in the example code.

    So could you clarify please?

    TBomb.1Answer
    Visitor II
    July 30, 2021

    Hi, they are just the inverse of the datasheet sensitivities:

    sensitivity 8.75 milli dps/ LSB --> 1/sensitivity = 114.285 LSB/dps

    sensitivity 17.50 milli dps/ LSB --> 1/sensitivity = 57.1429 LSB/dps

    sensitivity 70 milli dps/ LSB --> 1/sensitivity = 14.285 LSB/dps

    so you'll probably have in your code something like ROT=(1/SENSITIVITY)* (out_h*256+out_l)

    Tom

    Graduate
    August 2, 2021

    Ohh ok thanks for the information.