Apogee USB Sensors and Linux
Apogee USB sensors can be connected directly to a computer (Windows or macOS X) for taking spot measurements or graphing and datalogging real-time PPFD using the included software. Apogee currently does not have software for our sensors with Linux systems; however, while we do not design custom programs, we can offer a set of commands, sample code, and comments from the developer of ApogeeConnect that should help provide a good foundation for getting your own program started using Apogee USB sensors (SP-420, SQ-420, SQ-520, etc.). This information is copied below:
| Command |
Transmitted Bytes |
Returns |
|---|---|---|
| GET_VOLT | 55 21 | 5 [cmd + four byte floating point number] |
| READ_CALIBRATION | 83 21 |
9 [cmd + four byte float multiplier + four byte float offset] |
| SET_CALIBRATION | 84 XX XX XX XX YY YY YY YY 21 (X = 4 byte floating point multiplier, Y = 4 byte floating point offset) | 9 [same as above] |
| READ_SERIAL_NUM | 87 21 |
5 [cmd + four byte floating point number] |
| GET_LOGGING_INTERVAL | f1 21 |
9 [cmd + logging interval + sample interval] all floats |
| GET_LOGGING_COUNT | f3 21 |
5 [cmd + number of entries] four byte integer |
| GET_LOGGED_ENTRY | f2 XX XX XX XX 21 (X = 4 byte long integer) |
5 [cmd + four byte floating point number] |
| SET_LOGGING_INTERVAL | f0 XX XX XX XX YY YY YY YY 21 (X = 4 byte floating point logging interval, Y = 4 byte floating point sampling interval |
8 [cmd + received logging interval + 3 dummy bytes] |
| ERASE_LOGGED_DATA | f4 21 | 4 [cmd + 3 dummy bytes] |
There are many online resources on how to convert hexadecimal to floating point numbers. Here's a link with a few suggestions from other programmers using c# https://protect-eu.mimecast.com/s/pokJCZzGOF7xBKtNSk8F?domain=url9639.waterbearenergy.com.
The response from Apogee USB sensors is always sent in little endian format meaning the least significant byte is sent first.
**Please note: Apogee does not provide technical support for custom programs.