For the Sound and Vibration Measurement Hat for Raspberry Pi road test, I'm reviewing Measurement Computing's IEPE Measurement DAQ HAT for Raspberry Pi. |
All images and screenshots in this blog are from the actual designs. They reflect the status at the time of writing
Pilot Goals
In the first incarnation of the custom software, I had set these goals:
- make the DAQ hat remote programmable, via network
- Basic instrument service on the Pi
- SCPI wrapper service on the Pi
- LabVIEW driver, Virtual Instrument (VI) style
- All configuration areas controllable and status feedback: IEPE supply, Clock and Sensitivity
- Working: 2 binaries should run on the Pi, an example flow should be able to control the instrument, via the VI driver.
This means that I should be able to make a control panel in LabVIEW that can set all of the configurations, execute it, and show the results.
Stack
The software is layered. All of the layers are publicly available, so you can choose where to (re)use the APIs.
local Linux APIs:
These are libraries, and can be used in applications that run locally on the Raspberry Pi.
- suppliers MCC C API. This is the library that's supplied by Measurement Computing Corporation.
- DaqHatsInstrument C++ API: a wrapper for the vendor's C API I wrote for this road test. It's a part of the Instrument Service listed below, but can be used by itself.
TCP/IP socket APIs:
These are Linux services that run on the Raspberry Pi. They expose a TCP/IP Socket interface that can be used locally or over the network.
- Instrument Service: a 1-to-1 translation from the C++ API to datagrams. Written in C++ for this road test. It uses the C++ API.
- SCPI Service: parses SCPI commands, translates them into datagrams and forwards the requests to the Instrument Service. In C, for this road test.
LabVIEW Driver API:
This is a Virtual Instrument (VI) driver written for this road test with LabVIEW 2021 Community Edition. Its API is a set of reusable blocks that know how to connect and interact with the instrument. The driver sends SCPI commands to the Raspberry Pi.
Example LabVIEW flow:
Proof of concept flow, also in LabVIEW 2021 CE. It's available in the driver project, in a separate Examples folder. It connects, tests every configuration option, queries each setting, then disconnects.
To Do
See the backlog.