pub struct Settings<Word = u8> { /* private fields */ }Expand description
USART settings
Expected as an argument by the various enable methods on USART.
Implementations§
Source§impl<Word> Settings<Word>
impl<Word> Settings<Word>
Sourcepub fn data_len_7(self) -> Settings<u8>
pub fn data_len_7(self) -> Settings<u8>
Set data length to 7 bits
Overwrites the previous data length setting.
Sourcepub fn data_len_8(self) -> Settings<u8>
pub fn data_len_8(self) -> Settings<u8>
Set data length to 8 bits
Overwrites the previous data length setting. This is the default.
Sourcepub fn data_len_9(self) -> Settings<u16>
pub fn data_len_9(self) -> Settings<u16>
Set data length to 9 bits
Overwrites the previous data length setting.
Sourcepub fn parity_none(self) -> Self
pub fn parity_none(self) -> Self
Add no parity bit
Overwrites the previous parity setting. This is the default.
Sourcepub fn parity_even(self) -> Self
pub fn parity_even(self) -> Self
Add even parity bit
Overwrites the previous parity setting.
Sourcepub fn parity_odd(self) -> Self
pub fn parity_odd(self) -> Self
Add odd parity bit
Overwrites the previous parity setting.
Sourcepub fn stop_len_1(self) -> Self
pub fn stop_len_1(self) -> Self
Add one stop bit
Overwrites the previous stop length setting. This is the default.
Sourcepub fn stop_len_2(self) -> Self
pub fn stop_len_2(self) -> Self
Add two stop bits
Overwrites the previous stop length setting.
Sourcepub fn clock_pol_falling(self) -> Self
pub fn clock_pol_falling(self) -> Self
Sample on falling clock edge
This is only relevant when receiving data in synchronous mode.
Overwrites the previous clock polarity setting. This is the default.
Sourcepub fn clock_pol_rising(self) -> Self
pub fn clock_pol_rising(self) -> Self
Sample on rising clock edge
This is only relevant when receiving data in synchronous mode.
Overwrites the previous clock polarity setting.
Sourcepub fn rx_pol_standard(self) -> Self
pub fn rx_pol_standard(self) -> Self
Don’t invert RX signal
Overwrites the previous RX polarity setting. This is the default.
Sourcepub fn rx_pol_inverted(self) -> Self
pub fn rx_pol_inverted(self) -> Self
Invert RX signal
Overwrites the previous RX polarity setting.
Sourcepub fn tx_pol_standard(self) -> Self
pub fn tx_pol_standard(self) -> Self
Don’t invert TX signal
Overwrites the previous TX polarity setting. This is the default.
Sourcepub fn tx_pol_inverted(self) -> Self
pub fn tx_pol_inverted(self) -> Self
Invert TX signal
Overwrites the previous TX polarity setting.