pub type R = crate::R<CGCRrs>;
pub type W = crate::W<CGCRrs>;
pub type LCS_R = crate::FieldReader;
pub type LCS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type LCCCS_R = crate::BitReader;
pub type LCCCS_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type LCCFR_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type LCCHRS_R = crate::FieldReader;
pub type LCCHRS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type FCS_R = crate::FieldReader;
pub type FCS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type FCCCS_R = crate::FieldReader;
pub type FCCCS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type FCCFR_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type FCCHRS_R = crate::FieldReader;
pub type FCCHRS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
impl R {
#[inline(always)]
pub fn lcs(&self) -> LCS_R {
LCS_R::new((self.bits & 7) as u8)
}
#[inline(always)]
pub fn lcccs(&self) -> LCCCS_R {
LCCCS_R::new(((self.bits >> 4) & 1) != 0)
}
#[inline(always)]
pub fn lcchrs(&self) -> LCCHRS_R {
LCCHRS_R::new(((self.bits >> 12) & 7) as u8)
}
#[inline(always)]
pub fn fcs(&self) -> FCS_R {
FCS_R::new(((self.bits >> 16) & 7) as u8)
}
#[inline(always)]
pub fn fcccs(&self) -> FCCCS_R {
FCCCS_R::new(((self.bits >> 20) & 7) as u8)
}
#[inline(always)]
pub fn fcchrs(&self) -> FCCHRS_R {
FCCHRS_R::new(((self.bits >> 28) & 7) as u8)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("CGCR")
.field("lcs", &self.lcs())
.field("lcccs", &self.lcccs())
.field("lcchrs", &self.lcchrs())
.field("fcs", &self.fcs())
.field("fcccs", &self.fcccs())
.field("fcchrs", &self.fcchrs())
.finish()
}
}
impl W {
#[inline(always)]
pub fn lcs(&mut self) -> LCS_W<CGCRrs> {
LCS_W::new(self, 0)
}
#[inline(always)]
pub fn lcccs(&mut self) -> LCCCS_W<CGCRrs> {
LCCCS_W::new(self, 4)
}
#[inline(always)]
pub fn lccfr(&mut self) -> LCCFR_W<CGCRrs> {
LCCFR_W::new(self, 8)
}
#[inline(always)]
pub fn lcchrs(&mut self) -> LCCHRS_W<CGCRrs> {
LCCHRS_W::new(self, 12)
}
#[inline(always)]
pub fn fcs(&mut self) -> FCS_W<CGCRrs> {
FCS_W::new(self, 16)
}
#[inline(always)]
pub fn fcccs(&mut self) -> FCCCS_W<CGCRrs> {
FCCCS_W::new(self, 20)
}
#[inline(always)]
pub fn fccfr(&mut self) -> FCCFR_W<CGCRrs> {
FCCFR_W::new(self, 24)
}
#[inline(always)]
pub fn fcchrs(&mut self) -> FCCHRS_W<CGCRrs> {
FCCHRS_W::new(self, 28)
}
}
pub struct CGCRrs;
impl crate::RegisterSpec for CGCRrs {
type Ux = u32;
}
impl crate::Readable for CGCRrs {}
impl crate::Writable for CGCRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for CGCRrs {}