pub type SpiBusWrapper = RefCell<SpiBusInner>;Expand description
Shared SPI bus wrapper type, selected by the active bus-sharing feature.
This type wraps SpiBusInner in a concurrency-safe container so that
both the display and the SD card can share the same SPI2 peripheral:
| Feature | Wrapper | Thread safety |
|---|---|---|
RefCellBus | RefCell<SpiBusInner> | Single-core, no ISRs. |
CriticalSectionBus | Mutex<RefCell<SpiBusInner>> | Safe with ISRs. |
AtomicBus | AtomicCell<SpiBusInner> | Lock-free (blocking only). |
AsyncBus | embassy_sync::Mutex<…> | Async-safe. |
The wrapper lives in a 'static [StaticCell]; you receive a &'static SpiBusWrapper
from init_bus and pass it to [make_device] for each peripheral.
Aliased Type§
pub struct SpiBusWrapper { /* private fields */ }