21 0 4 14 255 232 0
22 8 0 72 255 252 255
23 228 255 232 255 252 0
24 32 0 8 255 200 255
25 224 0 32 0 12 255
26 212 255 244 255 252 255
27 248 0 16 0 0 255
28 240 0 44 0 12 0
29 16 255 200 255 220 0
30 8 0 44 255 220 255
31 248 0 16 255 228 0
If I then convert this to g values for X ,Y, and Z, I see the following for that same data:
0 -0.00, 0.00, -0.01
1 0.00, 0.00, -0.01
2 -0.00, -0.00, -0.01
3 -0.00, -0.00, -0.00
4 0.00, -0.00, 0.00
5 -0.00, -0.00, -0.00
6 -0.00, -0.00, 0.00
7 -0.00, 0.00, 0.00
8 0.00, 0.00, -0.00
9 -0.00, -0.00, 0.00
10 0.00, 0.00, -0.00
11 0.00, -0.00, 0.01
12 -0.00, -0.00, -0.00
13 -0.00, 0.00, -0.00
14 0.00, 0.00, -0.00
15 -0.00, -0.00, -0.01
16 -0.00, -0.00, 0.00
17 0.00, 0.00, 0.00
18 0.00, 0.00, -0.00
19 0.00, -0.00, 0.00
20 -0.00, 0.00, -0.01
21 0.00, 0.47, -0.75
22 0.25, 2.28, -0.09
23 -0.84, -0.72, -0.12
24 1.00, 0.28, -1.72
25 -1.00, 1.00, 0.41
26 -1.34, -0.34, -0.09
27 -0.25, 0.50, 0.03
28 -0.50, 1.38, 0.38
29 0.53, -1.72, -1.12
30 0.25, 1.41, -1.09
31 -0.25, 0.53, -0.88
Now here, we see zero g on all three axes (whereas we should see ~1g on the z-axis) until we get to the 21st event and then the data goes all over the place.
I can only conclude that the method I am using to read the FIFO is incorrect. Can anyone see the error in my method and share some pointers with me?
Thank you!