kernel::hil::sensors

Trait DistanceClient

Source
pub trait DistanceClient {
    // Required method
    fn callback(&self, distance: Result<u32, ErrorCode>);
}
Expand description

Client for receiving distance readings.

Required Methods§

Source

fn callback(&self, distance: Result<u32, ErrorCode>)

Called when a distance measurement has completed.

  • distance: the most recently measured distance in millimeters. If there was an error, this will be Err(ErrorCode).

Implementors§