Sampling rate for FXOS8700 in linux using evdev events

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

Sampling rate for FXOS8700 in linux using evdev events

892 Views
cheperuiz24
Contributor I

When I access the inputs generated by the driver for the accelerometer I can only get less than 10 samples per second. Is there a way to sample faster than that through this method or do I need to access the device directly using the i2c bus? The platform is i.MX6QP.

Thanks!

Labels (3)
0 Kudos
2 Replies

731 Views
lisettelozano
NXP Employee
NXP Employee

Hello Jose,

You can access the device through I2C in order to change the Output Data Rate “ODR” (register CTRL_REG1) from 1.563 Hz to 800 Hz for each sensor or up to 400 Hz when in hybrid mode (both sensors active). Another way to improve the resolution of the data is through oversampling ”OSR” (register CTRL_REG2); the oversampling settings allow the end user to optimize the resolution versus power trade-off in a given application. More details can be found in the datasheet.

You may find useful the following application notes as well:

https://www.nxp.com/docs/en/application-note/AN4076.pdf

https://www.nxp.com/docs/en/application-note/AN4075.pdf

Have a great day,

Paulina

0 Kudos

731 Views
cheperuiz24
Contributor I

Thank you! I’ll try that…

0 Kudos