pub struct W(_);
Expand description
Register CR2
writer
Implementations
sourceimpl W
impl W
sourcepub fn rtoen(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, RTOEN_A, BitM, 23>
pub fn rtoen(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, RTOEN_A, BitM, 23>
Bit 23 - Receiver timeout enable
sourcepub fn abren(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, ABREN_A, BitM, 20>
pub fn abren(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, ABREN_A, BitM, 20>
Bit 20 - Auto baud rate enable
sourcepub fn msbfirst(
&mut self
) -> BitWriterRaw<'_, u32, CR2_SPEC, MSBFIRST_A, BitM, 19>
pub fn msbfirst(
&mut self
) -> BitWriterRaw<'_, u32, CR2_SPEC, MSBFIRST_A, BitM, 19>
Bit 19 - Most significant bit first
sourcepub fn datainv(
&mut self
) -> BitWriterRaw<'_, u32, CR2_SPEC, DATAINV_A, BitM, 18>
pub fn datainv(
&mut self
) -> BitWriterRaw<'_, u32, CR2_SPEC, DATAINV_A, BitM, 18>
Bit 18 - Binary data inversion
sourcepub fn txinv(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, TXINV_A, BitM, 17>
pub fn txinv(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, TXINV_A, BitM, 17>
Bit 17 - TX pin active level inversion
sourcepub fn rxinv(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, RXINV_A, BitM, 16>
pub fn rxinv(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, RXINV_A, BitM, 16>
Bit 16 - RX pin active level inversion
sourcepub fn swap(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, SWAP_A, BitM, 15>
pub fn swap(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, SWAP_A, BitM, 15>
Bit 15 - Swap TX/RX pins
sourcepub fn linen(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LINEN_A, BitM, 14>
pub fn linen(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LINEN_A, BitM, 14>
Bit 14 - LIN mode enable
sourcepub fn stop(
&mut self
) -> FieldWriterRaw<'_, u32, CR2_SPEC, u8, STOP_A, Safe, 2, 12>
pub fn stop(
&mut self
) -> FieldWriterRaw<'_, u32, CR2_SPEC, u8, STOP_A, Safe, 2, 12>
Bits 12:13 - STOP bits
sourcepub fn clken(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, CLKEN_A, BitM, 11>
pub fn clken(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, CLKEN_A, BitM, 11>
Bit 11 - Clock enable
sourcepub fn cpol(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, CPOL_A, BitM, 10>
pub fn cpol(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, CPOL_A, BitM, 10>
Bit 10 - Clock polarity
sourcepub fn lbcl(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LBCL_A, BitM, 8>
pub fn lbcl(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LBCL_A, BitM, 8>
Bit 8 - Last bit clock pulse
sourcepub fn lbdie(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LBDIE_A, BitM, 6>
pub fn lbdie(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LBDIE_A, BitM, 6>
Bit 6 - LIN break detection interrupt enable
sourcepub fn lbdl(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LBDL_A, BitM, 5>
pub fn lbdl(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, LBDL_A, BitM, 5>
Bit 5 - LIN break detection length
sourcepub fn addm7(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, ADDM7_A, BitM, 4>
pub fn addm7(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, ADDM7_A, BitM, 4>
Bit 4 - 7-bit Address Detection/4-bit Address Detection
sourcepub fn dis_nss(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, bool, BitM, 3>
pub fn dis_nss(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, bool, BitM, 3>
Bit 3 - When the DSI_NSS bit is set, the NSS pin input is ignored
sourcepub fn slven(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, bool, BitM, 0>
pub fn slven(&mut self) -> BitWriterRaw<'_, u32, CR2_SPEC, bool, BitM, 0>
Bit 0 - Synchronous Slave mode enable
sourcepub fn abrmod(
&mut self
) -> FieldWriterRaw<'_, u32, CR2_SPEC, u8, ABRMOD_A, Safe, 2, 21>
pub fn abrmod(
&mut self
) -> FieldWriterRaw<'_, u32, CR2_SPEC, u8, ABRMOD_A, Safe, 2, 21>
Bits 21:22 - Auto baud rate mode
Methods from Deref<Target = W<CR2_SPEC>>
sourcepub unsafe fn bits(&mut self, bits: <REG as RegisterSpec>::Ux) -> &mut W<REG>
pub unsafe fn bits(&mut self, bits: <REG as RegisterSpec>::Ux) -> &mut W<REG>
Writes raw bits to the register.
Trait Implementations
Auto Trait Implementations
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
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