pub type R = crate::R<CRrs>;
pub type W = crate::W<CRrs>;
pub type WUCKSEL_R = crate::FieldReader;
pub type WUCKSEL_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type TSEDGE_R = crate::BitReader;
pub type TSEDGE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type REFCKON_R = crate::BitReader;
pub type REFCKON_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type BYPSHAD_R = crate::BitReader;
pub type BYPSHAD_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type FMT_R = crate::BitReader;
pub type FMT_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type ALRE_R = crate::BitReader;
pub type ALRE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type WUTE_R = crate::BitReader;
pub type WUTE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TSE_R = crate::BitReader;
pub type TSE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type ALRIE_R = crate::BitReader;
pub type ALRIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type WUTIE_R = crate::BitReader;
pub type WUTIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TSIE_R = crate::BitReader;
pub type TSIE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type ADD1H_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SUB1H_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type BKP_R = crate::BitReader;
pub type BKP_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type COSEL_R = crate::BitReader;
pub type COSEL_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type POL_R = crate::BitReader;
pub type POL_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OSEL_R = crate::FieldReader;
pub type OSEL_W<'a, REG> = crate::FieldWriter<'a, REG, 2>;
pub type COE_R = crate::BitReader;
pub type COE_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type ITSE_R = crate::BitReader;
pub type ITSE_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn wucksel(&self) -> WUCKSEL_R {
WUCKSEL_R::new((self.bits & 7) as u8)
}
#[inline(always)]
pub fn tsedge(&self) -> TSEDGE_R {
TSEDGE_R::new(((self.bits >> 3) & 1) != 0)
}
#[inline(always)]
pub fn refckon(&self) -> REFCKON_R {
REFCKON_R::new(((self.bits >> 4) & 1) != 0)
}
#[inline(always)]
pub fn bypshad(&self) -> BYPSHAD_R {
BYPSHAD_R::new(((self.bits >> 5) & 1) != 0)
}
#[inline(always)]
pub fn fmt(&self) -> FMT_R {
FMT_R::new(((self.bits >> 6) & 1) != 0)
}
#[inline(always)]
pub fn alre(&self, n: u8) -> ALRE_R {
#[allow(clippy::no_effect)] [(); 2][n as usize];
ALRE_R::new(((self.bits >> (n + 8)) & 1) != 0)
}
#[inline(always)]
pub fn alre_iter(&self) -> impl Iterator<Item = ALRE_R> + '_ {
(0..2).map(move |n| ALRE_R::new(((self.bits >> (n + 8)) & 1) != 0))
}
#[inline(always)]
pub fn alrae(&self) -> ALRE_R {
ALRE_R::new(((self.bits >> 8) & 1) != 0)
}
#[inline(always)]
pub fn alrbe(&self) -> ALRE_R {
ALRE_R::new(((self.bits >> 9) & 1) != 0)
}
#[inline(always)]
pub fn wute(&self) -> WUTE_R {
WUTE_R::new(((self.bits >> 10) & 1) != 0)
}
#[inline(always)]
pub fn tse(&self) -> TSE_R {
TSE_R::new(((self.bits >> 11) & 1) != 0)
}
#[inline(always)]
pub fn alrie(&self, n: u8) -> ALRIE_R {
#[allow(clippy::no_effect)] [(); 2][n as usize];
ALRIE_R::new(((self.bits >> (n + 12)) & 1) != 0)
}
#[inline(always)]
pub fn alrie_iter(&self) -> impl Iterator<Item = ALRIE_R> + '_ {
(0..2).map(move |n| ALRIE_R::new(((self.bits >> (n + 12)) & 1) != 0))
}
#[inline(always)]
pub fn alraie(&self) -> ALRIE_R {
ALRIE_R::new(((self.bits >> 12) & 1) != 0)
}
#[inline(always)]
pub fn alrbie(&self) -> ALRIE_R {
ALRIE_R::new(((self.bits >> 13) & 1) != 0)
}
#[inline(always)]
pub fn wutie(&self) -> WUTIE_R {
WUTIE_R::new(((self.bits >> 14) & 1) != 0)
}
#[inline(always)]
pub fn tsie(&self) -> TSIE_R {
TSIE_R::new(((self.bits >> 15) & 1) != 0)
}
#[inline(always)]
pub fn bkp(&self) -> BKP_R {
BKP_R::new(((self.bits >> 18) & 1) != 0)
}
#[inline(always)]
pub fn cosel(&self) -> COSEL_R {
COSEL_R::new(((self.bits >> 19) & 1) != 0)
}
#[inline(always)]
pub fn pol(&self) -> POL_R {
POL_R::new(((self.bits >> 20) & 1) != 0)
}
#[inline(always)]
pub fn osel(&self) -> OSEL_R {
OSEL_R::new(((self.bits >> 21) & 3) as u8)
}
#[inline(always)]
pub fn coe(&self) -> COE_R {
COE_R::new(((self.bits >> 23) & 1) != 0)
}
#[inline(always)]
pub fn itse(&self) -> ITSE_R {
ITSE_R::new(((self.bits >> 24) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("CR")
.field("wucksel", &self.wucksel())
.field("tsedge", &self.tsedge())
.field("refckon", &self.refckon())
.field("bypshad", &self.bypshad())
.field("fmt", &self.fmt())
.field("alrae", &self.alrae())
.field("alrbe", &self.alrbe())
.field("wute", &self.wute())
.field("tse", &self.tse())
.field("alraie", &self.alraie())
.field("alrbie", &self.alrbie())
.field("wutie", &self.wutie())
.field("tsie", &self.tsie())
.field("bkp", &self.bkp())
.field("cosel", &self.cosel())
.field("pol", &self.pol())
.field("osel", &self.osel())
.field("coe", &self.coe())
.field("itse", &self.itse())
.finish()
}
}
impl W {
#[inline(always)]
pub fn wucksel(&mut self) -> WUCKSEL_W<CRrs> {
WUCKSEL_W::new(self, 0)
}
#[inline(always)]
pub fn tsedge(&mut self) -> TSEDGE_W<CRrs> {
TSEDGE_W::new(self, 3)
}
#[inline(always)]
pub fn refckon(&mut self) -> REFCKON_W<CRrs> {
REFCKON_W::new(self, 4)
}
#[inline(always)]
pub fn bypshad(&mut self) -> BYPSHAD_W<CRrs> {
BYPSHAD_W::new(self, 5)
}
#[inline(always)]
pub fn fmt(&mut self) -> FMT_W<CRrs> {
FMT_W::new(self, 6)
}
#[inline(always)]
pub fn alre(&mut self, n: u8) -> ALRE_W<CRrs> {
#[allow(clippy::no_effect)] [(); 2][n as usize];
ALRE_W::new(self, n + 8)
}
#[inline(always)]
pub fn alrae(&mut self) -> ALRE_W<CRrs> {
ALRE_W::new(self, 8)
}
#[inline(always)]
pub fn alrbe(&mut self) -> ALRE_W<CRrs> {
ALRE_W::new(self, 9)
}
#[inline(always)]
pub fn wute(&mut self) -> WUTE_W<CRrs> {
WUTE_W::new(self, 10)
}
#[inline(always)]
pub fn tse(&mut self) -> TSE_W<CRrs> {
TSE_W::new(self, 11)
}
#[inline(always)]
pub fn alrie(&mut self, n: u8) -> ALRIE_W<CRrs> {
#[allow(clippy::no_effect)] [(); 2][n as usize];
ALRIE_W::new(self, n + 12)
}
#[inline(always)]
pub fn alraie(&mut self) -> ALRIE_W<CRrs> {
ALRIE_W::new(self, 12)
}
#[inline(always)]
pub fn alrbie(&mut self) -> ALRIE_W<CRrs> {
ALRIE_W::new(self, 13)
}
#[inline(always)]
pub fn wutie(&mut self) -> WUTIE_W<CRrs> {
WUTIE_W::new(self, 14)
}
#[inline(always)]
pub fn tsie(&mut self) -> TSIE_W<CRrs> {
TSIE_W::new(self, 15)
}
#[inline(always)]
pub fn add1h(&mut self) -> ADD1H_W<CRrs> {
ADD1H_W::new(self, 16)
}
#[inline(always)]
pub fn sub1h(&mut self) -> SUB1H_W<CRrs> {
SUB1H_W::new(self, 17)
}
#[inline(always)]
pub fn bkp(&mut self) -> BKP_W<CRrs> {
BKP_W::new(self, 18)
}
#[inline(always)]
pub fn cosel(&mut self) -> COSEL_W<CRrs> {
COSEL_W::new(self, 19)
}
#[inline(always)]
pub fn pol(&mut self) -> POL_W<CRrs> {
POL_W::new(self, 20)
}
#[inline(always)]
pub fn osel(&mut self) -> OSEL_W<CRrs> {
OSEL_W::new(self, 21)
}
#[inline(always)]
pub fn coe(&mut self) -> COE_W<CRrs> {
COE_W::new(self, 23)
}
#[inline(always)]
pub fn itse(&mut self) -> ITSE_W<CRrs> {
ITSE_W::new(self, 24)
}
}
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 {}