Bosch Sensortec Community

    Showing results for 
    Search instead for 
    Did you mean: 

    BMI088 giving wrong accelerometer RAW data?

    BMI088 giving wrong accelerometer RAW data?


    Hi everyone,

    I am facing some issues regarding BMI088. X-axis of the accelerometer is giving wrong RAW data. The sensor doesn't properly increments the accelerometer values while increasing the angle. When in positive axis, the sensor also gives negative values at some point due to which I get error in calculating the angles. At 3g configuration, this error is small but in 12g configuration  error is very much noticeable. Attached is the file with some of the readings. Any solution for my problem?


    8 REPLIES 8

    Hi ZeeshanAziz,

    I could not open this file as I do not have Matlab on my PC. But from your description the issue is not likely to come from the sensor, but rather from your test setup.

    The accelerometer responds the the physical input. There may be some misalignment between your reference measurement and the actual sensor position

    I am using matlab just for getting the data and plotting that data. I am doing all the calculations on STM32 Discovery board. I am also using complementary filter and the formula that I am using for calculation roll and pitch is "atan2(ACC_z, ACC_x)" and "atan2(sqrt(ACC_z*ACC_z + ACC_x*ACC_x),-ACC_y)" respectively. Now I have also attached the excel file. Major error can be seen on 3, 4 and 5 degree in 12g configuration as instead of 3, 4 or 5 degree I am getting  356, 357, 358 or 359 degrees.

    What I am suspecting is that the accelerometer values given by sensor are not correct. If this is the problem then can my sensor be damaged or faulty? 

    Your data looks very suspicious to me. In the "3g" datalog, the values between -0.0102539 and 0.0100708 never appear. In LSB, this would mean a "gap" of over 2000LSBs where you never get those values.

    I just tested with a BMI088 shuttleboard and could not reproduce your issue, I would recommend that you investigate closely how you read the data and convert it to floating point values.

    For future support, please make sure that your datalog is directly in LSB format, to eliminate the possibility of the conversion being the problem.

    Thanks a lot. Found problem in the conversion of the data from the sensor. Was using signed short int, which was causing the problem. I changed it to signed int and it solved my problem. Thanks for the help.   ^_^