pub type R = crate::R<_SMCRrs>;
pub type W = crate::W<_SMCRrs>;
pub type SMS_R = crate::FieldReader;
pub type SMS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type TS_R = crate::FieldReader;
pub type TS_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type MSM_R = crate::BitReader;
pub type MSM_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SMS_3_R = crate::BitReader;
pub type SMS_3_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TS_3_R = crate::BitReader;
pub type TS_3_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TS_4_R = crate::BitReader;
pub type TS_4_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn sms(&self) -> SMS_R {
SMS_R::new((self.bits & 7) as u8)
}
#[inline(always)]
pub fn ts(&self) -> TS_R {
TS_R::new(((self.bits >> 4) & 7) as u8)
}
#[inline(always)]
pub fn msm(&self) -> MSM_R {
MSM_R::new(((self.bits >> 7) & 1) != 0)
}
#[inline(always)]
pub fn sms_3(&self) -> SMS_3_R {
SMS_3_R::new(((self.bits >> 16) & 1) != 0)
}
#[inline(always)]
pub fn ts_3(&self) -> TS_3_R {
TS_3_R::new(((self.bits >> 20) & 1) != 0)
}
#[inline(always)]
pub fn ts_4(&self) -> TS_4_R {
TS_4_R::new(((self.bits >> 21) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("_SMCR")
.field("sms", &self.sms())
.field("ts", &self.ts())
.field("msm", &self.msm())
.field("sms_3", &self.sms_3())
.field("ts_3", &self.ts_3())
.field("ts_4", &self.ts_4())
.finish()
}
}
impl W {
#[inline(always)]
pub fn sms(&mut self) -> SMS_W<_SMCRrs> {
SMS_W::new(self, 0)
}
#[inline(always)]
pub fn ts(&mut self) -> TS_W<_SMCRrs> {
TS_W::new(self, 4)
}
#[inline(always)]
pub fn msm(&mut self) -> MSM_W<_SMCRrs> {
MSM_W::new(self, 7)
}
#[inline(always)]
pub fn sms_3(&mut self) -> SMS_3_W<_SMCRrs> {
SMS_3_W::new(self, 16)
}
#[inline(always)]
pub fn ts_3(&mut self) -> TS_3_W<_SMCRrs> {
TS_3_W::new(self, 20)
}
#[inline(always)]
pub fn ts_4(&mut self) -> TS_4_W<_SMCRrs> {
TS_4_W::new(self, 21)
}
}
pub struct _SMCRrs;
impl crate::RegisterSpec for _SMCRrs {
type Ux = u32;
}
impl crate::Readable for _SMCRrs {}
impl crate::Writable for _SMCRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for _SMCRrs {}