efm32pg12b500_pac/emu/
em23pernoretaincmd.rs

1#[doc = "Register `EM23PERNORETAINCMD` writer"]
2pub struct W(crate::W<EM23PERNORETAINCMD_SPEC>);
3impl core::ops::Deref for W {
4    type Target = crate::W<EM23PERNORETAINCMD_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl core::ops::DerefMut for W {
11    #[inline(always)]
12    fn deref_mut(&mut self) -> &mut Self::Target {
13        &mut self.0
14    }
15}
16impl From<crate::W<EM23PERNORETAINCMD_SPEC>> for W {
17    #[inline(always)]
18    fn from(writer: crate::W<EM23PERNORETAINCMD_SPEC>) -> Self {
19        W(writer)
20    }
21}
22#[doc = "Field `ACMP0UNLOCK` writer - Clears Status Bit of ACMP0 and Unlocks Access to It"]
23pub type ACMP0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 0>;
24#[doc = "Field `ACMP1UNLOCK` writer - Clears Status Bit of ACMP1 and Unlocks Access to It"]
25pub type ACMP1UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 1>;
26#[doc = "Field `PCNT0UNLOCK` writer - Clears Status Bit of PCNT0 and Unlocks Access to It"]
27pub type PCNT0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 2>;
28#[doc = "Field `PCNT1UNLOCK` writer - Clears Status Bit of PCNT1 and Unlocks Access to It"]
29pub type PCNT1UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 3>;
30#[doc = "Field `PCNT2UNLOCK` writer - Clears Status Bit of PCNT2 and Unlocks Access to It"]
31pub type PCNT2UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 4>;
32#[doc = "Field `I2C0UNLOCK` writer - Clears Status Bit of I2C0 and Unlocks Access to It"]
33pub type I2C0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 5>;
34#[doc = "Field `I2C1UNLOCK` writer - Clears Status Bit of I2C1 and Unlocks Access to It"]
35pub type I2C1UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 6>;
36#[doc = "Field `DAC0UNLOCK` writer - Clears Status Bit of DAC0 and Unlocks Access to It"]
37pub type DAC0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 7>;
38#[doc = "Field `IDAC0UNLOCK` writer - Clears Status Bit of IDAC0 and Unlocks Access to It"]
39pub type IDAC0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 8>;
40#[doc = "Field `ADC0UNLOCK` writer - Clears Status Bit of ADC0 and Unlocks Access to It"]
41pub type ADC0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 9>;
42#[doc = "Field `LETIMER0UNLOCK` writer - Clears Status Bit of LETIMER0 and Unlocks Access to It"]
43pub type LETIMER0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 10>;
44#[doc = "Field `WDOG0UNLOCK` writer - Clears Status Bit of WDOG0 and Unlocks Access to It"]
45pub type WDOG0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 11>;
46#[doc = "Field `WDOG1UNLOCK` writer - Clears Status Bit of WDOG1 and Unlocks Access to It"]
47pub type WDOG1UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 12>;
48#[doc = "Field `LESENSE0UNLOCK` writer - Clears Status Bit of LESENSE0 and Unlocks Access to It"]
49pub type LESENSE0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 13>;
50#[doc = "Field `CSENUNLOCK` writer - Clears Status Bit of CSEN and Unlocks Access to It"]
51pub type CSENUNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 14>;
52#[doc = "Field `LEUART0UNLOCK` writer - Clears Status Bit of LEUART0 and Unlocks Access to It"]
53pub type LEUART0UNLOCK_W<'a> = crate::BitWriter<'a, u32, EM23PERNORETAINCMD_SPEC, bool, 15>;
54impl W {
55    #[doc = "Bit 0 - Clears Status Bit of ACMP0 and Unlocks Access to It"]
56    #[inline(always)]
57    pub fn acmp0unlock(&mut self) -> ACMP0UNLOCK_W {
58        ACMP0UNLOCK_W::new(self)
59    }
60    #[doc = "Bit 1 - Clears Status Bit of ACMP1 and Unlocks Access to It"]
61    #[inline(always)]
62    pub fn acmp1unlock(&mut self) -> ACMP1UNLOCK_W {
63        ACMP1UNLOCK_W::new(self)
64    }
65    #[doc = "Bit 2 - Clears Status Bit of PCNT0 and Unlocks Access to It"]
66    #[inline(always)]
67    pub fn pcnt0unlock(&mut self) -> PCNT0UNLOCK_W {
68        PCNT0UNLOCK_W::new(self)
69    }
70    #[doc = "Bit 3 - Clears Status Bit of PCNT1 and Unlocks Access to It"]
71    #[inline(always)]
72    pub fn pcnt1unlock(&mut self) -> PCNT1UNLOCK_W {
73        PCNT1UNLOCK_W::new(self)
74    }
75    #[doc = "Bit 4 - Clears Status Bit of PCNT2 and Unlocks Access to It"]
76    #[inline(always)]
77    pub fn pcnt2unlock(&mut self) -> PCNT2UNLOCK_W {
78        PCNT2UNLOCK_W::new(self)
79    }
80    #[doc = "Bit 5 - Clears Status Bit of I2C0 and Unlocks Access to It"]
81    #[inline(always)]
82    pub fn i2c0unlock(&mut self) -> I2C0UNLOCK_W {
83        I2C0UNLOCK_W::new(self)
84    }
85    #[doc = "Bit 6 - Clears Status Bit of I2C1 and Unlocks Access to It"]
86    #[inline(always)]
87    pub fn i2c1unlock(&mut self) -> I2C1UNLOCK_W {
88        I2C1UNLOCK_W::new(self)
89    }
90    #[doc = "Bit 7 - Clears Status Bit of DAC0 and Unlocks Access to It"]
91    #[inline(always)]
92    pub fn dac0unlock(&mut self) -> DAC0UNLOCK_W {
93        DAC0UNLOCK_W::new(self)
94    }
95    #[doc = "Bit 8 - Clears Status Bit of IDAC0 and Unlocks Access to It"]
96    #[inline(always)]
97    pub fn idac0unlock(&mut self) -> IDAC0UNLOCK_W {
98        IDAC0UNLOCK_W::new(self)
99    }
100    #[doc = "Bit 9 - Clears Status Bit of ADC0 and Unlocks Access to It"]
101    #[inline(always)]
102    pub fn adc0unlock(&mut self) -> ADC0UNLOCK_W {
103        ADC0UNLOCK_W::new(self)
104    }
105    #[doc = "Bit 10 - Clears Status Bit of LETIMER0 and Unlocks Access to It"]
106    #[inline(always)]
107    pub fn letimer0unlock(&mut self) -> LETIMER0UNLOCK_W {
108        LETIMER0UNLOCK_W::new(self)
109    }
110    #[doc = "Bit 11 - Clears Status Bit of WDOG0 and Unlocks Access to It"]
111    #[inline(always)]
112    pub fn wdog0unlock(&mut self) -> WDOG0UNLOCK_W {
113        WDOG0UNLOCK_W::new(self)
114    }
115    #[doc = "Bit 12 - Clears Status Bit of WDOG1 and Unlocks Access to It"]
116    #[inline(always)]
117    pub fn wdog1unlock(&mut self) -> WDOG1UNLOCK_W {
118        WDOG1UNLOCK_W::new(self)
119    }
120    #[doc = "Bit 13 - Clears Status Bit of LESENSE0 and Unlocks Access to It"]
121    #[inline(always)]
122    pub fn lesense0unlock(&mut self) -> LESENSE0UNLOCK_W {
123        LESENSE0UNLOCK_W::new(self)
124    }
125    #[doc = "Bit 14 - Clears Status Bit of CSEN and Unlocks Access to It"]
126    #[inline(always)]
127    pub fn csenunlock(&mut self) -> CSENUNLOCK_W {
128        CSENUNLOCK_W::new(self)
129    }
130    #[doc = "Bit 15 - Clears Status Bit of LEUART0 and Unlocks Access to It"]
131    #[inline(always)]
132    pub fn leuart0unlock(&mut self) -> LEUART0UNLOCK_W {
133        LEUART0UNLOCK_W::new(self)
134    }
135    #[doc = "Writes raw bits to the register."]
136    #[inline(always)]
137    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
138        self.0.bits(bits);
139        self
140    }
141}
142#[doc = "Clears Corresponding Bits in EM23PERNORETAINSTATUS Unlocking Access to Peripheral\n\nThis register you can [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [em23pernoretaincmd](index.html) module"]
143pub struct EM23PERNORETAINCMD_SPEC;
144impl crate::RegisterSpec for EM23PERNORETAINCMD_SPEC {
145    type Ux = u32;
146}
147#[doc = "`write(|w| ..)` method takes [em23pernoretaincmd::W](W) writer structure"]
148impl crate::Writable for EM23PERNORETAINCMD_SPEC {
149    type Writer = W;
150}
151#[doc = "`reset()` method sets EM23PERNORETAINCMD to value 0"]
152impl crate::Resettable for EM23PERNORETAINCMD_SPEC {
153    #[inline(always)]
154    fn reset_value() -> Self::Ux {
155        0
156    }
157}