XDIMAX has provided a LabVIEW VI (SUB-20 SPI read-write.vi) for SPI communication and I am working on using it with the SUB-20 together with an IC (acc/gyro, LSM330DL) using SPI. Eventually, I want to use the IC to develop some algorithm using LabVIEW. There are certain issues that I need help to achieve my goal. I am breaking my goal down to some smaller tasks:
1. Configure SUB-20 to give command and to read data from the 3 axis accelerometer
2. Configure SUB-20 to give command and to read data from the 3 axis gyroscope
3. Configure SUB-20 to give command and to read data from the 3 axis accelerometer and 3 axis gyroscope
4. Stream all above 6 axis data set to LabVIEW for data processing/algorithm development
The list of the 8-bit registers embedded in the device for the gyro and the acc. (they have a different CS) and the respective address:
OUT_X_L_A 0x28
OUT_X_H_A 0x29
OUT_Y_L_A 0x2A
OUT_Y_H_A 0x2B
OUT_Z_L_A 0x2C
OUT_Z_H_A 0x2D
I am having difficulties using the VI. Would you how to use the vi or to modify it to achieve my objectives?
using SUB-20 SPI read-write.vi
Moderator: serg
Re: using SUB-20 SPI read-write.vi
Hi acc-gyro,
Before developing your vi in LabView I would suggest to use our GUI application - subtool, to communicate with your LSM330DL device, i.e
- Configure SPI (or I2C), SS polarity, clock edge, clock rate etc. See the datasheet for the LSM330DL
- Read registers from the device, check if reading is reliable. Then go ahead and develop your vi.
By the way, have you seen our new labview driver here
viewtopic.php?f=2&t=506
Try to achive your goal by the GUI tool, first. This will allow you to eliminate hardware related issues, like connections, grounds, pull-ups, signal levels etc.
Before developing your vi in LabView I would suggest to use our GUI application - subtool, to communicate with your LSM330DL device, i.e
- Configure SPI (or I2C), SS polarity, clock edge, clock rate etc. See the datasheet for the LSM330DL
- Read registers from the device, check if reading is reliable. Then go ahead and develop your vi.
By the way, have you seen our new labview driver here
viewtopic.php?f=2&t=506
Try to achive your goal by the GUI tool, first. This will allow you to eliminate hardware related issues, like connections, grounds, pull-ups, signal levels etc.