Skip to main content

can_task

Function can_task 

Source
pub fn can_task(
    can_buf: &'static BufferedCan,
    twai0: TWAI0<'static>,
    pins: EspCanPins<'static>,
) -> Result<SpawnToken<impl Sized>, SpawnError>
Expand description

Embassy task that owns the hardware TWAI peripheral and pumps it through BufferedCan::run. Spawn from a higher-priority InterruptExecutor for lower latency.