pub enum PublishEvent {
Battery(BatteryStatus),
Time(Option<u32>),
Gnss(u32, GnssSnapshot),
}Expand description
A device-initiated property publication, yielded by
DeviceEnv::publish_event.
The driver has exactly one select arm for everything the board pushes
unasked, because a hook per property would need one &mut self borrow
per arm and no two of those can coexist. One arm, one enum, and the
board decides internally which of its sources woke it.
Variants§
Battery(BatteryStatus)
An unsolicited PROP_BATTERY.
Time(Option<u32>)
An unsolicited PROP_TIME; None is a clock that has gone back
to not knowing what time it is.
Gnss(u32, GnssSnapshot)
An unsolicited positioning property, named by its key, encoded from the accompanying snapshot.
Auto Trait Implementations§
impl Freeze for PublishEvent
impl RefUnwindSafe for PublishEvent
impl Send for PublishEvent
impl Sync for PublishEvent
impl Unpin for PublishEvent
impl UnwindSafe for PublishEvent
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more