pub type R = crate::R<CRrs>;
pub type W = crate::W<CRrs>;
pub type LOCK_R = crate::BitReader;
pub type LOCK_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type PG_R = crate::BitReader;
pub type PG_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SER_R = crate::BitReader;
pub type SER_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type BER_R = crate::BitReader;
pub type BER_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type PSIZE_R = crate::FieldReader;
pub type PSIZE_W<'a, REG> = crate::FieldWriter<'a, REG, 2>;
pub type FW_R = crate::BitReader;
pub type FW_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type START_R = crate::BitReader;
pub type START_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SNB_R = crate::FieldReader;
pub type SNB_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type CRC_EN_R = crate::BitReader;
pub type CRC_EN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type EOPIE_R = crate::BitReader;
pub type EOPIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type WRPERRIE_R = crate::BitReader;
pub type WRPERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type PGSERRIE_R = crate::BitReader;
pub type PGSERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type STRBERRIE_R = crate::BitReader;
pub type STRBERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type INCERRIE_R = crate::BitReader;
pub type INCERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OPERRIE_R = crate::BitReader;
pub type OPERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type RDPERRIE_R = crate::BitReader;
pub type RDPERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type RDSERRIE_R = crate::BitReader;
pub type RDSERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SNECCERRIE_R = crate::BitReader;
pub type SNECCERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type DBECCERRIE_R = crate::BitReader;
pub type DBECCERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type CRCENDIE_R = crate::BitReader;
pub type CRCENDIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type CRCRDERRIE_R = crate::BitReader;
pub type CRCRDERRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn lock(&self) -> LOCK_R {
LOCK_R::new((self.bits & 1) != 0)
}
#[inline(always)]
pub fn pg(&self) -> PG_R {
PG_R::new(((self.bits >> 1) & 1) != 0)
}
#[inline(always)]
pub fn ser(&self) -> SER_R {
SER_R::new(((self.bits >> 2) & 1) != 0)
}
#[inline(always)]
pub fn ber(&self) -> BER_R {
BER_R::new(((self.bits >> 3) & 1) != 0)
}
#[inline(always)]
pub fn psize(&self) -> PSIZE_R {
PSIZE_R::new(((self.bits >> 4) & 3) as u8)
}
#[inline(always)]
pub fn fw(&self) -> FW_R {
FW_R::new(((self.bits >> 6) & 1) != 0)
}
#[inline(always)]
pub fn start(&self) -> START_R {
START_R::new(((self.bits >> 7) & 1) != 0)
}
#[inline(always)]
pub fn snb(&self) -> SNB_R {
SNB_R::new(((self.bits >> 8) & 7) as u8)
}
#[inline(always)]
pub fn crc_en(&self) -> CRC_EN_R {
CRC_EN_R::new(((self.bits >> 15) & 1) != 0)
}
#[inline(always)]
pub fn eopie(&self) -> EOPIE_R {
EOPIE_R::new(((self.bits >> 16) & 1) != 0)
}
#[inline(always)]
pub fn wrperrie(&self) -> WRPERRIE_R {
WRPERRIE_R::new(((self.bits >> 17) & 1) != 0)
}
#[inline(always)]
pub fn pgserrie(&self) -> PGSERRIE_R {
PGSERRIE_R::new(((self.bits >> 18) & 1) != 0)
}
#[inline(always)]
pub fn strberrie(&self) -> STRBERRIE_R {
STRBERRIE_R::new(((self.bits >> 19) & 1) != 0)
}
#[inline(always)]
pub fn incerrie(&self) -> INCERRIE_R {
INCERRIE_R::new(((self.bits >> 21) & 1) != 0)
}
#[inline(always)]
pub fn operrie(&self) -> OPERRIE_R {
OPERRIE_R::new(((self.bits >> 22) & 1) != 0)
}
#[inline(always)]
pub fn rdperrie(&self) -> RDPERRIE_R {
RDPERRIE_R::new(((self.bits >> 23) & 1) != 0)
}
#[inline(always)]
pub fn rdserrie(&self) -> RDSERRIE_R {
RDSERRIE_R::new(((self.bits >> 24) & 1) != 0)
}
#[inline(always)]
pub fn sneccerrie(&self) -> SNECCERRIE_R {
SNECCERRIE_R::new(((self.bits >> 25) & 1) != 0)
}
#[inline(always)]
pub fn dbeccerrie(&self) -> DBECCERRIE_R {
DBECCERRIE_R::new(((self.bits >> 26) & 1) != 0)
}
#[inline(always)]
pub fn crcendie(&self) -> CRCENDIE_R {
CRCENDIE_R::new(((self.bits >> 27) & 1) != 0)
}
#[inline(always)]
pub fn crcrderrie(&self) -> CRCRDERRIE_R {
CRCRDERRIE_R::new(((self.bits >> 28) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("CR")
.field("lock", &self.lock())
.field("pg", &self.pg())
.field("ser", &self.ser())
.field("ber", &self.ber())
.field("psize", &self.psize())
.field("fw", &self.fw())
.field("start", &self.start())
.field("snb", &self.snb())
.field("crc_en", &self.crc_en())
.field("eopie", &self.eopie())
.field("wrperrie", &self.wrperrie())
.field("pgserrie", &self.pgserrie())
.field("strberrie", &self.strberrie())
.field("incerrie", &self.incerrie())
.field("operrie", &self.operrie())
.field("rdperrie", &self.rdperrie())
.field("rdserrie", &self.rdserrie())
.field("sneccerrie", &self.sneccerrie())
.field("dbeccerrie", &self.dbeccerrie())
.field("crcendie", &self.crcendie())
.field("crcrderrie", &self.crcrderrie())
.finish()
}
}
impl W {
#[inline(always)]
pub fn lock(&mut self) -> LOCK_W<CRrs> {
LOCK_W::new(self, 0)
}
#[inline(always)]
pub fn pg(&mut self) -> PG_W<CRrs> {
PG_W::new(self, 1)
}
#[inline(always)]
pub fn ser(&mut self) -> SER_W<CRrs> {
SER_W::new(self, 2)
}
#[inline(always)]
pub fn ber(&mut self) -> BER_W<CRrs> {
BER_W::new(self, 3)
}
#[inline(always)]
pub fn psize(&mut self) -> PSIZE_W<CRrs> {
PSIZE_W::new(self, 4)
}
#[inline(always)]
pub fn fw(&mut self) -> FW_W<CRrs> {
FW_W::new(self, 6)
}
#[inline(always)]
pub fn start(&mut self) -> START_W<CRrs> {
START_W::new(self, 7)
}
#[inline(always)]
pub fn snb(&mut self) -> SNB_W<CRrs> {
SNB_W::new(self, 8)
}
#[inline(always)]
pub fn crc_en(&mut self) -> CRC_EN_W<CRrs> {
CRC_EN_W::new(self, 15)
}
#[inline(always)]
pub fn eopie(&mut self) -> EOPIE_W<CRrs> {
EOPIE_W::new(self, 16)
}
#[inline(always)]
pub fn wrperrie(&mut self) -> WRPERRIE_W<CRrs> {
WRPERRIE_W::new(self, 17)
}
#[inline(always)]
pub fn pgserrie(&mut self) -> PGSERRIE_W<CRrs> {
PGSERRIE_W::new(self, 18)
}
#[inline(always)]
pub fn strberrie(&mut self) -> STRBERRIE_W<CRrs> {
STRBERRIE_W::new(self, 19)
}
#[inline(always)]
pub fn incerrie(&mut self) -> INCERRIE_W<CRrs> {
INCERRIE_W::new(self, 21)
}
#[inline(always)]
pub fn operrie(&mut self) -> OPERRIE_W<CRrs> {
OPERRIE_W::new(self, 22)
}
#[inline(always)]
pub fn rdperrie(&mut self) -> RDPERRIE_W<CRrs> {
RDPERRIE_W::new(self, 23)
}
#[inline(always)]
pub fn rdserrie(&mut self) -> RDSERRIE_W<CRrs> {
RDSERRIE_W::new(self, 24)
}
#[inline(always)]
pub fn sneccerrie(&mut self) -> SNECCERRIE_W<CRrs> {
SNECCERRIE_W::new(self, 25)
}
#[inline(always)]
pub fn dbeccerrie(&mut self) -> DBECCERRIE_W<CRrs> {
DBECCERRIE_W::new(self, 26)
}
#[inline(always)]
pub fn crcendie(&mut self) -> CRCENDIE_W<CRrs> {
CRCENDIE_W::new(self, 27)
}
#[inline(always)]
pub fn crcrderrie(&mut self) -> CRCRDERRIE_W<CRrs> {
CRCRDERRIE_W::new(self, 28)
}
}
pub struct CRrs;
impl crate::RegisterSpec for CRrs {
type Ux = u32;
}
impl crate::Readable for CRrs {}
impl crate::Writable for CRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for CRrs {}