MMA8451Q FIFO xyz data order

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MMA8451Q FIFO xyz data order

804 Views
warwickgraham
Contributor I

Has anyone else seen data read from the MMA8451Q FIFO in Y-Z-X order, instead of as XYZ as normal?

I have written some functions to use I2C to configure initial settings for 8/14 bit data, ODR, HPF, Range etc. All of which seem to be OK.

Recently I added i2c 'burst' reading to do FIFO access, which also seems good.

However, a couple of days ago I was testing reading from the FIFO & changing the data size from 14-bits to 8-bits. I cannot say if I did anything to

trigger the change, but I noticed the pattern of FIFO data being read had changed from 0, 0, -1024  into 0, -1024, 0 [my device was completely stationary].

This ordering continued for subsequent FIFO reads.  It only happened once & has not been reproduced.

Two ideas I had:

1. I2C burst reading had failed somehow in the sequence after reading X, but before Y & Z.  So the next fifo byte available would be Y.

  BUT, I expect the FIFO would correct itself from this situation for the next i2c command.

2. When changing between 8 & 14 bit modes I put the mma8451q in Standby but did not disable the FIFO (my Bad).

  Do you think this mistake could be the cause?

Any comments or assistance would be greatly appreciated.

Cheers,

W

Labels (1)
Tags (3)
0 Kudos
1 Reply

555 Views
bryce
NXP Employee
NXP Employee

As you suggested, it sounds like it may be the auto-increment issue, but we have not seen this behavior specifically.  If you are still having the problem, take a look at the following app note:

http://cache.freescale.com/files/sensors/doc/app_note/AN4073.pdf

At the bottom of page 9 you can see a brief description of the way data is auto-incremented so it may be worth checking against this description.

0 Kudos