Skip to main content
Visitor II
May 15, 2025
Solved

LSM6DSV80x SLFP game rotation vector, and timestamp to fifo

  • May 15, 2025
  • 2 replies
  • 548 views

Hi there, 

I'm trying to program LSM6DSV80x to read sensor values in -500Hz for a certain period of time and send them for process (thus no realtime process, but need timestamps).  The sensor values include xl, hg_xl, gyro, and also Game rotation vector, gravity calculated by SFLP.  According to the use case, all values will be read through FIFO.  Mostly works well but I've come up with two questions.  

- What timestamp means? Is it time of the latest FIFO entry,  or of the next FIFO entry, or irrelevant with other entries?

- for game rotation vector, I got two consequtive entries having TAG=19 in FIFO everytime,  at the same timing.  Those two entries have completely different values. With the application note and the post in this forum, I understand the FIFO  entry for game rotation vector hold only x, y, z elements and w needs to be calculated at the host side.  For example (the order is, w - which I calculate, x, y, z):

LSM6DSV80X_SFLP_GAME_ROTATION_VECTOR_TAG game_rotation_mg: 0.81 0.00 -0.09 -0.32
LSM6DSV80X_SFLP_GAME_ROTATION_VECTOR_TAG game_rotation_mg: 0.24 0.00 0.31 0.89

How can I interpret these values?

Any comments are appreciated!

    This topic has been closed for replies.
    Best answer by casadeib

    Hi @jose365ww

     

    -As for the Timestamp doubt, it represents the timestamp of the right after FIFO DATA.

    -As for the game rotation vector, please refer to the AN6281 paragraph 8.6.3, in order to better understand the content of each FIFO register for both the TAG_SENSOR = 0x13. The first represents the first word in Table 90, and the second TAG 0x13 represents the secondo word in Table 91

    casadeib_0-1747402128244.png

     

     

    2 replies

    casadeibAnswer
    ST Employee
    May 16, 2025

    Hi @jose365ww

     

    -As for the Timestamp doubt, it represents the timestamp of the right after FIFO DATA.

    -As for the game rotation vector, please refer to the AN6281 paragraph 8.6.3, in order to better understand the content of each FIFO register for both the TAG_SENSOR = 0x13. The first represents the first word in Table 90, and the second TAG 0x13 represents the secondo word in Table 91

    casadeib_0-1747402128244.png

     

     

    jose365wwAuthor
    Visitor II
    May 17, 2025

    Thanks for your help, @casadeib !

    I thought I read through AN6281 but missed this description.