On Wed, Jul 5, 2017 at 9:37 AM, Beagle Boner <[email protected]> wrote: > Hi, > > I´m using a BBB, rev C, running debian 8 (4.4.54) > > My goal is to write a little c/c++ programm that will log the data from an > accelerometer (nxp mma8451). Since I am still a beginner with Embedded Linux > and programming hardware I have some issues understanding what are the > necessary steps for this. > > My situation: > > I got the sensor running on the I²C bus. All registers of the sensor are > readable/writetable with i2c-tools. > But what are the next steps? > There is a Linux driver written in C available for the MMA8x5x series. > http://www.nxp.com/webapp/sps/download/license.jsp?colCode=MMA8X5X-DRVR > Readme file doesn´t really help me. How do I install that driver? > What I have to include into my programm then to use the functions of the > driver? > > Any hints?
use the mainline iio driver: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/tree/drivers/iio/accel/mma8452.c?h=v4.9.36 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/tree/Documentation/devicetree/bindings/iio/accel/mma8452.txt?h=v4.9.36 Regards, -- Robert Nelson https://rcn-ee.com/ -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/CAOCHtYiRPe%2BboF%2B995bUsxQZiCDosm6RBE7YOyLTpLma9cEBfA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
