pub type R = crate::R<CFGR2rs>;
pub type W = crate::W<CFGR2rs>;
pub type FWDIS_R = crate::BitReader;
pub type FWDIS_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C_PB6_FMP_R = crate::BitReader;
pub type I2C_PB6_FMP_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C_PB7_FMP_R = crate::BitReader;
pub type I2C_PB7_FMP_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C_PB8_FMP_R = crate::BitReader;
pub type I2C_PB8_FMP_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C_PB9_FMP_R = crate::BitReader;
pub type I2C_PB9_FMP_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C1_FMP_R = crate::BitReader;
pub type I2C1_FMP_W<'a, REG> = crate::BitWriter<'a, REG>;
pub type I2C2_FMP_R = crate::BitReader;
pub type I2C2_FMP_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn fwdis(&self) -> FWDIS_R {
FWDIS_R::new((self.bits & 1) != 0)
}
#[inline(always)]
pub fn i2c_pb6_fmp(&self) -> I2C_PB6_FMP_R {
I2C_PB6_FMP_R::new(((self.bits >> 8) & 1) != 0)
}
#[inline(always)]
pub fn i2c_pb7_fmp(&self) -> I2C_PB7_FMP_R {
I2C_PB7_FMP_R::new(((self.bits >> 9) & 1) != 0)
}
#[inline(always)]
pub fn i2c_pb8_fmp(&self) -> I2C_PB8_FMP_R {
I2C_PB8_FMP_R::new(((self.bits >> 10) & 1) != 0)
}
#[inline(always)]
pub fn i2c_pb9_fmp(&self) -> I2C_PB9_FMP_R {
I2C_PB9_FMP_R::new(((self.bits >> 11) & 1) != 0)
}
#[inline(always)]
pub fn i2c1_fmp(&self) -> I2C1_FMP_R {
I2C1_FMP_R::new(((self.bits >> 12) & 1) != 0)
}
#[inline(always)]
pub fn i2c2_fmp(&self) -> I2C2_FMP_R {
I2C2_FMP_R::new(((self.bits >> 13) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("CFGR2")
.field("i2c2_fmp", &self.i2c2_fmp())
.field("i2c1_fmp", &self.i2c1_fmp())
.field("i2c_pb9_fmp", &self.i2c_pb9_fmp())
.field("i2c_pb8_fmp", &self.i2c_pb8_fmp())
.field("i2c_pb7_fmp", &self.i2c_pb7_fmp())
.field("i2c_pb6_fmp", &self.i2c_pb6_fmp())
.field("fwdis", &self.fwdis())
.finish()
}
}
impl W {
#[inline(always)]
pub fn fwdis(&mut self) -> FWDIS_W<CFGR2rs> {
FWDIS_W::new(self, 0)
}
#[inline(always)]
pub fn i2c_pb6_fmp(&mut self) -> I2C_PB6_FMP_W<CFGR2rs> {
I2C_PB6_FMP_W::new(self, 8)
}
#[inline(always)]
pub fn i2c_pb7_fmp(&mut self) -> I2C_PB7_FMP_W<CFGR2rs> {
I2C_PB7_FMP_W::new(self, 9)
}
#[inline(always)]
pub fn i2c_pb8_fmp(&mut self) -> I2C_PB8_FMP_W<CFGR2rs> {
I2C_PB8_FMP_W::new(self, 10)
}
#[inline(always)]
pub fn i2c_pb9_fmp(&mut self) -> I2C_PB9_FMP_W<CFGR2rs> {
I2C_PB9_FMP_W::new(self, 11)
}
#[inline(always)]
pub fn i2c1_fmp(&mut self) -> I2C1_FMP_W<CFGR2rs> {
I2C1_FMP_W::new(self, 12)
}
#[inline(always)]
pub fn i2c2_fmp(&mut self) -> I2C2_FMP_W<CFGR2rs> {
I2C2_FMP_W::new(self, 13)
}
}
pub struct CFGR2rs;
impl crate::RegisterSpec for CFGR2rs {
type Ux = u32;
}
impl crate::Readable for CFGR2rs {}
impl crate::Writable for CFGR2rs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for CFGR2rs {}