Digital Accelerometer SPI LabView Programming

We are trying to do some off-season experimenting with sensors, namely accelerometers and gyroscopes. However, we are having difficulty figuring out how to program the digital accelerometer in LabView. We have searched for examples and tutorials to no avail. It would be very helpful if someone could either explain how to do this with the SPI Vi’s or include a program, screenshot or link.

Thanks!

I no longer have last year’s examples installed, but I can tell you that there is one for 2015. I suspect that you can get most of the info from the data sheet, but it will certainly give a boost if there is an example. If there is one, it will be in ProgFiles/NationalInst/LabVIEW2013/examples/FRC/SPI.

If you don’t find one and need details, I can screenshot, or perhaps a beta team can. I’m not sure if the beta team agreement details.

Greg McKaskle

If possible, a screenshot would a great, thanks.

In LabVIEW, from the Getting Started window.

  1. Click on “Support” on the left side

  2. Click on “Find FRC Examples…”

  3. Open the “Sensors” folder by double-clicking on it

  4. Open the ADXL345 SPI Accelerometer.lvproj
    That’s your example code.
    To run the example

  5. Right-click on "RT CompactRIO Target (10.0.0.2) and choose “Properties”

  6. Change the default IP address to your team IP (10.36.54.2) and save
    *]Run from ADXL345 SPI Accelerometer.vi or build and run as startup
    All the code you’ll need to add to your project is under the ADXL345 SPI Driver folder in the example project.