pub struct Uhci<'d, Dm>where
Dm: DriverMode,{ /* private fields */ }Available on
soc_has_uart0 or soc_has_uart1 or soc_has_uart2 only.Expand description
UHCI (To use with UART over DMA)
Implementations§
Source§impl<'d, Dm> Uhci<'d, Dm>where
Dm: DriverMode,
impl<'d, Dm> Uhci<'d, Dm>where
Dm: DriverMode,
Sourcepub fn set_uart_config(
&mut self,
uart_config: &Config,
) -> Result<(), ConfigError>
pub fn set_uart_config( &mut self, uart_config: &Config, ) -> Result<(), ConfigError>
Sets the config the the consumed UART
Sourcepub fn apply_rx_config(&mut self, config: &RxConfig) -> Result<(), ConfigError>
pub fn apply_rx_config(&mut self, config: &RxConfig) -> Result<(), ConfigError>
Sets the config to the UHCI peripheral, Rx part
Sourcepub fn apply_tx_config(&mut self, config: &TxConfig) -> Result<(), ConfigError>
pub fn apply_tx_config(&mut self, config: &TxConfig) -> Result<(), ConfigError>
Sets the config to the UHCI peripheral, Tx part
Source§impl<'d> Uhci<'d, Blocking>
impl<'d> Uhci<'d, Blocking>
Sourcepub fn new(
uart: Uart<'d, Blocking>,
uhci: UHCI0<'static>,
channel: impl DmaChannelFor<AnyUhci<'d>>,
) -> Self
pub fn new( uart: Uart<'d, Blocking>, uhci: UHCI0<'static>, channel: impl DmaChannelFor<AnyUhci<'d>>, ) -> Self
Creates a new instance of UHCI
Sourcepub fn into_async(self) -> Uhci<'d, Async>
pub fn into_async(self) -> Uhci<'d, Async>
Create a new instance in crate::Async mode.
Source§impl<'d> Uhci<'d, Async>
impl<'d> Uhci<'d, Async>
Sourcepub fn into_blocking(self) -> Uhci<'d, Blocking>
pub fn into_blocking(self) -> Uhci<'d, Blocking>
Create a new instance in crate::Blocking mode.
Trait Implementations§
Source§impl<Dm> SetConfig for Uhci<'_, Dm>where
Dm: DriverMode,
impl<Dm> SetConfig for Uhci<'_, Dm>where
Dm: DriverMode,
Source§type ConfigError = ConfigError
type ConfigError = ConfigError
The error type that can occur if
set_config fails.Source§fn set_config(&mut self, config: &Self::Config) -> Result<(), Self::ConfigError>
fn set_config(&mut self, config: &Self::Config) -> Result<(), Self::ConfigError>
Set the configuration of the driver.