pub struct Worker<IO, I2C, SPI, UART>where
IO: WorkerIo,
I2C: Write + Read + WriteRead,
SPI: Write<u8> + Transfer<u8>,
UART: Write<u8> + Read<u8>,{
pub io: IO,
pub i2c: I2C,
pub spi: SPI,
pub uart: UART,
/* private fields */
}Expand description
A Pretty HAL Machine Worker
This struct is intended to contain all of the shared logic between workers. It is highly generic, which should allow the logic to execute regardless of the MCU the worker is executing on.
Fields§
§io: IO§i2c: I2C§spi: SPI§uart: UARTImplementations§
Auto Trait Implementations§
impl<IO, I2C, SPI, UART> Freeze for Worker<IO, I2C, SPI, UART>
impl<IO, I2C, SPI, UART> RefUnwindSafe for Worker<IO, I2C, SPI, UART>
impl<IO, I2C, SPI, UART> Send for Worker<IO, I2C, SPI, UART>
impl<IO, I2C, SPI, UART> Sync for Worker<IO, I2C, SPI, UART>
impl<IO, I2C, SPI, UART> Unpin for Worker<IO, I2C, SPI, UART>
impl<IO, I2C, SPI, UART> UnwindSafe for Worker<IO, I2C, SPI, UART>
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