pub type R = crate::R<CCCSRrs>;
pub type W = crate::W<CCCSRrs>;
pub type EN_R = crate::BitReader;
pub type EN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type CS_R = crate::BitReader;
pub type CS_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OCTO1_COMP_EN_R = crate::BitReader;
pub type OCTO1_COMP_EN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OCTO1_COMP_CODESEL_R = crate::BitReader;
pub type OCTO1_COMP_CODESEL_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OCTO2_COMP_EN_R = crate::BitReader;
pub type OCTO2_COMP_CODESEL_R = crate::BitReader;
pub type READY_R = crate::BitReader;
pub type OCTO1_COMP_RDY_R = crate::BitReader;
pub type OCTO2_COMP_RDY_R = crate::BitReader;
pub type HSLV_R = crate::BitReader;
pub type HSLV_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OCTO1_IOHSLV_R = crate::BitReader;
pub type OCTO1_IOHSLV_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type OCTO2_IOHSLV_R = crate::BitReader;
pub type OCTO2_IOHSLV_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn en(&self) -> EN_R {
EN_R::new((self.bits & 1) != 0)
}
#[inline(always)]
pub fn cs(&self) -> CS_R {
CS_R::new(((self.bits >> 1) & 1) != 0)
}
#[inline(always)]
pub fn octo1_comp_en(&self) -> OCTO1_COMP_EN_R {
OCTO1_COMP_EN_R::new(((self.bits >> 2) & 1) != 0)
}
#[inline(always)]
pub fn octo1_comp_codesel(&self) -> OCTO1_COMP_CODESEL_R {
OCTO1_COMP_CODESEL_R::new(((self.bits >> 3) & 1) != 0)
}
#[inline(always)]
pub fn octo2_comp_en(&self) -> OCTO2_COMP_EN_R {
OCTO2_COMP_EN_R::new(((self.bits >> 4) & 1) != 0)
}
#[inline(always)]
pub fn octo2_comp_codesel(&self) -> OCTO2_COMP_CODESEL_R {
OCTO2_COMP_CODESEL_R::new(((self.bits >> 5) & 1) != 0)
}
#[inline(always)]
pub fn ready(&self) -> READY_R {
READY_R::new(((self.bits >> 8) & 1) != 0)
}
#[inline(always)]
pub fn octo1_comp_rdy(&self) -> OCTO1_COMP_RDY_R {
OCTO1_COMP_RDY_R::new(((self.bits >> 9) & 1) != 0)
}
#[inline(always)]
pub fn octo2_comp_rdy(&self) -> OCTO2_COMP_RDY_R {
OCTO2_COMP_RDY_R::new(((self.bits >> 10) & 1) != 0)
}
#[inline(always)]
pub fn hslv(&self) -> HSLV_R {
HSLV_R::new(((self.bits >> 16) & 1) != 0)
}
#[inline(always)]
pub fn octo1_iohslv(&self) -> OCTO1_IOHSLV_R {
OCTO1_IOHSLV_R::new(((self.bits >> 17) & 1) != 0)
}
#[inline(always)]
pub fn octo2_iohslv(&self) -> OCTO2_IOHSLV_R {
OCTO2_IOHSLV_R::new(((self.bits >> 18) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("CCCSR")
.field("en", &self.en())
.field("cs", &self.cs())
.field("octo1_comp_en", &self.octo1_comp_en())
.field("octo1_comp_codesel", &self.octo1_comp_codesel())
.field("octo2_comp_en", &self.octo2_comp_en())
.field("octo2_comp_codesel", &self.octo2_comp_codesel())
.field("ready", &self.ready())
.field("octo1_comp_rdy", &self.octo1_comp_rdy())
.field("octo2_comp_rdy", &self.octo2_comp_rdy())
.field("hslv", &self.hslv())
.field("octo1_iohslv", &self.octo1_iohslv())
.field("octo2_iohslv", &self.octo2_iohslv())
.finish()
}
}
impl W {
#[inline(always)]
pub fn en(&mut self) -> EN_W<CCCSRrs> {
EN_W::new(self, 0)
}
#[inline(always)]
pub fn cs(&mut self) -> CS_W<CCCSRrs> {
CS_W::new(self, 1)
}
#[inline(always)]
pub fn octo1_comp_en(&mut self) -> OCTO1_COMP_EN_W<CCCSRrs> {
OCTO1_COMP_EN_W::new(self, 2)
}
#[inline(always)]
pub fn octo1_comp_codesel(&mut self) -> OCTO1_COMP_CODESEL_W<CCCSRrs> {
OCTO1_COMP_CODESEL_W::new(self, 3)
}
#[inline(always)]
pub fn hslv(&mut self) -> HSLV_W<CCCSRrs> {
HSLV_W::new(self, 16)
}
#[inline(always)]
pub fn octo1_iohslv(&mut self) -> OCTO1_IOHSLV_W<CCCSRrs> {
OCTO1_IOHSLV_W::new(self, 17)
}
#[inline(always)]
pub fn octo2_iohslv(&mut self) -> OCTO2_IOHSLV_W<CCCSRrs> {
OCTO2_IOHSLV_W::new(self, 18)
}
}
pub struct CCCSRrs;
impl crate::RegisterSpec for CCCSRrs {
type Ux = u32;
}
impl crate::Readable for CCCSRrs {}
impl crate::Writable for CCCSRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for CCCSRrs {}