diff --git a/src/core/motor.rs b/src/core/motor.rs index 5ddfb06..d43b2c0 100644 --- a/src/core/motor.rs +++ b/src/core/motor.rs @@ -116,13 +116,22 @@ pub trait Driver { /// Some sensors may also provide current and voltage feedback, if implemented the communication system can sync them to the host you for. /// Can also be used for other custom logic. They are unused by RNavP, entirely optional. pub trait Sensor { - ///Gets a speed struct value from the motors sensor + ///Returns the speed struct value from the motors sensor /// This should be non-blocking, there should be some form of cached value ready to go as soon as the method is called - /// IF properly returned in the correct Enum Data field, all other systems will use the value propely + /// + /// IF properly returned in the correct Enum Data field, all other systems will use the value propely, being unit agnostic later. fn get_speed(&self) -> Speed; + ///Returns the current from the sensor, if it capable. + /// This should be non-blocking. Keep a cached value ready. fn get_current(&self) -> Option; + + ///Returns the current voltage from the sensro, if it is capable. + /// This should be non-blocking. Keep a cached value ready. fn get_voltage(&self) -> Option; + + ///Returns the current angle from the sensor if it is capable. + /// This should be non-blocking. Keep a cached value ready. fn get_angle(&self) -> Option; }