Struct stm32h7xx_hal::serial::Rx

source ·
pub struct Rx<USART> { /* private fields */ }
Expand description

Serial receiver

Implementations§

source§

impl Rx<USART1>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<USART2>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<USART3>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<USART6>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<UART4>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<UART5>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<UART7>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

source§

impl Rx<UART8>

source

pub fn listen(&mut self)

Start listening for Rxne event

source

pub fn unlisten(&mut self)

Stop listening for Rxne event

source

pub fn enable_dma_rx(&mut self)

Enables the Rx DMA stream.

source

pub fn disable_dma_rx(&mut self)

Disables the Rx DMA stream.

source

pub fn is_idle(&self) -> bool

Return true if the line idle status is set

The line idle status bit is set when the peripheral detects the receive line is idle. The bit is cleared by software, by calling clear_idle().

source

pub fn clear_idle(&mut self)

Clear the line idle status bit

source

pub fn is_busy(&self) -> bool

Return true if the line busy status is set

The busy status bit is set when there is communication active on the receive line, and reset at the end of reception.

source

pub fn is_rxne(&self) -> bool

Return true if the rx register is not empty (and can be read)

Trait Implementations§

source§

impl TargetAddress<PeripheralToMemory> for Rx<UART4>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<UART5>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<UART7>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<UART8>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<USART1>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<USART2>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<USART3>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl TargetAddress<PeripheralToMemory> for Rx<USART6>

source§

fn address(&self) -> usize

The address to be used by the DMA stream
§

type MemSize = u8

Memory size of the target address
source§

const REQUEST_LINE: Option<u8> = _

An optional associated request line
source§

const TRBUFF: bool = true

Mark that the TRBUFF bit must be set for this target
source§

impl Read<u8> for Rx<UART4>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<UART5>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<UART7>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<UART8>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<USART1>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<USART2>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<USART3>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface
source§

impl Read<u8> for Rx<USART6>

§

type Error = Error

Read error
source§

fn read(&mut self) -> Result<u8, Error>

Reads a single word from the serial interface

Auto Trait Implementations§

§

impl<USART> Freeze for Rx<USART>

§

impl<USART> RefUnwindSafe for Rx<USART>
where USART: RefUnwindSafe,

§

impl<USART> Send for Rx<USART>
where USART: Send,

§

impl<USART> Sync for Rx<USART>
where USART: Sync,

§

impl<USART> Unpin for Rx<USART>
where USART: Unpin,

§

impl<USART> UnwindSafe for Rx<USART>
where USART: UnwindSafe,

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> 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>,

§

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>,

§

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.