Expand description
Safe Rust bindings for the Intrepid Control Systems neoRAD-IO2 device family.
use neoradio2::{Device, CalType};
for info in Device::find()? {
let dev = Device::open(&info)?;
dev.chain_identify()?;
dev.app_start(0, 0xFF)?;
dev.request_sensor_data(0, 0xFF, CalType::Enabled)?;
println!("{}", dev.read_sensor_float(0, 0)?);
}Modules§
- raw
- Raw
repr(C)structs used by the settings/calibration/statistics calls.
Structs§
- Device
- An open connection to a neoRAD-IO2 chain (closed automatically on drop).
- Device
Info - Information about a discovered neoRAD-IO2 USB device.
Enums§
- CalType
- Sensor read calibration mode.
- Command
Status - Command status returned by
Device::status. - Device
Type - neoRAD-IO2 device type.
- Error
- Errors returned by the neoRAD-IO2 API.
- LedMode
- LED toggle mode.
- Status
Type - Status query type (see
Device::status).
Functions§
- is_
blocking - Whether the API is in blocking mode.
- set_
blocking - Set process-global blocking mode. In blocking mode, calls wait up to
timeoutfor completion; in non-blocking mode they return immediately.
Type Aliases§
- Result
- Crate result type.