[−][src]Struct msp430fr2x5x_hal::serial::SerialConfig
Builder object for configuring a serial UART
Once the clock source has been selected, the builder can be converted into pins that can transmit or received bytes via a serial connection.
Implementations
impl<USCI: SerialUsci> SerialConfig<USCI, NoClockSet>
[src]
pub fn new(
usci: USCI,
order: BitOrder,
cnt: BitCount,
stopbits: StopBits,
parity: Parity,
loopback: Loopback,
baudrate: u32
) -> Self
[src]
usci: USCI,
order: BitOrder,
cnt: BitCount,
stopbits: StopBits,
parity: Parity,
loopback: Loopback,
baudrate: u32
) -> Self
Create a new serial configuration using a EUSCI peripheral
pub fn use_uclk<P: Into<USCI::ClockPin>>(
self,
_clk_pin: P,
freq: u32
) -> SerialConfig<USCI, ClockSet>
[src]
self,
_clk_pin: P,
freq: u32
) -> SerialConfig<USCI, ClockSet>
Configure serial UART to use external UCLK, passing in the appropriately configured pin used as the clock signal as well as the frequency of the clock.
pub fn use_aclk(self, aclk: &Aclk) -> SerialConfig<USCI, ClockSet>
[src]
Configure serial UART to use ACLK.
pub fn use_smclk(self, smclk: &Smclk) -> SerialConfig<USCI, ClockSet>
[src]
Configure serial UART to use SMCLK.
impl<USCI: SerialUsci> SerialConfig<USCI, ClockSet>
[src]
pub fn split<T: Into<USCI::TxPin>, R: Into<USCI::RxPin>>(
self,
_tx: T,
_rx: R
) -> (Tx<USCI>, Rx<USCI>)
[src]
self,
_tx: T,
_rx: R
) -> (Tx<USCI>, Rx<USCI>)
Perform hardware configuration and split into Tx and Rx pins from appropriate GPIOs
pub fn tx_only<T: Into<USCI::TxPin>>(self, _tx: T) -> Tx<USCI>
[src]
Perform hardware configuration and create Tx pin from appropriate GPIO
pub fn rx_only<R: Into<USCI::RxPin>>(self, _rx: R) -> Rx<USCI>
[src]
Perform hardware configuration and create Rx pin from appropriate GPIO
Auto Trait Implementations
impl<USCI, S> Send for SerialConfig<USCI, S> where
S: Send,
USCI: Send,
[src]
S: Send,
USCI: Send,
impl<USCI, S> Sync for SerialConfig<USCI, S> where
S: Sync,
USCI: Sync,
[src]
S: Sync,
USCI: Sync,
impl<USCI, S> Unpin for SerialConfig<USCI, S> where
S: Unpin,
USCI: Unpin,
[src]
S: Unpin,
USCI: Unpin,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,