pub type R = crate::R<EMR1rs>;
pub type W = crate::W<EMR1rs>;
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum EVENT_MASK {
        Masked = 0,
        Unmasked = 1,
}
impl From<EVENT_MASK> for bool {
    #[inline(always)]
    fn from(variant: EVENT_MASK) -> Self {
        variant as u8 != 0
    }
}
pub type EM0_R = crate::BitReader<EVENT_MASK>;
impl EM0_R {
        #[inline(always)]
    pub const fn variant(&self) -> EVENT_MASK {
        match self.bits {
            false => EVENT_MASK::Masked,
            true => EVENT_MASK::Unmasked,
        }
    }
        #[inline(always)]
    pub fn is_masked(&self) -> bool {
        *self == EVENT_MASK::Masked
    }
        #[inline(always)]
    pub fn is_unmasked(&self) -> bool {
        *self == EVENT_MASK::Unmasked
    }
}
pub type EM0_W<'a, REG> = crate::BitWriter<'a, REG, EVENT_MASK>;
impl<'a, REG> EM0_W<'a, REG>
where
    REG: crate::Writable + crate::RegisterSpec,
{
        #[inline(always)]
    pub fn masked(self) -> &'a mut crate::W<REG> {
        self.variant(EVENT_MASK::Masked)
    }
        #[inline(always)]
    pub fn unmasked(self) -> &'a mut crate::W<REG> {
        self.variant(EVENT_MASK::Unmasked)
    }
}
pub use EM0_R as EM1_R;
pub use EM0_R as EM2_R;
pub use EM0_R as EM3_R;
pub use EM0_R as EM4_R;
pub use EM0_R as EM5_R;
pub use EM0_R as EM6_R;
pub use EM0_R as EM7_R;
pub use EM0_R as EM8_R;
pub use EM0_R as EM9_R;
pub use EM0_R as EM10_R;
pub use EM0_R as EM11_R;
pub use EM0_R as EM12_R;
pub use EM0_R as EM13_R;
pub use EM0_R as EM14_R;
pub use EM0_R as EM15_R;
pub use EM0_R as EM16_R;
pub use EM0_R as EM17_R;
pub use EM0_R as EM18_R;
pub use EM0_R as EM19_R;
pub use EM0_R as EM20_R;
pub use EM0_R as EM21_R;
pub use EM0_R as EM22_R;
pub use EM0_R as EM23_R;
pub use EM0_R as EM24_R;
pub use EM0_R as EM25_R;
pub use EM0_R as EM26_R;
pub use EM0_R as EM27_R;
pub use EM0_R as EM28_R;
pub use EM0_R as EM29_R;
pub use EM0_R as EM30_R;
pub use EM0_R as EM31_R;
pub use EM0_W as EM1_W;
pub use EM0_W as EM2_W;
pub use EM0_W as EM3_W;
pub use EM0_W as EM4_W;
pub use EM0_W as EM5_W;
pub use EM0_W as EM6_W;
pub use EM0_W as EM7_W;
pub use EM0_W as EM8_W;
pub use EM0_W as EM9_W;
pub use EM0_W as EM10_W;
pub use EM0_W as EM11_W;
pub use EM0_W as EM12_W;
pub use EM0_W as EM13_W;
pub use EM0_W as EM14_W;
pub use EM0_W as EM15_W;
pub use EM0_W as EM16_W;
pub use EM0_W as EM17_W;
pub use EM0_W as EM18_W;
pub use EM0_W as EM19_W;
pub use EM0_W as EM20_W;
pub use EM0_W as EM21_W;
pub use EM0_W as EM22_W;
pub use EM0_W as EM23_W;
pub use EM0_W as EM24_W;
pub use EM0_W as EM25_W;
pub use EM0_W as EM26_W;
pub use EM0_W as EM27_W;
pub use EM0_W as EM28_W;
pub use EM0_W as EM29_W;
pub use EM0_W as EM30_W;
pub use EM0_W as EM31_W;
impl R {
        #[inline(always)]
    pub fn em0(&self) -> EM0_R {
        EM0_R::new((self.bits & 1) != 0)
    }
        #[inline(always)]
    pub fn em1(&self) -> EM1_R {
        EM1_R::new(((self.bits >> 1) & 1) != 0)
    }
        #[inline(always)]
    pub fn em2(&self) -> EM2_R {
        EM2_R::new(((self.bits >> 2) & 1) != 0)
    }
        #[inline(always)]
    pub fn em3(&self) -> EM3_R {
        EM3_R::new(((self.bits >> 3) & 1) != 0)
    }
        #[inline(always)]
    pub fn em4(&self) -> EM4_R {
        EM4_R::new(((self.bits >> 4) & 1) != 0)
    }
        #[inline(always)]
    pub fn em5(&self) -> EM5_R {
        EM5_R::new(((self.bits >> 5) & 1) != 0)
    }
        #[inline(always)]
    pub fn em6(&self) -> EM6_R {
        EM6_R::new(((self.bits >> 6) & 1) != 0)
    }
        #[inline(always)]
    pub fn em7(&self) -> EM7_R {
        EM7_R::new(((self.bits >> 7) & 1) != 0)
    }
        #[inline(always)]
    pub fn em8(&self) -> EM8_R {
        EM8_R::new(((self.bits >> 8) & 1) != 0)
    }
        #[inline(always)]
    pub fn em9(&self) -> EM9_R {
        EM9_R::new(((self.bits >> 9) & 1) != 0)
    }
        #[inline(always)]
    pub fn em10(&self) -> EM10_R {
        EM10_R::new(((self.bits >> 10) & 1) != 0)
    }
        #[inline(always)]
    pub fn em11(&self) -> EM11_R {
        EM11_R::new(((self.bits >> 11) & 1) != 0)
    }
        #[inline(always)]
    pub fn em12(&self) -> EM12_R {
        EM12_R::new(((self.bits >> 12) & 1) != 0)
    }
        #[inline(always)]
    pub fn em13(&self) -> EM13_R {
        EM13_R::new(((self.bits >> 13) & 1) != 0)
    }
        #[inline(always)]
    pub fn em14(&self) -> EM14_R {
        EM14_R::new(((self.bits >> 14) & 1) != 0)
    }
        #[inline(always)]
    pub fn em15(&self) -> EM15_R {
        EM15_R::new(((self.bits >> 15) & 1) != 0)
    }
        #[inline(always)]
    pub fn em16(&self) -> EM16_R {
        EM16_R::new(((self.bits >> 16) & 1) != 0)
    }
        #[inline(always)]
    pub fn em17(&self) -> EM17_R {
        EM17_R::new(((self.bits >> 17) & 1) != 0)
    }
        #[inline(always)]
    pub fn em18(&self) -> EM18_R {
        EM18_R::new(((self.bits >> 18) & 1) != 0)
    }
        #[inline(always)]
    pub fn em19(&self) -> EM19_R {
        EM19_R::new(((self.bits >> 19) & 1) != 0)
    }
        #[inline(always)]
    pub fn em20(&self) -> EM20_R {
        EM20_R::new(((self.bits >> 20) & 1) != 0)
    }
        #[inline(always)]
    pub fn em21(&self) -> EM21_R {
        EM21_R::new(((self.bits >> 21) & 1) != 0)
    }
        #[inline(always)]
    pub fn em22(&self) -> EM22_R {
        EM22_R::new(((self.bits >> 22) & 1) != 0)
    }
        #[inline(always)]
    pub fn em23(&self) -> EM23_R {
        EM23_R::new(((self.bits >> 23) & 1) != 0)
    }
        #[inline(always)]
    pub fn em24(&self) -> EM24_R {
        EM24_R::new(((self.bits >> 24) & 1) != 0)
    }
        #[inline(always)]
    pub fn em25(&self) -> EM25_R {
        EM25_R::new(((self.bits >> 25) & 1) != 0)
    }
        #[inline(always)]
    pub fn em26(&self) -> EM26_R {
        EM26_R::new(((self.bits >> 26) & 1) != 0)
    }
        #[inline(always)]
    pub fn em27(&self) -> EM27_R {
        EM27_R::new(((self.bits >> 27) & 1) != 0)
    }
        #[inline(always)]
    pub fn em28(&self) -> EM28_R {
        EM28_R::new(((self.bits >> 28) & 1) != 0)
    }
        #[inline(always)]
    pub fn em29(&self) -> EM29_R {
        EM29_R::new(((self.bits >> 29) & 1) != 0)
    }
        #[inline(always)]
    pub fn em30(&self) -> EM30_R {
        EM30_R::new(((self.bits >> 30) & 1) != 0)
    }
        #[inline(always)]
    pub fn em31(&self) -> EM31_R {
        EM31_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("EMR1")
            .field("em0", &self.em0())
            .field("em1", &self.em1())
            .field("em2", &self.em2())
            .field("em3", &self.em3())
            .field("em4", &self.em4())
            .field("em5", &self.em5())
            .field("em6", &self.em6())
            .field("em7", &self.em7())
            .field("em8", &self.em8())
            .field("em9", &self.em9())
            .field("em10", &self.em10())
            .field("em11", &self.em11())
            .field("em12", &self.em12())
            .field("em13", &self.em13())
            .field("em14", &self.em14())
            .field("em15", &self.em15())
            .field("em16", &self.em16())
            .field("em17", &self.em17())
            .field("em18", &self.em18())
            .field("em19", &self.em19())
            .field("em20", &self.em20())
            .field("em21", &self.em21())
            .field("em22", &self.em22())
            .field("em23", &self.em23())
            .field("em24", &self.em24())
            .field("em25", &self.em25())
            .field("em26", &self.em26())
            .field("em27", &self.em27())
            .field("em28", &self.em28())
            .field("em29", &self.em29())
            .field("em30", &self.em30())
            .field("em31", &self.em31())
            .finish()
    }
}
impl W {
        #[inline(always)]
    pub fn em0(&mut self) -> EM0_W<EMR1rs> {
        EM0_W::new(self, 0)
    }
        #[inline(always)]
    pub fn em1(&mut self) -> EM1_W<EMR1rs> {
        EM1_W::new(self, 1)
    }
        #[inline(always)]
    pub fn em2(&mut self) -> EM2_W<EMR1rs> {
        EM2_W::new(self, 2)
    }
        #[inline(always)]
    pub fn em3(&mut self) -> EM3_W<EMR1rs> {
        EM3_W::new(self, 3)
    }
        #[inline(always)]
    pub fn em4(&mut self) -> EM4_W<EMR1rs> {
        EM4_W::new(self, 4)
    }
        #[inline(always)]
    pub fn em5(&mut self) -> EM5_W<EMR1rs> {
        EM5_W::new(self, 5)
    }
        #[inline(always)]
    pub fn em6(&mut self) -> EM6_W<EMR1rs> {
        EM6_W::new(self, 6)
    }
        #[inline(always)]
    pub fn em7(&mut self) -> EM7_W<EMR1rs> {
        EM7_W::new(self, 7)
    }
        #[inline(always)]
    pub fn em8(&mut self) -> EM8_W<EMR1rs> {
        EM8_W::new(self, 8)
    }
        #[inline(always)]
    pub fn em9(&mut self) -> EM9_W<EMR1rs> {
        EM9_W::new(self, 9)
    }
        #[inline(always)]
    pub fn em10(&mut self) -> EM10_W<EMR1rs> {
        EM10_W::new(self, 10)
    }
        #[inline(always)]
    pub fn em11(&mut self) -> EM11_W<EMR1rs> {
        EM11_W::new(self, 11)
    }
        #[inline(always)]
    pub fn em12(&mut self) -> EM12_W<EMR1rs> {
        EM12_W::new(self, 12)
    }
        #[inline(always)]
    pub fn em13(&mut self) -> EM13_W<EMR1rs> {
        EM13_W::new(self, 13)
    }
        #[inline(always)]
    pub fn em14(&mut self) -> EM14_W<EMR1rs> {
        EM14_W::new(self, 14)
    }
        #[inline(always)]
    pub fn em15(&mut self) -> EM15_W<EMR1rs> {
        EM15_W::new(self, 15)
    }
        #[inline(always)]
    pub fn em16(&mut self) -> EM16_W<EMR1rs> {
        EM16_W::new(self, 16)
    }
        #[inline(always)]
    pub fn em17(&mut self) -> EM17_W<EMR1rs> {
        EM17_W::new(self, 17)
    }
        #[inline(always)]
    pub fn em18(&mut self) -> EM18_W<EMR1rs> {
        EM18_W::new(self, 18)
    }
        #[inline(always)]
    pub fn em19(&mut self) -> EM19_W<EMR1rs> {
        EM19_W::new(self, 19)
    }
        #[inline(always)]
    pub fn em20(&mut self) -> EM20_W<EMR1rs> {
        EM20_W::new(self, 20)
    }
        #[inline(always)]
    pub fn em21(&mut self) -> EM21_W<EMR1rs> {
        EM21_W::new(self, 21)
    }
        #[inline(always)]
    pub fn em22(&mut self) -> EM22_W<EMR1rs> {
        EM22_W::new(self, 22)
    }
        #[inline(always)]
    pub fn em23(&mut self) -> EM23_W<EMR1rs> {
        EM23_W::new(self, 23)
    }
        #[inline(always)]
    pub fn em24(&mut self) -> EM24_W<EMR1rs> {
        EM24_W::new(self, 24)
    }
        #[inline(always)]
    pub fn em25(&mut self) -> EM25_W<EMR1rs> {
        EM25_W::new(self, 25)
    }
        #[inline(always)]
    pub fn em26(&mut self) -> EM26_W<EMR1rs> {
        EM26_W::new(self, 26)
    }
        #[inline(always)]
    pub fn em27(&mut self) -> EM27_W<EMR1rs> {
        EM27_W::new(self, 27)
    }
        #[inline(always)]
    pub fn em28(&mut self) -> EM28_W<EMR1rs> {
        EM28_W::new(self, 28)
    }
        #[inline(always)]
    pub fn em29(&mut self) -> EM29_W<EMR1rs> {
        EM29_W::new(self, 29)
    }
        #[inline(always)]
    pub fn em30(&mut self) -> EM30_W<EMR1rs> {
        EM30_W::new(self, 30)
    }
        #[inline(always)]
    pub fn em31(&mut self) -> EM31_W<EMR1rs> {
        EM31_W::new(self, 31)
    }
}
pub struct EMR1rs;
impl crate::RegisterSpec for EMR1rs {
    type Ux = u32;
}
impl crate::Readable for EMR1rs {}
impl crate::Writable for EMR1rs {
    type Safety = crate::Unsafe;
}
impl crate::Resettable for EMR1rs {}