Struct UarteConfig
#[repr(transparent)]pub struct UarteConfig(pub u32);
Expand description
Configuration of parity, hardware flow control, framesize, and packet timeout.
Tuple Fields§
§0: u32
Implementations§
§impl UarteConfig
impl UarteConfig
pub const fn parity(&self) -> ConfigParity
pub const fn parity(&self) -> ConfigParity
Parity
pub fn set_parity(&mut self, val: ConfigParity)
pub fn set_parity(&mut self, val: ConfigParity)
Parity
pub const fn stop(&self) -> ConfigStop
pub const fn stop(&self) -> ConfigStop
Stop bits
pub fn set_stop(&mut self, val: ConfigStop)
pub fn set_stop(&mut self, val: ConfigStop)
Stop bits
pub const fn paritytype(&self) -> Paritytype
pub const fn paritytype(&self) -> Paritytype
Even or odd parity type
pub fn set_paritytype(&mut self, val: Paritytype)
pub fn set_paritytype(&mut self, val: Paritytype)
Even or odd parity type
pub fn set_framesize(&mut self, val: Framesize)
pub fn set_framesize(&mut self, val: Framesize)
Set the data frame size
pub const fn endian(&self) -> Endian
pub const fn endian(&self) -> Endian
Select if data is trimmed from MSB or LSB end when the data frame size is less than 8.
pub fn set_endian(&mut self, val: Endian)
pub fn set_endian(&mut self, val: Endian)
Select if data is trimmed from MSB or LSB end when the data frame size is less than 8.
pub const fn frametimeout(&self) -> bool
pub const fn frametimeout(&self) -> bool
Enable packet timeout.
pub fn set_frametimeout(&mut self, val: bool)
pub fn set_frametimeout(&mut self, val: bool)
Enable packet timeout.
Trait Implementations§
§impl Clone for UarteConfig
impl Clone for UarteConfig
§fn clone(&self) -> UarteConfig
fn clone(&self) -> UarteConfig
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more§impl Default for UarteConfig
impl Default for UarteConfig
§fn default() -> UarteConfig
fn default() -> UarteConfig
Returns the “default value” for a type. Read more
§impl PartialEq for UarteConfig
impl PartialEq for UarteConfig
impl Copy for UarteConfig
impl Eq for UarteConfig
impl StructuralPartialEq for UarteConfig
Auto Trait Implementations§
impl Freeze for UarteConfig
impl RefUnwindSafe for UarteConfig
impl Send for UarteConfig
impl Sync for UarteConfig
impl Unpin for UarteConfig
impl UnwindSafe for UarteConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)