Skip to main content
Associate
April 22, 2024
Question

Spikes in the LIS2DH12 accelerometer raw data

  • April 22, 2024
  • 3 replies
  • 1831 views

Spikes are present in the data coming from the LIS2DH12 accelerometer when placed in a casing, but when it is in the open there are no spikes. Attached is an image of the 3 axis data plotted from the accelerometer when placed on the table with casing and rotated. I have also added another plot of the same device on air (no movements). Please advice how to mitigate this issue. Thanks.

 

Axis_Plot_closed_and_zreversed.png

 

Axis_Plot_in_air.png

 

This topic has been closed for replies.

3 replies

Federica Bossi
Technical Moderator
April 24, 2024

Hi @soundarya1 ,

Welcome to ST Community!

Can you give us more details about your casing? Is it possible that it is in contact directly with the top of the LIS2DW12?

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Associate
April 25, 2024

Hello @Federica Bossi,

The casing/enclosure has no direct contact with LIS2DW12. It only encompases the entire device. There is nothing else placed above LIS2DW12. 

 

Associate
April 25, 2024

Also, the casing is ABS casing, there is 5mm+ of space present between the casing and LIS2DW12. 

Federica Bossi
Technical Moderator
May 2, 2024

Hi @soundarya1 ,

When you put the LIS2DH12 in the casing and it doesn't rotate, what do you see? can you share a graph?

In addition, can you write me your settings? ODR, FS, BDU...

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Lead II
May 2, 2024

Could be vibration. Have you rotated at different speeds? What is the spectrum of the spikes? Perhaps the enclosure has a certain resonance frequency that causes issues.

Also the data looks like it's a modulo of the real data. It overflows/wraps around. You can see that around t=1250 the x and y values slowly cross the boundary and then wrap around. If you remove the overflows from the data does it still have spikes? Or is it bouncing around 0.0/0.8?

Can you attach a csv file of the raw data? (integer not floating point)

"Kudo posts if you have the same problem and kudo replies if the solution works.Click ""Accept as Solution"" if a reply solved your problem. If no solution was posted please answer with your own."