diff --git a/src/registries/sensors.rs b/src/registries/sensors.rs new file mode 100644 index 0000000..3508b2e --- /dev/null +++ b/src/registries/sensors.rs @@ -0,0 +1,16 @@ +use futures::{Future, Stream}; + +pub struct Sensors { + +} + + +// Implementing Sensors. +// +// Given the coroutine/task split stays as it is - Sensor input to machine update being one, +// machine update signal to actor doing thing being another, a Sensor implementation would send a +// Stream of futures - each future being an atomic Machine update. +#[async_trait] +pub trait Sensor: Stream>> { + async fn setup() -> Self; +}