Module sensor

Module sensor 

Available on crate feature sensors only.
Expand description

Provides a Sensor trait abstracting over implementation details of a sensor driver.

Structs§

ReadingChannel
Provides metadata about a Sample.
ReadingChannels
Metadata required to interpret samples returned by Sensor::wait_for_reading().
ReadingWaiter
Future returned by Sensor::wait_for_reading().
Sample
Represents a value obtained from a sensor device, along with its metadata.
Samples
Samples returned by a sensor driver.
TryFromIntError
The error type returned when a checked integral type conversion fails.

Enums§

Mode
Mode of a sensor driver.
ReadingError
Represents errors happening when accessing a sensor reading.
SampleError
Errors returned when trying to interpret a sample.
SampleMetadata
Metadata associated with a Sample.
SetModeError
Possible errors when attempting to set the mode of a sensor driver.
State
State of a sensor driver.
TriggerMeasurementError
Represents errors happening when triggering a sensor measurement.

Traits§

Reading
Implemented on Samples, returned by Sensor::wait_for_reading().
Sensor
This trait must be implemented by sensor drivers.
SensorAccess
Provides access to the sensor driver instance. For driver implementors only.

Type Aliases§

ReadingResult
A specialized Result type for Reading operations.