pub type R = crate::R<TXDATAXrs>;
pub type W = crate::W<TXDATAXrs>;
pub type TxdataR = crate::FieldReader<u16>;
pub type TxdataW<'a, REG> = crate::FieldWriter<'a, REG, 9, u16>;
pub type TxbreakR = crate::BitReader;
pub type TxbreakW<'a, REG> = crate::BitWriter<'a, REG>;
pub type TxdisatR = crate::BitReader;
pub type TxdisatW<'a, REG> = crate::BitWriter<'a, REG>;
pub type RxenatR = crate::BitReader;
pub type RxenatW<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn txdata(&self) -> TxdataR {
TxdataR::new((self.bits & 0x01ff) as u16)
}
#[inline(always)]
pub fn txbreak(&self) -> TxbreakR {
TxbreakR::new(((self.bits >> 13) & 1) != 0)
}
#[inline(always)]
pub fn txdisat(&self) -> TxdisatR {
TxdisatR::new(((self.bits >> 14) & 1) != 0)
}
#[inline(always)]
pub fn rxenat(&self) -> RxenatR {
RxenatR::new(((self.bits >> 15) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("TXDATAX")
.field("txdata", &self.txdata())
.field("txbreak", &self.txbreak())
.field("txdisat", &self.txdisat())
.field("rxenat", &self.rxenat())
.finish()
}
}
impl W {
#[inline(always)]
pub fn txdata(&mut self) -> TxdataW<'_, TXDATAXrs> {
TxdataW::new(self, 0)
}
#[inline(always)]
pub fn txbreak(&mut self) -> TxbreakW<'_, TXDATAXrs> {
TxbreakW::new(self, 13)
}
#[inline(always)]
pub fn txdisat(&mut self) -> TxdisatW<'_, TXDATAXrs> {
TxdisatW::new(self, 14)
}
#[inline(always)]
pub fn rxenat(&mut self) -> RxenatW<'_, TXDATAXrs> {
RxenatW::new(self, 15)
}
}
pub struct TXDATAXrs;
impl crate::RegisterSpec for TXDATAXrs {
type Ux = u32;
}
impl crate::Readable for TXDATAXrs {}
impl crate::Writable for TXDATAXrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for TXDATAXrs {}