[][src]Module embedded_hal::mutex::default

[]

Blanket implementations for RoMutex and RwMutex

Any RwMutex can trivially implement RoMutex as well. To enable this, add a line like

impl<T> mutex::default::DefaultRo for MyMutex<T> { }

to your mutex definition.

Similarly, a RoMutex and a RefCell can be used to implement RwMutex. The blanket implementation can be enabled using

impl<T> mutex::default::RefCellRw for MyMutex<T> { }

Traits

DefaultRo

Marker trait to enable the default RoMutex implementation.

RefCellRw

Marker trait to enable an implementation of RwMutex using RefCells