pub trait DeviceIo: Send {
type Seq;
type Ptr: Copy + Send;
type Model: ?Sized;
type LoraCmd;
type LoraAck;
// Required methods
fn model(&self) -> &Self::Model;
fn facts(&self) -> DeviceFacts;
fn max_depth(&self) -> usize;
fn launch(
&self,
plan: StepPlan<'_>,
rows: &mut [&mut Self::Seq],
) -> Result<Ticket, DeviceError>;
fn await_result(
&self,
ticket: Ticket,
) -> Result<StepResult<Self::Ptr>, DeviceError>;
fn apply(
&self,
effect: Effect<'_, Self::Seq, Self::Ptr>,
) -> Result<EffectOutcome, DeviceError>;
fn lora(&mut self, cmd: Self::LoraCmd) -> Result<Self::LoraAck, String>;
fn teardown(self: Box<Self>) -> Result<()>;
}Required Associated Types§
Sourcetype Model: ?Sized
type Model: ?Sized
2026-09-25: The model behind this router, returned by Self::model for
calls that go around plans and effects.
type LoraAck
Required Methods§
fn model(&self) -> &Self::Model
Sourcefn facts(&self) -> DeviceFacts
fn facts(&self) -> DeviceFacts
2026-09-25: The KV pool and SSM snapshot counters (DeviceFacts).
Sourcefn max_depth(&self) -> usize
fn max_depth(&self) -> usize
2026-09-25: How many steps may be in flight (1 = every step settles before the next launches).
Sourcefn launch(
&self,
plan: StepPlan<'_>,
rows: &mut [&mut Self::Seq],
) -> Result<Ticket, DeviceError>
fn launch( &self, plan: StepPlan<'_>, rows: &mut [&mut Self::Seq], ) -> Result<Ticket, DeviceError>
2026-09-25: Start plan over rows; settle it with Self::await_result.