mss_uart_instance

Struct mss_uart_instance 

Source
#[repr(C)]
pub struct mss_uart_instance {
Show 20 fields pub hw_reg: *mut MSS_UART_TypeDef, pub baudrate: u32, pub lineconfig: u8, pub status: u8, pub padding0: [u8; 2], pub tx_buffer: *const u8, pub tx_buff_size: u32, pub tx_idx: u32, pub linests_handler: mss_uart_irq_handler_t, pub rx_handler: mss_uart_irq_handler_t, pub tx_handler: mss_uart_irq_handler_t, pub modemsts_handler: mss_uart_irq_handler_t, pub rto_handler: mss_uart_irq_handler_t, pub nack_handler: mss_uart_irq_handler_t, pub pid_pei_handler: mss_uart_irq_handler_t, pub break_handler: mss_uart_irq_handler_t, pub sync_handler: mss_uart_irq_handler_t, pub local_irq_enabled: u8, pub padding1: [u8; 7], pub user_data: *mut c_void,
}
Expand description

/ /** mss_uart_instance. There is one instance of this structure for each instance of the microprocessor subsystem’s UARTs. Instances of this structure are used to identify a specific UART. A pointer to an initialized instance of the mss_uart_instance_t structure is passed as the first parameter to MSS UART driver functions to identify which UART should perform the requested operation.

Fields§

§hw_reg: *mut MSS_UART_TypeDef

< Pointer to UART registers.

§baudrate: u32

< Operating baud rate.

§lineconfig: u8

< Line configuration parameters.

§status: u8

< Sticky line status.

§padding0: [u8; 2]

< Padding bytes for data alignment.

§tx_buffer: *const u8

< Pointer to transmit buffer.

§tx_buff_size: u32

< Transmit buffer size.

§tx_idx: u32

< Index within transmit buffer of next byte to transmit.

§linests_handler: mss_uart_irq_handler_t

< Pointer to user registered line status handler.

§rx_handler: mss_uart_irq_handler_t

< Pointer to user registered receiver handler.

§tx_handler: mss_uart_irq_handler_t

< Pointer to user registered transmit handler.

§modemsts_handler: mss_uart_irq_handler_t

< Pointer to user registered modem status handler.

§rto_handler: mss_uart_irq_handler_t

< Pointer to user registered receiver timeout handler.

§nack_handler: mss_uart_irq_handler_t

< Pointer to user registered NACK handler.

§pid_pei_handler: mss_uart_irq_handler_t

< Pointer to user registered PID parity error handler.

§break_handler: mss_uart_irq_handler_t

< Pointer to user registered LIN break handler.

§sync_handler: mss_uart_irq_handler_t

< Pointer to user registered LIN sync detection handler.

§local_irq_enabled: u8

< Check if local interrupt were enabled on this instance.

§padding1: [u8; 7]

< Padding bytes for data alignment.

§user_data: *mut c_void

< Pointer to user provided pointer for user specific use.

Trait Implementations§

Source§

impl Clone for mss_uart_instance

Source§

fn clone(&self) -> mss_uart_instance

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for mss_uart_instance

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Copy for mss_uart_instance

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.