You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
impl<'d,T,M>UartRx<'d,T,M>whereT:Instance,M:Mode,{pubfnread_byte(&mutself) -> nb::Result<u8,Error>{// On the ESP32-S2 we need to use PeriBus2 to read the FIFO:let offset = ifcfg!(esp32s2){0x20C00000}else{0};ifT::get_rx_fifo_count() > 0{let value = unsafe{let fifo = (T::register_block().fifo().as_ptr()as*mutu8).offset(offset)as*mutcrate::peripherals::generic::Reg<FIFO_SPEC>;(*fifo).read().rxfifo_rd_byte().bits()};Ok(value)}else{Err(nb::Error::WouldBlock)}}}
//! ### Examples//!//! #### Sending and Receiving Data//!//! ```no_run//! // Write bytes out over the UART://! uart1.write_bytes("Hello, world!".as_bytes())?;//! ```//!//! #### Splitting the UART into TX and RX Components//!//! ```no_run//! // The UART can be split into separate Transmit and Receive components://! let (mut tx, rx) = uart1.split();//!//! // Each component can be used individually to interact with the UART://! tx.write_bytes(&[42u8])?;//! let byte = rx.read_byte()?;//! ```
just a tiny fix so I have given a pr, you can accept or fix with other change
The text was updated successfully, but these errors were encountered:
At uart.rs, line 466, this function should be public:
Or you should change the document for uart.rs at line 44:
just a tiny fix so I have given a pr, you can accept or fix with other change
The text was updated successfully, but these errors were encountered: