emcyphal_stm32_embassy/
lib.rs

1//! STM32 FDCAN driver adapter for the Emcyphal stack
2//!
3//! This adapter integrates the FDCAN driver from the Embassy framework with the Emcyphal stack.
4//!
5//! # Features
6//!
7//! * 7 subject filters
8//! * 1 destination (node address) filter
9//! * Partial TX timeout support
10//!
11//! # Limitations
12//!
13//! * Anonymous frame transmission is not supported
14//! * Loop-back frames are not supported
15//! * Frame ordering is partially preserved per priority; frames from different sessions may
16//!   preempt each other
17//! * Partial TX timeout support: timestamps are checked when inserting frames into the 3-element
18//!   hardware queue. Frames may remain enqueued indefinitely if the bus is occupied by
19//!   higher-priority traffic
20//! * Discontinuous transmission: a runner task wakes up to initial transmission of each frame
21//!   within the same session
22//! * A 32-frame buffer is required for worst-case preemption
23//! * embassy-stm32 v0.4.0 does not enable transmitter delay compensation; data bit rates
24//!   above 4 Mbps may be unavailable with typical transceivers
25//!
26//! # Examples
27//!
28//! See the `pubsub_native` example in the 
29//! [nucleo-g431rb](https://github.com/dan-stefanov/emcyphal/tree/emcyphal-stm32-embassy-v0.1.0/nucleo-g431rb)
30//! crate.
31
32#![no_std]
33
34// This mod MUST go first, so that the others see its macros.
35pub(crate) mod fmt;
36
37pub mod config;
38mod driver;
39mod format;
40mod utils;
41
42pub use driver::SUBJECT_SLOT_COUNT;
43pub use driver::{RxFilterRunner, RxRunner, TxRunner, bind};