Skip to main content
ADvor.2
Associate
Question

Lsm6dso : how to get accelerometer data in FIFO

I'm working with lsm6dso for activity monitoring project. I want to record the acc and gyro data in the fifo and trigger an interrupt when the number of samples in fifo are more than the configured watermark. I already achieved to get the gyro data in the fifo and trigger the interrupt when the number of samples equals the watermark.

​

My problem is that I only get gyroscope data and no acc data. Do I have to write to a special register in order to enable the acc? I apreciate any help regarding the topic how to get acc running in fifo mode.

​

Best regards ​

This topic has been closed for replies.

4 replies

Eleon BORLINI
ST Employee

Hi @ADvor.2​ ,

did you correctly configured both the ODRs of the axl and the gyro?

You might also compare your code with the example on Github --> lsm6dso_fifo.c

-Eleon

ADvor.2
ADvor.2Author
Associate

Yes, I already checked the fifo example in fifo. The code I'm using is based on it and the register are setted as in the example

SS13
Associate III

Another thing to check is that the Batching Data Rate in FIFO_CTRL3 is set for XL.

ADvor.2
ADvor.2Author
Associate

Setting or not setting the batching data rate in fifo_ctr3 didnt affect at all.