pub type W = crate::W<SWTRIGRrs>;
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum SWTRIG1 {
        Disabled = 0,
        Enabled = 1,
}
impl From<SWTRIG1> for bool {
    #[inline(always)]
    fn from(variant: SWTRIG1) -> Self {
        variant as u8 != 0
    }
}
pub type SWTRIG_W<'a, REG> = crate::BitWriter<'a, REG, SWTRIG1>;
impl<'a, REG> SWTRIG_W<'a, REG>
where
    REG: crate::Writable + crate::RegisterSpec,
{
        #[inline(always)]
    pub fn disabled(self) -> &'a mut crate::W<REG> {
        self.variant(SWTRIG1::Disabled)
    }
        #[inline(always)]
    pub fn enabled(self) -> &'a mut crate::W<REG> {
        self.variant(SWTRIG1::Enabled)
    }
}
impl core::fmt::Debug for crate::generic::Reg<SWTRIGRrs> {
    fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
        write!(f, "(not readable)")
    }
}
impl W {
                #[inline(always)]
    pub fn swtrig(&mut self, n: u8) -> SWTRIG_W<SWTRIGRrs> {
        #[allow(clippy::no_effect)]
        [(); 2][n as usize];
        SWTRIG_W::new(self, n)
    }
        #[inline(always)]
    pub fn swtrig1(&mut self) -> SWTRIG_W<SWTRIGRrs> {
        SWTRIG_W::new(self, 0)
    }
        #[inline(always)]
    pub fn swtrig2(&mut self) -> SWTRIG_W<SWTRIGRrs> {
        SWTRIG_W::new(self, 1)
    }
}
pub struct SWTRIGRrs;
impl crate::RegisterSpec for SWTRIGRrs {
    type Ux = u32;
}
impl crate::Writable for SWTRIGRrs {
    type Safety = crate::Unsafe;
}
impl crate::Resettable for SWTRIGRrs {}