Struct gd32f1x0_hal::serial::Serial
source · [−]pub struct Serial<USART, TXPIN, RXPIN> { /* private fields */ }
Expand description
Serial abstraction
Implementations
sourceimpl<USART: RcuBus + Enable + Reset + Deref<Target = RegisterBlock>, TXPIN: TxPin<USART>, RXPIN: RxPin<USART>> Serial<USART, TXPIN, RXPIN> where
USART::Bus: GetBusFreq,
impl<USART: RcuBus + Enable + Reset + Deref<Target = RegisterBlock>, TXPIN: TxPin<USART>, RXPIN: RxPin<USART>> Serial<USART, TXPIN, RXPIN> where
USART::Bus: GetBusFreq,
sourcepub fn usart(
usart: USART,
pins: (TXPIN, RXPIN),
config: Config,
clocks: Clocks,
bus: &mut USART::Bus
) -> Self
pub fn usart(
usart: USART,
pins: (TXPIN, RXPIN),
config: Config,
clocks: Clocks,
bus: &mut USART::Bus
) -> Self
Configures the USART and creates a new Serial instance.
sourceimpl<USART: RcuBus + Enable + Reset + Deref<Target = RegisterBlock>, TXPIN: TxPin<USART>> Serial<USART, TXPIN, ()> where
USART::Bus: GetBusFreq,
impl<USART: RcuBus + Enable + Reset + Deref<Target = RegisterBlock>, TXPIN: TxPin<USART>> Serial<USART, TXPIN, ()> where
USART::Bus: GetBusFreq,
sourceimpl<USART: RcuBus + Enable + Reset + Deref<Target = RegisterBlock>, RXPIN: RxPin<USART>> Serial<USART, (), RXPIN> where
USART::Bus: GetBusFreq,
impl<USART: RcuBus + Enable + Reset + Deref<Target = RegisterBlock>, RXPIN: RxPin<USART>> Serial<USART, (), RXPIN> where
USART::Bus: GetBusFreq,
Trait Implementations
sourceimpl<USART: Deref<Target = RegisterBlock>, TXPIN, RXPIN: RxPin<USART>> Read<u8> for Serial<USART, TXPIN, RXPIN>
impl<USART: Deref<Target = RegisterBlock>, TXPIN, RXPIN: RxPin<USART>> Read<u8> for Serial<USART, TXPIN, RXPIN>
sourceimpl<USART: Deref<Target = RegisterBlock>, TXPIN: TxPin<USART>, RXPIN> Write for Serial<USART, TXPIN, RXPIN>
impl<USART: Deref<Target = RegisterBlock>, TXPIN: TxPin<USART>, RXPIN> Write for Serial<USART, TXPIN, RXPIN>
Auto Trait Implementations
impl<USART, TXPIN, RXPIN> RefUnwindSafe for Serial<USART, TXPIN, RXPIN> where
RXPIN: RefUnwindSafe,
TXPIN: RefUnwindSafe,
USART: RefUnwindSafe,
impl<USART, TXPIN, RXPIN> Send for Serial<USART, TXPIN, RXPIN> where
RXPIN: Send,
TXPIN: Send,
USART: Send,
impl<USART, TXPIN, RXPIN> Sync for Serial<USART, TXPIN, RXPIN> where
RXPIN: Sync,
TXPIN: Sync,
USART: Sync,
impl<USART, TXPIN, RXPIN> Unpin for Serial<USART, TXPIN, RXPIN> where
RXPIN: Unpin,
TXPIN: Unpin,
USART: Unpin,
impl<USART, TXPIN, RXPIN> UnwindSafe for Serial<USART, TXPIN, RXPIN> where
RXPIN: UnwindSafe,
TXPIN: UnwindSafe,
USART: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more