pub type R = crate::R<APB1SMENR1rs>;
pub type W = crate::W<APB1SMENR1rs>;
pub type TIM2SMEN_R = crate::BitReader;
pub type TIM2SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TIM3SMEN_R = crate::BitReader;
pub type TIM3SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TIM4SMEN_R = crate::BitReader;
pub type TIM4SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TIM5SMEN_R = crate::BitReader;
pub type TIM5SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TIM6SMEN_R = crate::BitReader;
pub type TIM6SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type TIM7SMEN_R = crate::BitReader;
pub type TIM7SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type CRSSMEN_R = crate::BitReader;
pub type CRSSMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type RTCAPBSMEN_R = crate::BitReader;
pub type RTCAPBSMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type WWDGSMEN_R = crate::BitReader;
pub type WWDGSMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SPI2SMEN_R = crate::BitReader;
pub type SPI2SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type SPI3SMEN_R = crate::BitReader;
pub type SPI3SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type USART2SMEN_R = crate::BitReader;
pub type USART2SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type USART3SMEN_R = crate::BitReader;
pub type USART3SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type UART4SMEN_R = crate::BitReader;
pub type UART4SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type UART5SMEN_R = crate::BitReader;
pub type UART5SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C1SMEN_R = crate::BitReader;
pub type I2C1SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C2SMEN_R = crate::BitReader;
pub type I2C2SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type USBSMEN_R = crate::BitReader;
pub type USBSMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type FDCANSMEN_R = crate::BitReader;
pub type FDCANSMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type PWRSMEN_R = crate::BitReader;
pub type PWRSMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C3SMEN_R = crate::BitReader;
pub type I2C3SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type LPTIM1SMEN_R = crate::BitReader;
pub type LPTIM1SMEN_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn tim2smen(&self) -> TIM2SMEN_R {
TIM2SMEN_R::new((self.bits & 1) != 0)
}
#[inline(always)]
pub fn tim3smen(&self) -> TIM3SMEN_R {
TIM3SMEN_R::new(((self.bits >> 1) & 1) != 0)
}
#[inline(always)]
pub fn tim4smen(&self) -> TIM4SMEN_R {
TIM4SMEN_R::new(((self.bits >> 2) & 1) != 0)
}
#[inline(always)]
pub fn tim5smen(&self) -> TIM5SMEN_R {
TIM5SMEN_R::new(((self.bits >> 3) & 1) != 0)
}
#[inline(always)]
pub fn tim6smen(&self) -> TIM6SMEN_R {
TIM6SMEN_R::new(((self.bits >> 4) & 1) != 0)
}
#[inline(always)]
pub fn tim7smen(&self) -> TIM7SMEN_R {
TIM7SMEN_R::new(((self.bits >> 5) & 1) != 0)
}
#[inline(always)]
pub fn crssmen(&self) -> CRSSMEN_R {
CRSSMEN_R::new(((self.bits >> 8) & 1) != 0)
}
#[inline(always)]
pub fn rtcapbsmen(&self) -> RTCAPBSMEN_R {
RTCAPBSMEN_R::new(((self.bits >> 10) & 1) != 0)
}
#[inline(always)]
pub fn wwdgsmen(&self) -> WWDGSMEN_R {
WWDGSMEN_R::new(((self.bits >> 11) & 1) != 0)
}
#[inline(always)]
pub fn spi2smen(&self) -> SPI2SMEN_R {
SPI2SMEN_R::new(((self.bits >> 14) & 1) != 0)
}
#[inline(always)]
pub fn spi3smen(&self) -> SPI3SMEN_R {
SPI3SMEN_R::new(((self.bits >> 15) & 1) != 0)
}
#[inline(always)]
pub fn usart2smen(&self) -> USART2SMEN_R {
USART2SMEN_R::new(((self.bits >> 17) & 1) != 0)
}
#[inline(always)]
pub fn usart3smen(&self) -> USART3SMEN_R {
USART3SMEN_R::new(((self.bits >> 18) & 1) != 0)
}
#[inline(always)]
pub fn uart4smen(&self) -> UART4SMEN_R {
UART4SMEN_R::new(((self.bits >> 19) & 1) != 0)
}
#[inline(always)]
pub fn uart5smen(&self) -> UART5SMEN_R {
UART5SMEN_R::new(((self.bits >> 20) & 1) != 0)
}
#[inline(always)]
pub fn i2c1smen(&self) -> I2C1SMEN_R {
I2C1SMEN_R::new(((self.bits >> 21) & 1) != 0)
}
#[inline(always)]
pub fn i2c2smen(&self) -> I2C2SMEN_R {
I2C2SMEN_R::new(((self.bits >> 22) & 1) != 0)
}
#[inline(always)]
pub fn usbsmen(&self) -> USBSMEN_R {
USBSMEN_R::new(((self.bits >> 23) & 1) != 0)
}
#[inline(always)]
pub fn fdcansmen(&self) -> FDCANSMEN_R {
FDCANSMEN_R::new(((self.bits >> 25) & 1) != 0)
}
#[inline(always)]
pub fn pwrsmen(&self) -> PWRSMEN_R {
PWRSMEN_R::new(((self.bits >> 28) & 1) != 0)
}
#[inline(always)]
pub fn i2c3smen(&self) -> I2C3SMEN_R {
I2C3SMEN_R::new(((self.bits >> 30) & 1) != 0)
}
#[inline(always)]
pub fn lptim1smen(&self) -> LPTIM1SMEN_R {
LPTIM1SMEN_R::new(((self.bits >> 31) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("APB1SMENR1")
.field("tim2smen", &self.tim2smen())
.field("tim3smen", &self.tim3smen())
.field("tim4smen", &self.tim4smen())
.field("tim5smen", &self.tim5smen())
.field("tim6smen", &self.tim6smen())
.field("tim7smen", &self.tim7smen())
.field("crssmen", &self.crssmen())
.field("rtcapbsmen", &self.rtcapbsmen())
.field("wwdgsmen", &self.wwdgsmen())
.field("spi2smen", &self.spi2smen())
.field("spi3smen", &self.spi3smen())
.field("usart2smen", &self.usart2smen())
.field("usart3smen", &self.usart3smen())
.field("uart4smen", &self.uart4smen())
.field("uart5smen", &self.uart5smen())
.field("i2c1smen", &self.i2c1smen())
.field("i2c2smen", &self.i2c2smen())
.field("usbsmen", &self.usbsmen())
.field("fdcansmen", &self.fdcansmen())
.field("pwrsmen", &self.pwrsmen())
.field("i2c3smen", &self.i2c3smen())
.field("lptim1smen", &self.lptim1smen())
.finish()
}
}
impl W {
#[inline(always)]
pub fn tim2smen(&mut self) -> TIM2SMEN_W<APB1SMENR1rs> {
TIM2SMEN_W::new(self, 0)
}
#[inline(always)]
pub fn tim3smen(&mut self) -> TIM3SMEN_W<APB1SMENR1rs> {
TIM3SMEN_W::new(self, 1)
}
#[inline(always)]
pub fn tim4smen(&mut self) -> TIM4SMEN_W<APB1SMENR1rs> {
TIM4SMEN_W::new(self, 2)
}
#[inline(always)]
pub fn tim5smen(&mut self) -> TIM5SMEN_W<APB1SMENR1rs> {
TIM5SMEN_W::new(self, 3)
}
#[inline(always)]
pub fn tim6smen(&mut self) -> TIM6SMEN_W<APB1SMENR1rs> {
TIM6SMEN_W::new(self, 4)
}
#[inline(always)]
pub fn tim7smen(&mut self) -> TIM7SMEN_W<APB1SMENR1rs> {
TIM7SMEN_W::new(self, 5)
}
#[inline(always)]
pub fn crssmen(&mut self) -> CRSSMEN_W<APB1SMENR1rs> {
CRSSMEN_W::new(self, 8)
}
#[inline(always)]
pub fn rtcapbsmen(&mut self) -> RTCAPBSMEN_W<APB1SMENR1rs> {
RTCAPBSMEN_W::new(self, 10)
}
#[inline(always)]
pub fn wwdgsmen(&mut self) -> WWDGSMEN_W<APB1SMENR1rs> {
WWDGSMEN_W::new(self, 11)
}
#[inline(always)]
pub fn spi2smen(&mut self) -> SPI2SMEN_W<APB1SMENR1rs> {
SPI2SMEN_W::new(self, 14)
}
#[inline(always)]
pub fn spi3smen(&mut self) -> SPI3SMEN_W<APB1SMENR1rs> {
SPI3SMEN_W::new(self, 15)
}
#[inline(always)]
pub fn usart2smen(&mut self) -> USART2SMEN_W<APB1SMENR1rs> {
USART2SMEN_W::new(self, 17)
}
#[inline(always)]
pub fn usart3smen(&mut self) -> USART3SMEN_W<APB1SMENR1rs> {
USART3SMEN_W::new(self, 18)
}
#[inline(always)]
pub fn uart4smen(&mut self) -> UART4SMEN_W<APB1SMENR1rs> {
UART4SMEN_W::new(self, 19)
}
#[inline(always)]
pub fn uart5smen(&mut self) -> UART5SMEN_W<APB1SMENR1rs> {
UART5SMEN_W::new(self, 20)
}
#[inline(always)]
pub fn i2c1smen(&mut self) -> I2C1SMEN_W<APB1SMENR1rs> {
I2C1SMEN_W::new(self, 21)
}
#[inline(always)]
pub fn i2c2smen(&mut self) -> I2C2SMEN_W<APB1SMENR1rs> {
I2C2SMEN_W::new(self, 22)
}
#[inline(always)]
pub fn usbsmen(&mut self) -> USBSMEN_W<APB1SMENR1rs> {
USBSMEN_W::new(self, 23)
}
#[inline(always)]
pub fn fdcansmen(&mut self) -> FDCANSMEN_W<APB1SMENR1rs> {
FDCANSMEN_W::new(self, 25)
}
#[inline(always)]
pub fn pwrsmen(&mut self) -> PWRSMEN_W<APB1SMENR1rs> {
PWRSMEN_W::new(self, 28)
}
#[inline(always)]
pub fn i2c3smen(&mut self) -> I2C3SMEN_W<APB1SMENR1rs> {
I2C3SMEN_W::new(self, 30)
}
#[inline(always)]
pub fn lptim1smen(&mut self) -> LPTIM1SMEN_W<APB1SMENR1rs> {
LPTIM1SMEN_W::new(self, 31)
}
}
pub struct APB1SMENR1rs;
impl crate::RegisterSpec for APB1SMENR1rs {
type Ux = u32;
}
impl crate::Readable for APB1SMENR1rs {}
impl crate::Writable for APB1SMENR1rs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for APB1SMENR1rs {
const RESET_VALUE: u32 = 0xd2fe_cd3f;
}