pub type R = crate::R<TIMINGRrs>;
pub type W = crate::W<TIMINGRrs>;
pub type SCLL_R = crate::FieldReader;
pub type SCLL_W<'a, REG> = crate::FieldWriter<'a, REG, 8, u8, crate::Safe>;
pub type SCLH_R = crate::FieldReader;
pub type SCLH_W<'a, REG> = crate::FieldWriter<'a, REG, 8, u8, crate::Safe>;
pub type SDADEL_R = crate::FieldReader;
pub type SDADEL_W<'a, REG> = crate::FieldWriter<'a, REG, 4, u8, crate::Safe>;
pub type SCLDEL_R = crate::FieldReader;
pub type SCLDEL_W<'a, REG> = crate::FieldWriter<'a, REG, 4, u8, crate::Safe>;
pub type PRESC_R = crate::FieldReader;
pub type PRESC_W<'a, REG> = crate::FieldWriter<'a, REG, 4, u8, crate::Safe>;
impl R {
#[inline(always)]
pub fn scll(&self) -> SCLL_R {
SCLL_R::new((self.bits & 0xff) as u8)
}
#[inline(always)]
pub fn sclh(&self) -> SCLH_R {
SCLH_R::new(((self.bits >> 8) & 0xff) as u8)
}
#[inline(always)]
pub fn sdadel(&self) -> SDADEL_R {
SDADEL_R::new(((self.bits >> 16) & 0x0f) as u8)
}
#[inline(always)]
pub fn scldel(&self) -> SCLDEL_R {
SCLDEL_R::new(((self.bits >> 20) & 0x0f) as u8)
}
#[inline(always)]
pub fn presc(&self) -> PRESC_R {
PRESC_R::new(((self.bits >> 28) & 0x0f) as u8)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("TIMINGR")
.field("scll", &self.scll())
.field("sclh", &self.sclh())
.field("sdadel", &self.sdadel())
.field("scldel", &self.scldel())
.field("presc", &self.presc())
.finish()
}
}
impl W {
#[inline(always)]
pub fn scll(&mut self) -> SCLL_W<TIMINGRrs> {
SCLL_W::new(self, 0)
}
#[inline(always)]
pub fn sclh(&mut self) -> SCLH_W<TIMINGRrs> {
SCLH_W::new(self, 8)
}
#[inline(always)]
pub fn sdadel(&mut self) -> SDADEL_W<TIMINGRrs> {
SDADEL_W::new(self, 16)
}
#[inline(always)]
pub fn scldel(&mut self) -> SCLDEL_W<TIMINGRrs> {
SCLDEL_W::new(self, 20)
}
#[inline(always)]
pub fn presc(&mut self) -> PRESC_W<TIMINGRrs> {
PRESC_W::new(self, 28)
}
}
pub struct TIMINGRrs;
impl crate::RegisterSpec for TIMINGRrs {
type Ux = u32;
}
impl crate::Readable for TIMINGRrs {}
impl crate::Writable for TIMINGRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for TIMINGRrs {}