pub type R = crate::R<APB4FZRrs>;
pub type W = crate::W<APB4FZRrs>;
pub type LPTIM2_R = crate::BitReader;
pub type LPTIM2_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type LPTIM3_R = crate::BitReader;
pub type LPTIM3_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type LPTIM4_R = crate::BitReader;
pub type LPTIM4_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type LPTIM5_R = crate::BitReader;
pub type LPTIM5_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type RTC_R = crate::BitReader;
pub type RTC_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type IWDG_R = crate::BitReader;
pub type IWDG_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn lptim2(&self) -> LPTIM2_R {
LPTIM2_R::new(((self.bits >> 9) & 1) != 0)
}
#[inline(always)]
pub fn lptim3(&self) -> LPTIM3_R {
LPTIM3_R::new(((self.bits >> 10) & 1) != 0)
}
#[inline(always)]
pub fn lptim4(&self) -> LPTIM4_R {
LPTIM4_R::new(((self.bits >> 11) & 1) != 0)
}
#[inline(always)]
pub fn lptim5(&self) -> LPTIM5_R {
LPTIM5_R::new(((self.bits >> 12) & 1) != 0)
}
#[inline(always)]
pub fn rtc(&self) -> RTC_R {
RTC_R::new(((self.bits >> 16) & 1) != 0)
}
#[inline(always)]
pub fn iwdg(&self) -> IWDG_R {
IWDG_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("APB4FZR")
.field("lptim2", &self.lptim2())
.field("lptim3", &self.lptim3())
.field("lptim4", &self.lptim4())
.field("lptim5", &self.lptim5())
.field("rtc", &self.rtc())
.field("iwdg", &self.iwdg())
.finish()
}
}
impl W {
#[inline(always)]
pub fn lptim2(&mut self) -> LPTIM2_W<APB4FZRrs> {
LPTIM2_W::new(self, 9)
}
#[inline(always)]
pub fn lptim3(&mut self) -> LPTIM3_W<APB4FZRrs> {
LPTIM3_W::new(self, 10)
}
#[inline(always)]
pub fn lptim4(&mut self) -> LPTIM4_W<APB4FZRrs> {
LPTIM4_W::new(self, 11)
}
#[inline(always)]
pub fn lptim5(&mut self) -> LPTIM5_W<APB4FZRrs> {
LPTIM5_W::new(self, 12)
}
#[inline(always)]
pub fn rtc(&mut self) -> RTC_W<APB4FZRrs> {
RTC_W::new(self, 16)
}
#[inline(always)]
pub fn iwdg(&mut self) -> IWDG_W<APB4FZRrs> {
IWDG_W::new(self, 18)
}
}
pub struct APB4FZRrs;
impl crate::RegisterSpec for APB4FZRrs {
type Ux = u32;
}
impl crate::Readable for APB4FZRrs {}
impl crate::Writable for APB4FZRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for APB4FZRrs {}