pub struct RemoteIo { /* private fields */ }
Expand description
Implements the Firmata protocol within an IoProtocol
.
Implementations§
Source§impl RemoteIo
impl RemoteIo
Sourcepub fn start_polling(&self)
pub fn start_polling(&self)
Manually attaches the board value change listener. This is only used for input events.
This should never be needed unless you manually detach()
the sensor first for some reason
and want it to start being reactive to events again.
Sourcepub fn stop_polling(&self)
pub fn stop_polling(&self)
Detaches the interval associated with the button. This means the button won’t react anymore to value changes.
Trait Implementations§
Source§impl<T: IoTransport + 'static> From<T> for RemoteIo
impl<T: IoTransport + 'static> From<T> for RemoteIo
Source§impl IO for RemoteIo
impl IO for RemoteIo
Source§fn is_connected(&self) -> bool
fn is_connected(&self) -> bool
Checks if the communication is opened using the underlying protocol.
Source§fn servo_config(&mut self, pin: u8, pwm_range: Range<u16>) -> Result<(), Error>
fn servo_config(&mut self, pin: u8, pwm_range: Range<u16>) -> Result<(), Error>
Sends a SERVO_CONFIG command (0x70 - configure servo)
https://github.com/firmata/protocol/blob/master/servos.md
Source§fn i2c_config(&mut self, delay: u16) -> Result<(), Error>
fn i2c_config(&mut self, delay: u16) -> Result<(), Error>
Configures the
delay
in microseconds for I2C devices that require a delay between when the
register is written to and the data in that register can be read.Source§impl IoProtocol for RemoteIo
impl IoProtocol for RemoteIo
Source§fn open(&mut self) -> Result<(), Error>
fn open(&mut self) -> Result<(), Error>
Opens the communication using the underlying protocol.
Auto Trait Implementations§
impl Freeze for RemoteIo
impl !RefUnwindSafe for RemoteIo
impl Send for RemoteIo
impl Sync for RemoteIo
impl Unpin for RemoteIo
impl !UnwindSafe for RemoteIo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more