Struct rstubs::device::serial::LineStatus
source · #[repr(transparent)]struct LineStatus(u8);
Expand description
Line Status Register
Tuple Fields§
§0: u8
Implementations§
source§impl LineStatus
impl LineStatus
const DATA_READY_BITS: usize = 1usize
const DATA_READY_OFFSET: usize = 0usize
sourceconst fn with_data_ready(self, value: bool) -> Self
const fn with_data_ready(self, value: bool) -> Self
Set when there is a value in the receive buffer
Bits: 0..1
sourceconst fn data_ready(&self) -> bool
const fn data_ready(&self) -> bool
Set when there is a value in the receive buffer
Bits: 0..1
sourcefn set_data_ready(&mut self, value: bool)
fn set_data_ready(&mut self, value: bool)
Set when there is a value in the receive buffer
Bits: 0..1
const OVERRUN_ERROR_BITS: usize = 1usize
const OVERRUN_ERROR_OFFSET: usize = 1usize
sourceconst fn with_overrun_error(self, value: bool) -> Self
const fn with_overrun_error(self, value: bool) -> Self
Bits: 1..2
sourceconst fn overrun_error(&self) -> bool
const fn overrun_error(&self) -> bool
Bits: 1..2
sourcefn set_overrun_error(&mut self, value: bool)
fn set_overrun_error(&mut self, value: bool)
Bits: 1..2
const PARITY_ERROR_BITS: usize = 1usize
const PARITY_ERROR_OFFSET: usize = 2usize
sourceconst fn with_parity_error(self, value: bool) -> Self
const fn with_parity_error(self, value: bool) -> Self
Bits: 2..3
sourceconst fn parity_error(&self) -> bool
const fn parity_error(&self) -> bool
Bits: 2..3
sourcefn set_parity_error(&mut self, value: bool)
fn set_parity_error(&mut self, value: bool)
Bits: 2..3
const FRAMING_ERROR_BITS: usize = 1usize
const FRAMING_ERROR_OFFSET: usize = 3usize
sourceconst fn with_framing_error(self, value: bool) -> Self
const fn with_framing_error(self, value: bool) -> Self
Bits: 3..4
sourceconst fn framing_error(&self) -> bool
const fn framing_error(&self) -> bool
Bits: 3..4
sourcefn set_framing_error(&mut self, value: bool)
fn set_framing_error(&mut self, value: bool)
Bits: 3..4
const BREAK_INTERRUPT_BITS: usize = 1usize
const BREAK_INTERRUPT_OFFSET: usize = 4usize
sourceconst fn with_break_interrupt(self, value: bool) -> Self
const fn with_break_interrupt(self, value: bool) -> Self
Bits: 4..5
sourceconst fn break_interrupt(&self) -> bool
const fn break_interrupt(&self) -> bool
Bits: 4..5
sourcefn set_break_interrupt(&mut self, value: bool)
fn set_break_interrupt(&mut self, value: bool)
Bits: 4..5
const TRANSMITTER_HOLDING_REGISTER_BITS: usize = 1usize
const TRANSMITTER_HOLDING_REGISTER_OFFSET: usize = 5usize
sourceconst fn with_transmitter_holding_register(self, value: bool) -> Self
const fn with_transmitter_holding_register(self, value: bool) -> Self
Bits: 5..6
sourceconst fn transmitter_holding_register(&self) -> bool
const fn transmitter_holding_register(&self) -> bool
Bits: 5..6
sourcefn set_transmitter_holding_register(&mut self, value: bool)
fn set_transmitter_holding_register(&mut self, value: bool)
Bits: 5..6
const TRANSMITTER_EMPTY_BITS: usize = 1usize
const TRANSMITTER_EMPTY_OFFSET: usize = 6usize
sourceconst fn with_transmitter_empty(self, value: bool) -> Self
const fn with_transmitter_empty(self, value: bool) -> Self
Send buffer empty (ready to send)
Bits: 6..7
sourceconst fn transmitter_empty(&self) -> bool
const fn transmitter_empty(&self) -> bool
Send buffer empty (ready to send)
Bits: 6..7
sourcefn set_transmitter_empty(&mut self, value: bool)
fn set_transmitter_empty(&mut self, value: bool)
Send buffer empty (ready to send)
Bits: 6..7
Trait Implementations§
source§impl Clone for LineStatus
impl Clone for LineStatus
source§fn clone(&self) -> LineStatus
fn clone(&self) -> LineStatus
Returns a copy of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for LineStatus
impl Debug for LineStatus
source§impl Default for LineStatus
impl Default for LineStatus
source§impl From<LineStatus> for u8
impl From<LineStatus> for u8
source§fn from(v: LineStatus) -> u8
fn from(v: LineStatus) -> u8
Converts to this type from the input type.