lpc845_pac/swm0/
pinenable0.rs

1#[doc = "Register `PINENABLE0` reader"]
2pub struct R(crate::R<PINENABLE0_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<PINENABLE0_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<PINENABLE0_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<PINENABLE0_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `PINENABLE0` writer"]
17pub struct W(crate::W<PINENABLE0_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<PINENABLE0_SPEC>;
20    #[inline(always)]
21    fn deref(&self) -> &Self::Target {
22        &self.0
23    }
24}
25impl core::ops::DerefMut for W {
26    #[inline(always)]
27    fn deref_mut(&mut self) -> &mut Self::Target {
28        &mut self.0
29    }
30}
31impl From<crate::W<PINENABLE0_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<PINENABLE0_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "ACMP_I1 function select.\n\nValue on reset: 1"]
38#[derive(Clone, Copy, Debug, PartialEq)]
39pub enum ACMP_I1_A {
40    #[doc = "0: ACMP_I1 enabled on pin PIO0_00."]
41    ENABLED = 0,
42    #[doc = "1: ACMP_I1 disabled."]
43    DISABLED = 1,
44}
45impl From<ACMP_I1_A> for bool {
46    #[inline(always)]
47    fn from(variant: ACMP_I1_A) -> Self {
48        variant as u8 != 0
49    }
50}
51#[doc = "Field `ACMP_I1` reader - ACMP_I1 function select."]
52pub struct ACMP_I1_R(crate::FieldReader<bool, ACMP_I1_A>);
53impl ACMP_I1_R {
54    pub(crate) fn new(bits: bool) -> Self {
55        ACMP_I1_R(crate::FieldReader::new(bits))
56    }
57    #[doc = r"Get enumerated values variant"]
58    #[inline(always)]
59    pub fn variant(&self) -> ACMP_I1_A {
60        match self.bits {
61            false => ACMP_I1_A::ENABLED,
62            true => ACMP_I1_A::DISABLED,
63        }
64    }
65    #[doc = "Checks if the value of the field is `ENABLED`"]
66    #[inline(always)]
67    pub fn is_enabled(&self) -> bool {
68        **self == ACMP_I1_A::ENABLED
69    }
70    #[doc = "Checks if the value of the field is `DISABLED`"]
71    #[inline(always)]
72    pub fn is_disabled(&self) -> bool {
73        **self == ACMP_I1_A::DISABLED
74    }
75}
76impl core::ops::Deref for ACMP_I1_R {
77    type Target = crate::FieldReader<bool, ACMP_I1_A>;
78    #[inline(always)]
79    fn deref(&self) -> &Self::Target {
80        &self.0
81    }
82}
83#[doc = "Field `ACMP_I1` writer - ACMP_I1 function select."]
84pub struct ACMP_I1_W<'a> {
85    w: &'a mut W,
86}
87impl<'a> ACMP_I1_W<'a> {
88    #[doc = r"Writes `variant` to the field"]
89    #[inline(always)]
90    pub fn variant(self, variant: ACMP_I1_A) -> &'a mut W {
91        self.bit(variant.into())
92    }
93    #[doc = "ACMP_I1 enabled on pin PIO0_00."]
94    #[inline(always)]
95    pub fn enabled(self) -> &'a mut W {
96        self.variant(ACMP_I1_A::ENABLED)
97    }
98    #[doc = "ACMP_I1 disabled."]
99    #[inline(always)]
100    pub fn disabled(self) -> &'a mut W {
101        self.variant(ACMP_I1_A::DISABLED)
102    }
103    #[doc = r"Sets the field bit"]
104    #[inline(always)]
105    pub fn set_bit(self) -> &'a mut W {
106        self.bit(true)
107    }
108    #[doc = r"Clears the field bit"]
109    #[inline(always)]
110    pub fn clear_bit(self) -> &'a mut W {
111        self.bit(false)
112    }
113    #[doc = r"Writes raw bits to the field"]
114    #[inline(always)]
115    pub fn bit(self, value: bool) -> &'a mut W {
116        self.w.bits = (self.w.bits & !0x01) | (value as u32 & 0x01);
117        self.w
118    }
119}
120#[doc = "ACMP_I2 function select.\n\nValue on reset: 1"]
121#[derive(Clone, Copy, Debug, PartialEq)]
122pub enum ACMP_I2_A {
123    #[doc = "0: ACMP_I2 enabled on pin PIO0_1."]
124    ACMP_I2_0 = 0,
125    #[doc = "1: ACMP_I2 disabled."]
126    ACMP_I2_1 = 1,
127}
128impl From<ACMP_I2_A> for bool {
129    #[inline(always)]
130    fn from(variant: ACMP_I2_A) -> Self {
131        variant as u8 != 0
132    }
133}
134#[doc = "Field `ACMP_I2` reader - ACMP_I2 function select."]
135pub struct ACMP_I2_R(crate::FieldReader<bool, ACMP_I2_A>);
136impl ACMP_I2_R {
137    pub(crate) fn new(bits: bool) -> Self {
138        ACMP_I2_R(crate::FieldReader::new(bits))
139    }
140    #[doc = r"Get enumerated values variant"]
141    #[inline(always)]
142    pub fn variant(&self) -> ACMP_I2_A {
143        match self.bits {
144            false => ACMP_I2_A::ACMP_I2_0,
145            true => ACMP_I2_A::ACMP_I2_1,
146        }
147    }
148    #[doc = "Checks if the value of the field is `ACMP_I2_0`"]
149    #[inline(always)]
150    pub fn is_acmp_i2_0(&self) -> bool {
151        **self == ACMP_I2_A::ACMP_I2_0
152    }
153    #[doc = "Checks if the value of the field is `ACMP_I2_1`"]
154    #[inline(always)]
155    pub fn is_acmp_i2_1(&self) -> bool {
156        **self == ACMP_I2_A::ACMP_I2_1
157    }
158}
159impl core::ops::Deref for ACMP_I2_R {
160    type Target = crate::FieldReader<bool, ACMP_I2_A>;
161    #[inline(always)]
162    fn deref(&self) -> &Self::Target {
163        &self.0
164    }
165}
166#[doc = "Field `ACMP_I2` writer - ACMP_I2 function select."]
167pub struct ACMP_I2_W<'a> {
168    w: &'a mut W,
169}
170impl<'a> ACMP_I2_W<'a> {
171    #[doc = r"Writes `variant` to the field"]
172    #[inline(always)]
173    pub fn variant(self, variant: ACMP_I2_A) -> &'a mut W {
174        self.bit(variant.into())
175    }
176    #[doc = "ACMP_I2 enabled on pin PIO0_1."]
177    #[inline(always)]
178    pub fn acmp_i2_0(self) -> &'a mut W {
179        self.variant(ACMP_I2_A::ACMP_I2_0)
180    }
181    #[doc = "ACMP_I2 disabled."]
182    #[inline(always)]
183    pub fn acmp_i2_1(self) -> &'a mut W {
184        self.variant(ACMP_I2_A::ACMP_I2_1)
185    }
186    #[doc = r"Sets the field bit"]
187    #[inline(always)]
188    pub fn set_bit(self) -> &'a mut W {
189        self.bit(true)
190    }
191    #[doc = r"Clears the field bit"]
192    #[inline(always)]
193    pub fn clear_bit(self) -> &'a mut W {
194        self.bit(false)
195    }
196    #[doc = r"Writes raw bits to the field"]
197    #[inline(always)]
198    pub fn bit(self, value: bool) -> &'a mut W {
199        self.w.bits = (self.w.bits & !(0x01 << 1)) | ((value as u32 & 0x01) << 1);
200        self.w
201    }
202}
203#[doc = "ACMP_I3 function select.\n\nValue on reset: 1"]
204#[derive(Clone, Copy, Debug, PartialEq)]
205pub enum ACMP_I3_A {
206    #[doc = "0: ACMP_I3 enabled on pin PIO0_14."]
207    ENABLED = 0,
208    #[doc = "1: ACMP_I3 disabled."]
209    DISABLED = 1,
210}
211impl From<ACMP_I3_A> for bool {
212    #[inline(always)]
213    fn from(variant: ACMP_I3_A) -> Self {
214        variant as u8 != 0
215    }
216}
217#[doc = "Field `ACMP_I3` reader - ACMP_I3 function select."]
218pub struct ACMP_I3_R(crate::FieldReader<bool, ACMP_I3_A>);
219impl ACMP_I3_R {
220    pub(crate) fn new(bits: bool) -> Self {
221        ACMP_I3_R(crate::FieldReader::new(bits))
222    }
223    #[doc = r"Get enumerated values variant"]
224    #[inline(always)]
225    pub fn variant(&self) -> ACMP_I3_A {
226        match self.bits {
227            false => ACMP_I3_A::ENABLED,
228            true => ACMP_I3_A::DISABLED,
229        }
230    }
231    #[doc = "Checks if the value of the field is `ENABLED`"]
232    #[inline(always)]
233    pub fn is_enabled(&self) -> bool {
234        **self == ACMP_I3_A::ENABLED
235    }
236    #[doc = "Checks if the value of the field is `DISABLED`"]
237    #[inline(always)]
238    pub fn is_disabled(&self) -> bool {
239        **self == ACMP_I3_A::DISABLED
240    }
241}
242impl core::ops::Deref for ACMP_I3_R {
243    type Target = crate::FieldReader<bool, ACMP_I3_A>;
244    #[inline(always)]
245    fn deref(&self) -> &Self::Target {
246        &self.0
247    }
248}
249#[doc = "Field `ACMP_I3` writer - ACMP_I3 function select."]
250pub struct ACMP_I3_W<'a> {
251    w: &'a mut W,
252}
253impl<'a> ACMP_I3_W<'a> {
254    #[doc = r"Writes `variant` to the field"]
255    #[inline(always)]
256    pub fn variant(self, variant: ACMP_I3_A) -> &'a mut W {
257        self.bit(variant.into())
258    }
259    #[doc = "ACMP_I3 enabled on pin PIO0_14."]
260    #[inline(always)]
261    pub fn enabled(self) -> &'a mut W {
262        self.variant(ACMP_I3_A::ENABLED)
263    }
264    #[doc = "ACMP_I3 disabled."]
265    #[inline(always)]
266    pub fn disabled(self) -> &'a mut W {
267        self.variant(ACMP_I3_A::DISABLED)
268    }
269    #[doc = r"Sets the field bit"]
270    #[inline(always)]
271    pub fn set_bit(self) -> &'a mut W {
272        self.bit(true)
273    }
274    #[doc = r"Clears the field bit"]
275    #[inline(always)]
276    pub fn clear_bit(self) -> &'a mut W {
277        self.bit(false)
278    }
279    #[doc = r"Writes raw bits to the field"]
280    #[inline(always)]
281    pub fn bit(self, value: bool) -> &'a mut W {
282        self.w.bits = (self.w.bits & !(0x01 << 2)) | ((value as u32 & 0x01) << 2);
283        self.w
284    }
285}
286#[doc = "ACMP_I4 function select.\n\nValue on reset: 1"]
287#[derive(Clone, Copy, Debug, PartialEq)]
288pub enum ACMP_I4_A {
289    #[doc = "0: ACMP_I4 enabled on pin PIO0_23."]
290    ENABLED = 0,
291    #[doc = "1: ACMP_I4 disabled."]
292    DISABLED = 1,
293}
294impl From<ACMP_I4_A> for bool {
295    #[inline(always)]
296    fn from(variant: ACMP_I4_A) -> Self {
297        variant as u8 != 0
298    }
299}
300#[doc = "Field `ACMP_I4` reader - ACMP_I4 function select."]
301pub struct ACMP_I4_R(crate::FieldReader<bool, ACMP_I4_A>);
302impl ACMP_I4_R {
303    pub(crate) fn new(bits: bool) -> Self {
304        ACMP_I4_R(crate::FieldReader::new(bits))
305    }
306    #[doc = r"Get enumerated values variant"]
307    #[inline(always)]
308    pub fn variant(&self) -> ACMP_I4_A {
309        match self.bits {
310            false => ACMP_I4_A::ENABLED,
311            true => ACMP_I4_A::DISABLED,
312        }
313    }
314    #[doc = "Checks if the value of the field is `ENABLED`"]
315    #[inline(always)]
316    pub fn is_enabled(&self) -> bool {
317        **self == ACMP_I4_A::ENABLED
318    }
319    #[doc = "Checks if the value of the field is `DISABLED`"]
320    #[inline(always)]
321    pub fn is_disabled(&self) -> bool {
322        **self == ACMP_I4_A::DISABLED
323    }
324}
325impl core::ops::Deref for ACMP_I4_R {
326    type Target = crate::FieldReader<bool, ACMP_I4_A>;
327    #[inline(always)]
328    fn deref(&self) -> &Self::Target {
329        &self.0
330    }
331}
332#[doc = "Field `ACMP_I4` writer - ACMP_I4 function select."]
333pub struct ACMP_I4_W<'a> {
334    w: &'a mut W,
335}
336impl<'a> ACMP_I4_W<'a> {
337    #[doc = r"Writes `variant` to the field"]
338    #[inline(always)]
339    pub fn variant(self, variant: ACMP_I4_A) -> &'a mut W {
340        self.bit(variant.into())
341    }
342    #[doc = "ACMP_I4 enabled on pin PIO0_23."]
343    #[inline(always)]
344    pub fn enabled(self) -> &'a mut W {
345        self.variant(ACMP_I4_A::ENABLED)
346    }
347    #[doc = "ACMP_I4 disabled."]
348    #[inline(always)]
349    pub fn disabled(self) -> &'a mut W {
350        self.variant(ACMP_I4_A::DISABLED)
351    }
352    #[doc = r"Sets the field bit"]
353    #[inline(always)]
354    pub fn set_bit(self) -> &'a mut W {
355        self.bit(true)
356    }
357    #[doc = r"Clears the field bit"]
358    #[inline(always)]
359    pub fn clear_bit(self) -> &'a mut W {
360        self.bit(false)
361    }
362    #[doc = r"Writes raw bits to the field"]
363    #[inline(always)]
364    pub fn bit(self, value: bool) -> &'a mut W {
365        self.w.bits = (self.w.bits & !(0x01 << 3)) | ((value as u32 & 0x01) << 3);
366        self.w
367    }
368}
369#[doc = "ACMP_I5 function select.\n\nValue on reset: 1"]
370#[derive(Clone, Copy, Debug, PartialEq)]
371pub enum ACMP_I5_A {
372    #[doc = "0: ACMP_I5 enabled on pin PIO0_30."]
373    ENABLED = 0,
374    #[doc = "1: ACMP_I5 disabled."]
375    DISABLED = 1,
376}
377impl From<ACMP_I5_A> for bool {
378    #[inline(always)]
379    fn from(variant: ACMP_I5_A) -> Self {
380        variant as u8 != 0
381    }
382}
383#[doc = "Field `ACMP_I5` reader - ACMP_I5 function select."]
384pub struct ACMP_I5_R(crate::FieldReader<bool, ACMP_I5_A>);
385impl ACMP_I5_R {
386    pub(crate) fn new(bits: bool) -> Self {
387        ACMP_I5_R(crate::FieldReader::new(bits))
388    }
389    #[doc = r"Get enumerated values variant"]
390    #[inline(always)]
391    pub fn variant(&self) -> ACMP_I5_A {
392        match self.bits {
393            false => ACMP_I5_A::ENABLED,
394            true => ACMP_I5_A::DISABLED,
395        }
396    }
397    #[doc = "Checks if the value of the field is `ENABLED`"]
398    #[inline(always)]
399    pub fn is_enabled(&self) -> bool {
400        **self == ACMP_I5_A::ENABLED
401    }
402    #[doc = "Checks if the value of the field is `DISABLED`"]
403    #[inline(always)]
404    pub fn is_disabled(&self) -> bool {
405        **self == ACMP_I5_A::DISABLED
406    }
407}
408impl core::ops::Deref for ACMP_I5_R {
409    type Target = crate::FieldReader<bool, ACMP_I5_A>;
410    #[inline(always)]
411    fn deref(&self) -> &Self::Target {
412        &self.0
413    }
414}
415#[doc = "Field `ACMP_I5` writer - ACMP_I5 function select."]
416pub struct ACMP_I5_W<'a> {
417    w: &'a mut W,
418}
419impl<'a> ACMP_I5_W<'a> {
420    #[doc = r"Writes `variant` to the field"]
421    #[inline(always)]
422    pub fn variant(self, variant: ACMP_I5_A) -> &'a mut W {
423        self.bit(variant.into())
424    }
425    #[doc = "ACMP_I5 enabled on pin PIO0_30."]
426    #[inline(always)]
427    pub fn enabled(self) -> &'a mut W {
428        self.variant(ACMP_I5_A::ENABLED)
429    }
430    #[doc = "ACMP_I5 disabled."]
431    #[inline(always)]
432    pub fn disabled(self) -> &'a mut W {
433        self.variant(ACMP_I5_A::DISABLED)
434    }
435    #[doc = r"Sets the field bit"]
436    #[inline(always)]
437    pub fn set_bit(self) -> &'a mut W {
438        self.bit(true)
439    }
440    #[doc = r"Clears the field bit"]
441    #[inline(always)]
442    pub fn clear_bit(self) -> &'a mut W {
443        self.bit(false)
444    }
445    #[doc = r"Writes raw bits to the field"]
446    #[inline(always)]
447    pub fn bit(self, value: bool) -> &'a mut W {
448        self.w.bits = (self.w.bits & !(0x01 << 4)) | ((value as u32 & 0x01) << 4);
449        self.w
450    }
451}
452#[doc = "SWCLK function select.\n\nValue on reset: 0"]
453#[derive(Clone, Copy, Debug, PartialEq)]
454pub enum SWCLK_A {
455    #[doc = "0: SWCLK enabled on pin PIO0_3."]
456    ENABLED = 0,
457    #[doc = "1: SWCLK disabled."]
458    DISABLED = 1,
459}
460impl From<SWCLK_A> for bool {
461    #[inline(always)]
462    fn from(variant: SWCLK_A) -> Self {
463        variant as u8 != 0
464    }
465}
466#[doc = "Field `SWCLK` reader - SWCLK function select."]
467pub struct SWCLK_R(crate::FieldReader<bool, SWCLK_A>);
468impl SWCLK_R {
469    pub(crate) fn new(bits: bool) -> Self {
470        SWCLK_R(crate::FieldReader::new(bits))
471    }
472    #[doc = r"Get enumerated values variant"]
473    #[inline(always)]
474    pub fn variant(&self) -> SWCLK_A {
475        match self.bits {
476            false => SWCLK_A::ENABLED,
477            true => SWCLK_A::DISABLED,
478        }
479    }
480    #[doc = "Checks if the value of the field is `ENABLED`"]
481    #[inline(always)]
482    pub fn is_enabled(&self) -> bool {
483        **self == SWCLK_A::ENABLED
484    }
485    #[doc = "Checks if the value of the field is `DISABLED`"]
486    #[inline(always)]
487    pub fn is_disabled(&self) -> bool {
488        **self == SWCLK_A::DISABLED
489    }
490}
491impl core::ops::Deref for SWCLK_R {
492    type Target = crate::FieldReader<bool, SWCLK_A>;
493    #[inline(always)]
494    fn deref(&self) -> &Self::Target {
495        &self.0
496    }
497}
498#[doc = "Field `SWCLK` writer - SWCLK function select."]
499pub struct SWCLK_W<'a> {
500    w: &'a mut W,
501}
502impl<'a> SWCLK_W<'a> {
503    #[doc = r"Writes `variant` to the field"]
504    #[inline(always)]
505    pub fn variant(self, variant: SWCLK_A) -> &'a mut W {
506        self.bit(variant.into())
507    }
508    #[doc = "SWCLK enabled on pin PIO0_3."]
509    #[inline(always)]
510    pub fn enabled(self) -> &'a mut W {
511        self.variant(SWCLK_A::ENABLED)
512    }
513    #[doc = "SWCLK disabled."]
514    #[inline(always)]
515    pub fn disabled(self) -> &'a mut W {
516        self.variant(SWCLK_A::DISABLED)
517    }
518    #[doc = r"Sets the field bit"]
519    #[inline(always)]
520    pub fn set_bit(self) -> &'a mut W {
521        self.bit(true)
522    }
523    #[doc = r"Clears the field bit"]
524    #[inline(always)]
525    pub fn clear_bit(self) -> &'a mut W {
526        self.bit(false)
527    }
528    #[doc = r"Writes raw bits to the field"]
529    #[inline(always)]
530    pub fn bit(self, value: bool) -> &'a mut W {
531        self.w.bits = (self.w.bits & !(0x01 << 5)) | ((value as u32 & 0x01) << 5);
532        self.w
533    }
534}
535#[doc = "SWDIO function select.\n\nValue on reset: 0"]
536#[derive(Clone, Copy, Debug, PartialEq)]
537pub enum SWDIO_A {
538    #[doc = "0: SWDIO enabled on pin PIO0_2."]
539    ENABLED = 0,
540    #[doc = "1: SWDIO disabled."]
541    DISABLED = 1,
542}
543impl From<SWDIO_A> for bool {
544    #[inline(always)]
545    fn from(variant: SWDIO_A) -> Self {
546        variant as u8 != 0
547    }
548}
549#[doc = "Field `SWDIO` reader - SWDIO function select."]
550pub struct SWDIO_R(crate::FieldReader<bool, SWDIO_A>);
551impl SWDIO_R {
552    pub(crate) fn new(bits: bool) -> Self {
553        SWDIO_R(crate::FieldReader::new(bits))
554    }
555    #[doc = r"Get enumerated values variant"]
556    #[inline(always)]
557    pub fn variant(&self) -> SWDIO_A {
558        match self.bits {
559            false => SWDIO_A::ENABLED,
560            true => SWDIO_A::DISABLED,
561        }
562    }
563    #[doc = "Checks if the value of the field is `ENABLED`"]
564    #[inline(always)]
565    pub fn is_enabled(&self) -> bool {
566        **self == SWDIO_A::ENABLED
567    }
568    #[doc = "Checks if the value of the field is `DISABLED`"]
569    #[inline(always)]
570    pub fn is_disabled(&self) -> bool {
571        **self == SWDIO_A::DISABLED
572    }
573}
574impl core::ops::Deref for SWDIO_R {
575    type Target = crate::FieldReader<bool, SWDIO_A>;
576    #[inline(always)]
577    fn deref(&self) -> &Self::Target {
578        &self.0
579    }
580}
581#[doc = "Field `SWDIO` writer - SWDIO function select."]
582pub struct SWDIO_W<'a> {
583    w: &'a mut W,
584}
585impl<'a> SWDIO_W<'a> {
586    #[doc = r"Writes `variant` to the field"]
587    #[inline(always)]
588    pub fn variant(self, variant: SWDIO_A) -> &'a mut W {
589        self.bit(variant.into())
590    }
591    #[doc = "SWDIO enabled on pin PIO0_2."]
592    #[inline(always)]
593    pub fn enabled(self) -> &'a mut W {
594        self.variant(SWDIO_A::ENABLED)
595    }
596    #[doc = "SWDIO disabled."]
597    #[inline(always)]
598    pub fn disabled(self) -> &'a mut W {
599        self.variant(SWDIO_A::DISABLED)
600    }
601    #[doc = r"Sets the field bit"]
602    #[inline(always)]
603    pub fn set_bit(self) -> &'a mut W {
604        self.bit(true)
605    }
606    #[doc = r"Clears the field bit"]
607    #[inline(always)]
608    pub fn clear_bit(self) -> &'a mut W {
609        self.bit(false)
610    }
611    #[doc = r"Writes raw bits to the field"]
612    #[inline(always)]
613    pub fn bit(self, value: bool) -> &'a mut W {
614        self.w.bits = (self.w.bits & !(0x01 << 6)) | ((value as u32 & 0x01) << 6);
615        self.w
616    }
617}
618#[doc = "XTALIN function select.\n\nValue on reset: 1"]
619#[derive(Clone, Copy, Debug, PartialEq)]
620pub enum XTALIN_A {
621    #[doc = "0: XTALIN enabled on pin PIO0_8."]
622    ENABLED = 0,
623    #[doc = "1: XTALIN disabled."]
624    DISABLED = 1,
625}
626impl From<XTALIN_A> for bool {
627    #[inline(always)]
628    fn from(variant: XTALIN_A) -> Self {
629        variant as u8 != 0
630    }
631}
632#[doc = "Field `XTALIN` reader - XTALIN function select."]
633pub struct XTALIN_R(crate::FieldReader<bool, XTALIN_A>);
634impl XTALIN_R {
635    pub(crate) fn new(bits: bool) -> Self {
636        XTALIN_R(crate::FieldReader::new(bits))
637    }
638    #[doc = r"Get enumerated values variant"]
639    #[inline(always)]
640    pub fn variant(&self) -> XTALIN_A {
641        match self.bits {
642            false => XTALIN_A::ENABLED,
643            true => XTALIN_A::DISABLED,
644        }
645    }
646    #[doc = "Checks if the value of the field is `ENABLED`"]
647    #[inline(always)]
648    pub fn is_enabled(&self) -> bool {
649        **self == XTALIN_A::ENABLED
650    }
651    #[doc = "Checks if the value of the field is `DISABLED`"]
652    #[inline(always)]
653    pub fn is_disabled(&self) -> bool {
654        **self == XTALIN_A::DISABLED
655    }
656}
657impl core::ops::Deref for XTALIN_R {
658    type Target = crate::FieldReader<bool, XTALIN_A>;
659    #[inline(always)]
660    fn deref(&self) -> &Self::Target {
661        &self.0
662    }
663}
664#[doc = "Field `XTALIN` writer - XTALIN function select."]
665pub struct XTALIN_W<'a> {
666    w: &'a mut W,
667}
668impl<'a> XTALIN_W<'a> {
669    #[doc = r"Writes `variant` to the field"]
670    #[inline(always)]
671    pub fn variant(self, variant: XTALIN_A) -> &'a mut W {
672        self.bit(variant.into())
673    }
674    #[doc = "XTALIN enabled on pin PIO0_8."]
675    #[inline(always)]
676    pub fn enabled(self) -> &'a mut W {
677        self.variant(XTALIN_A::ENABLED)
678    }
679    #[doc = "XTALIN disabled."]
680    #[inline(always)]
681    pub fn disabled(self) -> &'a mut W {
682        self.variant(XTALIN_A::DISABLED)
683    }
684    #[doc = r"Sets the field bit"]
685    #[inline(always)]
686    pub fn set_bit(self) -> &'a mut W {
687        self.bit(true)
688    }
689    #[doc = r"Clears the field bit"]
690    #[inline(always)]
691    pub fn clear_bit(self) -> &'a mut W {
692        self.bit(false)
693    }
694    #[doc = r"Writes raw bits to the field"]
695    #[inline(always)]
696    pub fn bit(self, value: bool) -> &'a mut W {
697        self.w.bits = (self.w.bits & !(0x01 << 7)) | ((value as u32 & 0x01) << 7);
698        self.w
699    }
700}
701#[doc = "XTALOUT function select.\n\nValue on reset: 1"]
702#[derive(Clone, Copy, Debug, PartialEq)]
703pub enum XTALOUT_A {
704    #[doc = "0: XTALOUT enabled on pin PIO0_9."]
705    ENABLED = 0,
706    #[doc = "1: XTALOUT disabled."]
707    DISABLED = 1,
708}
709impl From<XTALOUT_A> for bool {
710    #[inline(always)]
711    fn from(variant: XTALOUT_A) -> Self {
712        variant as u8 != 0
713    }
714}
715#[doc = "Field `XTALOUT` reader - XTALOUT function select."]
716pub struct XTALOUT_R(crate::FieldReader<bool, XTALOUT_A>);
717impl XTALOUT_R {
718    pub(crate) fn new(bits: bool) -> Self {
719        XTALOUT_R(crate::FieldReader::new(bits))
720    }
721    #[doc = r"Get enumerated values variant"]
722    #[inline(always)]
723    pub fn variant(&self) -> XTALOUT_A {
724        match self.bits {
725            false => XTALOUT_A::ENABLED,
726            true => XTALOUT_A::DISABLED,
727        }
728    }
729    #[doc = "Checks if the value of the field is `ENABLED`"]
730    #[inline(always)]
731    pub fn is_enabled(&self) -> bool {
732        **self == XTALOUT_A::ENABLED
733    }
734    #[doc = "Checks if the value of the field is `DISABLED`"]
735    #[inline(always)]
736    pub fn is_disabled(&self) -> bool {
737        **self == XTALOUT_A::DISABLED
738    }
739}
740impl core::ops::Deref for XTALOUT_R {
741    type Target = crate::FieldReader<bool, XTALOUT_A>;
742    #[inline(always)]
743    fn deref(&self) -> &Self::Target {
744        &self.0
745    }
746}
747#[doc = "Field `XTALOUT` writer - XTALOUT function select."]
748pub struct XTALOUT_W<'a> {
749    w: &'a mut W,
750}
751impl<'a> XTALOUT_W<'a> {
752    #[doc = r"Writes `variant` to the field"]
753    #[inline(always)]
754    pub fn variant(self, variant: XTALOUT_A) -> &'a mut W {
755        self.bit(variant.into())
756    }
757    #[doc = "XTALOUT enabled on pin PIO0_9."]
758    #[inline(always)]
759    pub fn enabled(self) -> &'a mut W {
760        self.variant(XTALOUT_A::ENABLED)
761    }
762    #[doc = "XTALOUT disabled."]
763    #[inline(always)]
764    pub fn disabled(self) -> &'a mut W {
765        self.variant(XTALOUT_A::DISABLED)
766    }
767    #[doc = r"Sets the field bit"]
768    #[inline(always)]
769    pub fn set_bit(self) -> &'a mut W {
770        self.bit(true)
771    }
772    #[doc = r"Clears the field bit"]
773    #[inline(always)]
774    pub fn clear_bit(self) -> &'a mut W {
775        self.bit(false)
776    }
777    #[doc = r"Writes raw bits to the field"]
778    #[inline(always)]
779    pub fn bit(self, value: bool) -> &'a mut W {
780        self.w.bits = (self.w.bits & !(0x01 << 8)) | ((value as u32 & 0x01) << 8);
781        self.w
782    }
783}
784#[doc = "RESETN function select.\n\nValue on reset: 0"]
785#[derive(Clone, Copy, Debug, PartialEq)]
786pub enum RESETN_A {
787    #[doc = "0: RESETN enabled on pin PIO0_5."]
788    ENABLED = 0,
789    #[doc = "1: RESETN disabled."]
790    DISABLED = 1,
791}
792impl From<RESETN_A> for bool {
793    #[inline(always)]
794    fn from(variant: RESETN_A) -> Self {
795        variant as u8 != 0
796    }
797}
798#[doc = "Field `RESETN` reader - RESETN function select."]
799pub struct RESETN_R(crate::FieldReader<bool, RESETN_A>);
800impl RESETN_R {
801    pub(crate) fn new(bits: bool) -> Self {
802        RESETN_R(crate::FieldReader::new(bits))
803    }
804    #[doc = r"Get enumerated values variant"]
805    #[inline(always)]
806    pub fn variant(&self) -> RESETN_A {
807        match self.bits {
808            false => RESETN_A::ENABLED,
809            true => RESETN_A::DISABLED,
810        }
811    }
812    #[doc = "Checks if the value of the field is `ENABLED`"]
813    #[inline(always)]
814    pub fn is_enabled(&self) -> bool {
815        **self == RESETN_A::ENABLED
816    }
817    #[doc = "Checks if the value of the field is `DISABLED`"]
818    #[inline(always)]
819    pub fn is_disabled(&self) -> bool {
820        **self == RESETN_A::DISABLED
821    }
822}
823impl core::ops::Deref for RESETN_R {
824    type Target = crate::FieldReader<bool, RESETN_A>;
825    #[inline(always)]
826    fn deref(&self) -> &Self::Target {
827        &self.0
828    }
829}
830#[doc = "Field `RESETN` writer - RESETN function select."]
831pub struct RESETN_W<'a> {
832    w: &'a mut W,
833}
834impl<'a> RESETN_W<'a> {
835    #[doc = r"Writes `variant` to the field"]
836    #[inline(always)]
837    pub fn variant(self, variant: RESETN_A) -> &'a mut W {
838        self.bit(variant.into())
839    }
840    #[doc = "RESETN enabled on pin PIO0_5."]
841    #[inline(always)]
842    pub fn enabled(self) -> &'a mut W {
843        self.variant(RESETN_A::ENABLED)
844    }
845    #[doc = "RESETN disabled."]
846    #[inline(always)]
847    pub fn disabled(self) -> &'a mut W {
848        self.variant(RESETN_A::DISABLED)
849    }
850    #[doc = r"Sets the field bit"]
851    #[inline(always)]
852    pub fn set_bit(self) -> &'a mut W {
853        self.bit(true)
854    }
855    #[doc = r"Clears the field bit"]
856    #[inline(always)]
857    pub fn clear_bit(self) -> &'a mut W {
858        self.bit(false)
859    }
860    #[doc = r"Writes raw bits to the field"]
861    #[inline(always)]
862    pub fn bit(self, value: bool) -> &'a mut W {
863        self.w.bits = (self.w.bits & !(0x01 << 9)) | ((value as u32 & 0x01) << 9);
864        self.w
865    }
866}
867#[doc = "CLKIN function select.\n\nValue on reset: 1"]
868#[derive(Clone, Copy, Debug, PartialEq)]
869pub enum CLKIN_A {
870    #[doc = "0: CLKIN enabled on pin PIO0_1."]
871    ENABLED = 0,
872    #[doc = "1: CLKIN disabled."]
873    DISABLED = 1,
874}
875impl From<CLKIN_A> for bool {
876    #[inline(always)]
877    fn from(variant: CLKIN_A) -> Self {
878        variant as u8 != 0
879    }
880}
881#[doc = "Field `CLKIN` reader - CLKIN function select."]
882pub struct CLKIN_R(crate::FieldReader<bool, CLKIN_A>);
883impl CLKIN_R {
884    pub(crate) fn new(bits: bool) -> Self {
885        CLKIN_R(crate::FieldReader::new(bits))
886    }
887    #[doc = r"Get enumerated values variant"]
888    #[inline(always)]
889    pub fn variant(&self) -> CLKIN_A {
890        match self.bits {
891            false => CLKIN_A::ENABLED,
892            true => CLKIN_A::DISABLED,
893        }
894    }
895    #[doc = "Checks if the value of the field is `ENABLED`"]
896    #[inline(always)]
897    pub fn is_enabled(&self) -> bool {
898        **self == CLKIN_A::ENABLED
899    }
900    #[doc = "Checks if the value of the field is `DISABLED`"]
901    #[inline(always)]
902    pub fn is_disabled(&self) -> bool {
903        **self == CLKIN_A::DISABLED
904    }
905}
906impl core::ops::Deref for CLKIN_R {
907    type Target = crate::FieldReader<bool, CLKIN_A>;
908    #[inline(always)]
909    fn deref(&self) -> &Self::Target {
910        &self.0
911    }
912}
913#[doc = "Field `CLKIN` writer - CLKIN function select."]
914pub struct CLKIN_W<'a> {
915    w: &'a mut W,
916}
917impl<'a> CLKIN_W<'a> {
918    #[doc = r"Writes `variant` to the field"]
919    #[inline(always)]
920    pub fn variant(self, variant: CLKIN_A) -> &'a mut W {
921        self.bit(variant.into())
922    }
923    #[doc = "CLKIN enabled on pin PIO0_1."]
924    #[inline(always)]
925    pub fn enabled(self) -> &'a mut W {
926        self.variant(CLKIN_A::ENABLED)
927    }
928    #[doc = "CLKIN disabled."]
929    #[inline(always)]
930    pub fn disabled(self) -> &'a mut W {
931        self.variant(CLKIN_A::DISABLED)
932    }
933    #[doc = r"Sets the field bit"]
934    #[inline(always)]
935    pub fn set_bit(self) -> &'a mut W {
936        self.bit(true)
937    }
938    #[doc = r"Clears the field bit"]
939    #[inline(always)]
940    pub fn clear_bit(self) -> &'a mut W {
941        self.bit(false)
942    }
943    #[doc = r"Writes raw bits to the field"]
944    #[inline(always)]
945    pub fn bit(self, value: bool) -> &'a mut W {
946        self.w.bits = (self.w.bits & !(0x01 << 10)) | ((value as u32 & 0x01) << 10);
947        self.w
948    }
949}
950#[doc = "VDDCMP function select.\n\nValue on reset: 1"]
951#[derive(Clone, Copy, Debug, PartialEq)]
952pub enum VDDCMP_A {
953    #[doc = "0: VDDCMP enabled on pin PIO0_6."]
954    ENABLED = 0,
955    #[doc = "1: VDDCMP disabled."]
956    DISABLED = 1,
957}
958impl From<VDDCMP_A> for bool {
959    #[inline(always)]
960    fn from(variant: VDDCMP_A) -> Self {
961        variant as u8 != 0
962    }
963}
964#[doc = "Field `VDDCMP` reader - VDDCMP function select."]
965pub struct VDDCMP_R(crate::FieldReader<bool, VDDCMP_A>);
966impl VDDCMP_R {
967    pub(crate) fn new(bits: bool) -> Self {
968        VDDCMP_R(crate::FieldReader::new(bits))
969    }
970    #[doc = r"Get enumerated values variant"]
971    #[inline(always)]
972    pub fn variant(&self) -> VDDCMP_A {
973        match self.bits {
974            false => VDDCMP_A::ENABLED,
975            true => VDDCMP_A::DISABLED,
976        }
977    }
978    #[doc = "Checks if the value of the field is `ENABLED`"]
979    #[inline(always)]
980    pub fn is_enabled(&self) -> bool {
981        **self == VDDCMP_A::ENABLED
982    }
983    #[doc = "Checks if the value of the field is `DISABLED`"]
984    #[inline(always)]
985    pub fn is_disabled(&self) -> bool {
986        **self == VDDCMP_A::DISABLED
987    }
988}
989impl core::ops::Deref for VDDCMP_R {
990    type Target = crate::FieldReader<bool, VDDCMP_A>;
991    #[inline(always)]
992    fn deref(&self) -> &Self::Target {
993        &self.0
994    }
995}
996#[doc = "Field `VDDCMP` writer - VDDCMP function select."]
997pub struct VDDCMP_W<'a> {
998    w: &'a mut W,
999}
1000impl<'a> VDDCMP_W<'a> {
1001    #[doc = r"Writes `variant` to the field"]
1002    #[inline(always)]
1003    pub fn variant(self, variant: VDDCMP_A) -> &'a mut W {
1004        self.bit(variant.into())
1005    }
1006    #[doc = "VDDCMP enabled on pin PIO0_6."]
1007    #[inline(always)]
1008    pub fn enabled(self) -> &'a mut W {
1009        self.variant(VDDCMP_A::ENABLED)
1010    }
1011    #[doc = "VDDCMP disabled."]
1012    #[inline(always)]
1013    pub fn disabled(self) -> &'a mut W {
1014        self.variant(VDDCMP_A::DISABLED)
1015    }
1016    #[doc = r"Sets the field bit"]
1017    #[inline(always)]
1018    pub fn set_bit(self) -> &'a mut W {
1019        self.bit(true)
1020    }
1021    #[doc = r"Clears the field bit"]
1022    #[inline(always)]
1023    pub fn clear_bit(self) -> &'a mut W {
1024        self.bit(false)
1025    }
1026    #[doc = r"Writes raw bits to the field"]
1027    #[inline(always)]
1028    pub fn bit(self, value: bool) -> &'a mut W {
1029        self.w.bits = (self.w.bits & !(0x01 << 11)) | ((value as u32 & 0x01) << 11);
1030        self.w
1031    }
1032}
1033#[doc = "I2C0_SDA function select.\n\nValue on reset: 1"]
1034#[derive(Clone, Copy, Debug, PartialEq)]
1035pub enum I2C0_SDA_A {
1036    #[doc = "0: I2C0_SDA enabled on pin PIO0_11."]
1037    ENABLED = 0,
1038    #[doc = "1: I2C0_SDA disabled."]
1039    DISABLED = 1,
1040}
1041impl From<I2C0_SDA_A> for bool {
1042    #[inline(always)]
1043    fn from(variant: I2C0_SDA_A) -> Self {
1044        variant as u8 != 0
1045    }
1046}
1047#[doc = "Field `I2C0_SDA` reader - I2C0_SDA function select."]
1048pub struct I2C0_SDA_R(crate::FieldReader<bool, I2C0_SDA_A>);
1049impl I2C0_SDA_R {
1050    pub(crate) fn new(bits: bool) -> Self {
1051        I2C0_SDA_R(crate::FieldReader::new(bits))
1052    }
1053    #[doc = r"Get enumerated values variant"]
1054    #[inline(always)]
1055    pub fn variant(&self) -> I2C0_SDA_A {
1056        match self.bits {
1057            false => I2C0_SDA_A::ENABLED,
1058            true => I2C0_SDA_A::DISABLED,
1059        }
1060    }
1061    #[doc = "Checks if the value of the field is `ENABLED`"]
1062    #[inline(always)]
1063    pub fn is_enabled(&self) -> bool {
1064        **self == I2C0_SDA_A::ENABLED
1065    }
1066    #[doc = "Checks if the value of the field is `DISABLED`"]
1067    #[inline(always)]
1068    pub fn is_disabled(&self) -> bool {
1069        **self == I2C0_SDA_A::DISABLED
1070    }
1071}
1072impl core::ops::Deref for I2C0_SDA_R {
1073    type Target = crate::FieldReader<bool, I2C0_SDA_A>;
1074    #[inline(always)]
1075    fn deref(&self) -> &Self::Target {
1076        &self.0
1077    }
1078}
1079#[doc = "Field `I2C0_SDA` writer - I2C0_SDA function select."]
1080pub struct I2C0_SDA_W<'a> {
1081    w: &'a mut W,
1082}
1083impl<'a> I2C0_SDA_W<'a> {
1084    #[doc = r"Writes `variant` to the field"]
1085    #[inline(always)]
1086    pub fn variant(self, variant: I2C0_SDA_A) -> &'a mut W {
1087        self.bit(variant.into())
1088    }
1089    #[doc = "I2C0_SDA enabled on pin PIO0_11."]
1090    #[inline(always)]
1091    pub fn enabled(self) -> &'a mut W {
1092        self.variant(I2C0_SDA_A::ENABLED)
1093    }
1094    #[doc = "I2C0_SDA disabled."]
1095    #[inline(always)]
1096    pub fn disabled(self) -> &'a mut W {
1097        self.variant(I2C0_SDA_A::DISABLED)
1098    }
1099    #[doc = r"Sets the field bit"]
1100    #[inline(always)]
1101    pub fn set_bit(self) -> &'a mut W {
1102        self.bit(true)
1103    }
1104    #[doc = r"Clears the field bit"]
1105    #[inline(always)]
1106    pub fn clear_bit(self) -> &'a mut W {
1107        self.bit(false)
1108    }
1109    #[doc = r"Writes raw bits to the field"]
1110    #[inline(always)]
1111    pub fn bit(self, value: bool) -> &'a mut W {
1112        self.w.bits = (self.w.bits & !(0x01 << 12)) | ((value as u32 & 0x01) << 12);
1113        self.w
1114    }
1115}
1116#[doc = "I2C0_SCL function select.\n\nValue on reset: 1"]
1117#[derive(Clone, Copy, Debug, PartialEq)]
1118pub enum I2C0_SCL_A {
1119    #[doc = "0: I2C0_SCL enabled on pin PIO0_10."]
1120    ENABLED = 0,
1121    #[doc = "1: I2C0_SCL disabled."]
1122    DISABLED = 1,
1123}
1124impl From<I2C0_SCL_A> for bool {
1125    #[inline(always)]
1126    fn from(variant: I2C0_SCL_A) -> Self {
1127        variant as u8 != 0
1128    }
1129}
1130#[doc = "Field `I2C0_SCL` reader - I2C0_SCL function select."]
1131pub struct I2C0_SCL_R(crate::FieldReader<bool, I2C0_SCL_A>);
1132impl I2C0_SCL_R {
1133    pub(crate) fn new(bits: bool) -> Self {
1134        I2C0_SCL_R(crate::FieldReader::new(bits))
1135    }
1136    #[doc = r"Get enumerated values variant"]
1137    #[inline(always)]
1138    pub fn variant(&self) -> I2C0_SCL_A {
1139        match self.bits {
1140            false => I2C0_SCL_A::ENABLED,
1141            true => I2C0_SCL_A::DISABLED,
1142        }
1143    }
1144    #[doc = "Checks if the value of the field is `ENABLED`"]
1145    #[inline(always)]
1146    pub fn is_enabled(&self) -> bool {
1147        **self == I2C0_SCL_A::ENABLED
1148    }
1149    #[doc = "Checks if the value of the field is `DISABLED`"]
1150    #[inline(always)]
1151    pub fn is_disabled(&self) -> bool {
1152        **self == I2C0_SCL_A::DISABLED
1153    }
1154}
1155impl core::ops::Deref for I2C0_SCL_R {
1156    type Target = crate::FieldReader<bool, I2C0_SCL_A>;
1157    #[inline(always)]
1158    fn deref(&self) -> &Self::Target {
1159        &self.0
1160    }
1161}
1162#[doc = "Field `I2C0_SCL` writer - I2C0_SCL function select."]
1163pub struct I2C0_SCL_W<'a> {
1164    w: &'a mut W,
1165}
1166impl<'a> I2C0_SCL_W<'a> {
1167    #[doc = r"Writes `variant` to the field"]
1168    #[inline(always)]
1169    pub fn variant(self, variant: I2C0_SCL_A) -> &'a mut W {
1170        self.bit(variant.into())
1171    }
1172    #[doc = "I2C0_SCL enabled on pin PIO0_10."]
1173    #[inline(always)]
1174    pub fn enabled(self) -> &'a mut W {
1175        self.variant(I2C0_SCL_A::ENABLED)
1176    }
1177    #[doc = "I2C0_SCL disabled."]
1178    #[inline(always)]
1179    pub fn disabled(self) -> &'a mut W {
1180        self.variant(I2C0_SCL_A::DISABLED)
1181    }
1182    #[doc = r"Sets the field bit"]
1183    #[inline(always)]
1184    pub fn set_bit(self) -> &'a mut W {
1185        self.bit(true)
1186    }
1187    #[doc = r"Clears the field bit"]
1188    #[inline(always)]
1189    pub fn clear_bit(self) -> &'a mut W {
1190        self.bit(false)
1191    }
1192    #[doc = r"Writes raw bits to the field"]
1193    #[inline(always)]
1194    pub fn bit(self, value: bool) -> &'a mut W {
1195        self.w.bits = (self.w.bits & !(0x01 << 13)) | ((value as u32 & 0x01) << 13);
1196        self.w
1197    }
1198}
1199#[doc = "ADC_0 function select.\n\nValue on reset: 1"]
1200#[derive(Clone, Copy, Debug, PartialEq)]
1201pub enum ADC_0_A {
1202    #[doc = "0: ADC_0 enabled on pin PIO0_7."]
1203    ENABLED = 0,
1204    #[doc = "1: ADC_0 disabled."]
1205    DISABLED = 1,
1206}
1207impl From<ADC_0_A> for bool {
1208    #[inline(always)]
1209    fn from(variant: ADC_0_A) -> Self {
1210        variant as u8 != 0
1211    }
1212}
1213#[doc = "Field `ADC_0` reader - ADC_0 function select."]
1214pub struct ADC_0_R(crate::FieldReader<bool, ADC_0_A>);
1215impl ADC_0_R {
1216    pub(crate) fn new(bits: bool) -> Self {
1217        ADC_0_R(crate::FieldReader::new(bits))
1218    }
1219    #[doc = r"Get enumerated values variant"]
1220    #[inline(always)]
1221    pub fn variant(&self) -> ADC_0_A {
1222        match self.bits {
1223            false => ADC_0_A::ENABLED,
1224            true => ADC_0_A::DISABLED,
1225        }
1226    }
1227    #[doc = "Checks if the value of the field is `ENABLED`"]
1228    #[inline(always)]
1229    pub fn is_enabled(&self) -> bool {
1230        **self == ADC_0_A::ENABLED
1231    }
1232    #[doc = "Checks if the value of the field is `DISABLED`"]
1233    #[inline(always)]
1234    pub fn is_disabled(&self) -> bool {
1235        **self == ADC_0_A::DISABLED
1236    }
1237}
1238impl core::ops::Deref for ADC_0_R {
1239    type Target = crate::FieldReader<bool, ADC_0_A>;
1240    #[inline(always)]
1241    fn deref(&self) -> &Self::Target {
1242        &self.0
1243    }
1244}
1245#[doc = "Field `ADC_0` writer - ADC_0 function select."]
1246pub struct ADC_0_W<'a> {
1247    w: &'a mut W,
1248}
1249impl<'a> ADC_0_W<'a> {
1250    #[doc = r"Writes `variant` to the field"]
1251    #[inline(always)]
1252    pub fn variant(self, variant: ADC_0_A) -> &'a mut W {
1253        self.bit(variant.into())
1254    }
1255    #[doc = "ADC_0 enabled on pin PIO0_7."]
1256    #[inline(always)]
1257    pub fn enabled(self) -> &'a mut W {
1258        self.variant(ADC_0_A::ENABLED)
1259    }
1260    #[doc = "ADC_0 disabled."]
1261    #[inline(always)]
1262    pub fn disabled(self) -> &'a mut W {
1263        self.variant(ADC_0_A::DISABLED)
1264    }
1265    #[doc = r"Sets the field bit"]
1266    #[inline(always)]
1267    pub fn set_bit(self) -> &'a mut W {
1268        self.bit(true)
1269    }
1270    #[doc = r"Clears the field bit"]
1271    #[inline(always)]
1272    pub fn clear_bit(self) -> &'a mut W {
1273        self.bit(false)
1274    }
1275    #[doc = r"Writes raw bits to the field"]
1276    #[inline(always)]
1277    pub fn bit(self, value: bool) -> &'a mut W {
1278        self.w.bits = (self.w.bits & !(0x01 << 14)) | ((value as u32 & 0x01) << 14);
1279        self.w
1280    }
1281}
1282#[doc = "ADC_1 function select.\n\nValue on reset: 1"]
1283#[derive(Clone, Copy, Debug, PartialEq)]
1284pub enum ADC_1_A {
1285    #[doc = "0: ADC_1 enabled on pin PIO0_6."]
1286    ENABLED = 0,
1287    #[doc = "1: ADC_1 disabled."]
1288    DISABLED = 1,
1289}
1290impl From<ADC_1_A> for bool {
1291    #[inline(always)]
1292    fn from(variant: ADC_1_A) -> Self {
1293        variant as u8 != 0
1294    }
1295}
1296#[doc = "Field `ADC_1` reader - ADC_1 function select."]
1297pub struct ADC_1_R(crate::FieldReader<bool, ADC_1_A>);
1298impl ADC_1_R {
1299    pub(crate) fn new(bits: bool) -> Self {
1300        ADC_1_R(crate::FieldReader::new(bits))
1301    }
1302    #[doc = r"Get enumerated values variant"]
1303    #[inline(always)]
1304    pub fn variant(&self) -> ADC_1_A {
1305        match self.bits {
1306            false => ADC_1_A::ENABLED,
1307            true => ADC_1_A::DISABLED,
1308        }
1309    }
1310    #[doc = "Checks if the value of the field is `ENABLED`"]
1311    #[inline(always)]
1312    pub fn is_enabled(&self) -> bool {
1313        **self == ADC_1_A::ENABLED
1314    }
1315    #[doc = "Checks if the value of the field is `DISABLED`"]
1316    #[inline(always)]
1317    pub fn is_disabled(&self) -> bool {
1318        **self == ADC_1_A::DISABLED
1319    }
1320}
1321impl core::ops::Deref for ADC_1_R {
1322    type Target = crate::FieldReader<bool, ADC_1_A>;
1323    #[inline(always)]
1324    fn deref(&self) -> &Self::Target {
1325        &self.0
1326    }
1327}
1328#[doc = "Field `ADC_1` writer - ADC_1 function select."]
1329pub struct ADC_1_W<'a> {
1330    w: &'a mut W,
1331}
1332impl<'a> ADC_1_W<'a> {
1333    #[doc = r"Writes `variant` to the field"]
1334    #[inline(always)]
1335    pub fn variant(self, variant: ADC_1_A) -> &'a mut W {
1336        self.bit(variant.into())
1337    }
1338    #[doc = "ADC_1 enabled on pin PIO0_6."]
1339    #[inline(always)]
1340    pub fn enabled(self) -> &'a mut W {
1341        self.variant(ADC_1_A::ENABLED)
1342    }
1343    #[doc = "ADC_1 disabled."]
1344    #[inline(always)]
1345    pub fn disabled(self) -> &'a mut W {
1346        self.variant(ADC_1_A::DISABLED)
1347    }
1348    #[doc = r"Sets the field bit"]
1349    #[inline(always)]
1350    pub fn set_bit(self) -> &'a mut W {
1351        self.bit(true)
1352    }
1353    #[doc = r"Clears the field bit"]
1354    #[inline(always)]
1355    pub fn clear_bit(self) -> &'a mut W {
1356        self.bit(false)
1357    }
1358    #[doc = r"Writes raw bits to the field"]
1359    #[inline(always)]
1360    pub fn bit(self, value: bool) -> &'a mut W {
1361        self.w.bits = (self.w.bits & !(0x01 << 15)) | ((value as u32 & 0x01) << 15);
1362        self.w
1363    }
1364}
1365#[doc = "ADC_2 function select.\n\nValue on reset: 1"]
1366#[derive(Clone, Copy, Debug, PartialEq)]
1367pub enum ADC_2_A {
1368    #[doc = "0: ADC_2 enabled on pin PIO0_14."]
1369    ENABLED = 0,
1370    #[doc = "1: ADC_2 disabled."]
1371    DISABLED = 1,
1372}
1373impl From<ADC_2_A> for bool {
1374    #[inline(always)]
1375    fn from(variant: ADC_2_A) -> Self {
1376        variant as u8 != 0
1377    }
1378}
1379#[doc = "Field `ADC_2` reader - ADC_2 function select."]
1380pub struct ADC_2_R(crate::FieldReader<bool, ADC_2_A>);
1381impl ADC_2_R {
1382    pub(crate) fn new(bits: bool) -> Self {
1383        ADC_2_R(crate::FieldReader::new(bits))
1384    }
1385    #[doc = r"Get enumerated values variant"]
1386    #[inline(always)]
1387    pub fn variant(&self) -> ADC_2_A {
1388        match self.bits {
1389            false => ADC_2_A::ENABLED,
1390            true => ADC_2_A::DISABLED,
1391        }
1392    }
1393    #[doc = "Checks if the value of the field is `ENABLED`"]
1394    #[inline(always)]
1395    pub fn is_enabled(&self) -> bool {
1396        **self == ADC_2_A::ENABLED
1397    }
1398    #[doc = "Checks if the value of the field is `DISABLED`"]
1399    #[inline(always)]
1400    pub fn is_disabled(&self) -> bool {
1401        **self == ADC_2_A::DISABLED
1402    }
1403}
1404impl core::ops::Deref for ADC_2_R {
1405    type Target = crate::FieldReader<bool, ADC_2_A>;
1406    #[inline(always)]
1407    fn deref(&self) -> &Self::Target {
1408        &self.0
1409    }
1410}
1411#[doc = "Field `ADC_2` writer - ADC_2 function select."]
1412pub struct ADC_2_W<'a> {
1413    w: &'a mut W,
1414}
1415impl<'a> ADC_2_W<'a> {
1416    #[doc = r"Writes `variant` to the field"]
1417    #[inline(always)]
1418    pub fn variant(self, variant: ADC_2_A) -> &'a mut W {
1419        self.bit(variant.into())
1420    }
1421    #[doc = "ADC_2 enabled on pin PIO0_14."]
1422    #[inline(always)]
1423    pub fn enabled(self) -> &'a mut W {
1424        self.variant(ADC_2_A::ENABLED)
1425    }
1426    #[doc = "ADC_2 disabled."]
1427    #[inline(always)]
1428    pub fn disabled(self) -> &'a mut W {
1429        self.variant(ADC_2_A::DISABLED)
1430    }
1431    #[doc = r"Sets the field bit"]
1432    #[inline(always)]
1433    pub fn set_bit(self) -> &'a mut W {
1434        self.bit(true)
1435    }
1436    #[doc = r"Clears the field bit"]
1437    #[inline(always)]
1438    pub fn clear_bit(self) -> &'a mut W {
1439        self.bit(false)
1440    }
1441    #[doc = r"Writes raw bits to the field"]
1442    #[inline(always)]
1443    pub fn bit(self, value: bool) -> &'a mut W {
1444        self.w.bits = (self.w.bits & !(0x01 << 16)) | ((value as u32 & 0x01) << 16);
1445        self.w
1446    }
1447}
1448#[doc = "ADC_3 function select.\n\nValue on reset: 1"]
1449#[derive(Clone, Copy, Debug, PartialEq)]
1450pub enum ADC_3_A {
1451    #[doc = "0: ADC_3 enabled on pin PIO0_23."]
1452    ENABLED = 0,
1453    #[doc = "1: ADC_3 disabled."]
1454    DISABLED = 1,
1455}
1456impl From<ADC_3_A> for bool {
1457    #[inline(always)]
1458    fn from(variant: ADC_3_A) -> Self {
1459        variant as u8 != 0
1460    }
1461}
1462#[doc = "Field `ADC_3` reader - ADC_3 function select."]
1463pub struct ADC_3_R(crate::FieldReader<bool, ADC_3_A>);
1464impl ADC_3_R {
1465    pub(crate) fn new(bits: bool) -> Self {
1466        ADC_3_R(crate::FieldReader::new(bits))
1467    }
1468    #[doc = r"Get enumerated values variant"]
1469    #[inline(always)]
1470    pub fn variant(&self) -> ADC_3_A {
1471        match self.bits {
1472            false => ADC_3_A::ENABLED,
1473            true => ADC_3_A::DISABLED,
1474        }
1475    }
1476    #[doc = "Checks if the value of the field is `ENABLED`"]
1477    #[inline(always)]
1478    pub fn is_enabled(&self) -> bool {
1479        **self == ADC_3_A::ENABLED
1480    }
1481    #[doc = "Checks if the value of the field is `DISABLED`"]
1482    #[inline(always)]
1483    pub fn is_disabled(&self) -> bool {
1484        **self == ADC_3_A::DISABLED
1485    }
1486}
1487impl core::ops::Deref for ADC_3_R {
1488    type Target = crate::FieldReader<bool, ADC_3_A>;
1489    #[inline(always)]
1490    fn deref(&self) -> &Self::Target {
1491        &self.0
1492    }
1493}
1494#[doc = "Field `ADC_3` writer - ADC_3 function select."]
1495pub struct ADC_3_W<'a> {
1496    w: &'a mut W,
1497}
1498impl<'a> ADC_3_W<'a> {
1499    #[doc = r"Writes `variant` to the field"]
1500    #[inline(always)]
1501    pub fn variant(self, variant: ADC_3_A) -> &'a mut W {
1502        self.bit(variant.into())
1503    }
1504    #[doc = "ADC_3 enabled on pin PIO0_23."]
1505    #[inline(always)]
1506    pub fn enabled(self) -> &'a mut W {
1507        self.variant(ADC_3_A::ENABLED)
1508    }
1509    #[doc = "ADC_3 disabled."]
1510    #[inline(always)]
1511    pub fn disabled(self) -> &'a mut W {
1512        self.variant(ADC_3_A::DISABLED)
1513    }
1514    #[doc = r"Sets the field bit"]
1515    #[inline(always)]
1516    pub fn set_bit(self) -> &'a mut W {
1517        self.bit(true)
1518    }
1519    #[doc = r"Clears the field bit"]
1520    #[inline(always)]
1521    pub fn clear_bit(self) -> &'a mut W {
1522        self.bit(false)
1523    }
1524    #[doc = r"Writes raw bits to the field"]
1525    #[inline(always)]
1526    pub fn bit(self, value: bool) -> &'a mut W {
1527        self.w.bits = (self.w.bits & !(0x01 << 17)) | ((value as u32 & 0x01) << 17);
1528        self.w
1529    }
1530}
1531#[doc = "ADC_4 function select.\n\nValue on reset: 1"]
1532#[derive(Clone, Copy, Debug, PartialEq)]
1533pub enum ADC_4_A {
1534    #[doc = "0: ADC_4 enabled on pin PIO0_22."]
1535    ENABLED = 0,
1536    #[doc = "1: ADC_4 disabled."]
1537    DISABLED = 1,
1538}
1539impl From<ADC_4_A> for bool {
1540    #[inline(always)]
1541    fn from(variant: ADC_4_A) -> Self {
1542        variant as u8 != 0
1543    }
1544}
1545#[doc = "Field `ADC_4` reader - ADC_4 function select."]
1546pub struct ADC_4_R(crate::FieldReader<bool, ADC_4_A>);
1547impl ADC_4_R {
1548    pub(crate) fn new(bits: bool) -> Self {
1549        ADC_4_R(crate::FieldReader::new(bits))
1550    }
1551    #[doc = r"Get enumerated values variant"]
1552    #[inline(always)]
1553    pub fn variant(&self) -> ADC_4_A {
1554        match self.bits {
1555            false => ADC_4_A::ENABLED,
1556            true => ADC_4_A::DISABLED,
1557        }
1558    }
1559    #[doc = "Checks if the value of the field is `ENABLED`"]
1560    #[inline(always)]
1561    pub fn is_enabled(&self) -> bool {
1562        **self == ADC_4_A::ENABLED
1563    }
1564    #[doc = "Checks if the value of the field is `DISABLED`"]
1565    #[inline(always)]
1566    pub fn is_disabled(&self) -> bool {
1567        **self == ADC_4_A::DISABLED
1568    }
1569}
1570impl core::ops::Deref for ADC_4_R {
1571    type Target = crate::FieldReader<bool, ADC_4_A>;
1572    #[inline(always)]
1573    fn deref(&self) -> &Self::Target {
1574        &self.0
1575    }
1576}
1577#[doc = "Field `ADC_4` writer - ADC_4 function select."]
1578pub struct ADC_4_W<'a> {
1579    w: &'a mut W,
1580}
1581impl<'a> ADC_4_W<'a> {
1582    #[doc = r"Writes `variant` to the field"]
1583    #[inline(always)]
1584    pub fn variant(self, variant: ADC_4_A) -> &'a mut W {
1585        self.bit(variant.into())
1586    }
1587    #[doc = "ADC_4 enabled on pin PIO0_22."]
1588    #[inline(always)]
1589    pub fn enabled(self) -> &'a mut W {
1590        self.variant(ADC_4_A::ENABLED)
1591    }
1592    #[doc = "ADC_4 disabled."]
1593    #[inline(always)]
1594    pub fn disabled(self) -> &'a mut W {
1595        self.variant(ADC_4_A::DISABLED)
1596    }
1597    #[doc = r"Sets the field bit"]
1598    #[inline(always)]
1599    pub fn set_bit(self) -> &'a mut W {
1600        self.bit(true)
1601    }
1602    #[doc = r"Clears the field bit"]
1603    #[inline(always)]
1604    pub fn clear_bit(self) -> &'a mut W {
1605        self.bit(false)
1606    }
1607    #[doc = r"Writes raw bits to the field"]
1608    #[inline(always)]
1609    pub fn bit(self, value: bool) -> &'a mut W {
1610        self.w.bits = (self.w.bits & !(0x01 << 18)) | ((value as u32 & 0x01) << 18);
1611        self.w
1612    }
1613}
1614#[doc = "ADC_5 function select.\n\nValue on reset: 1"]
1615#[derive(Clone, Copy, Debug, PartialEq)]
1616pub enum ADC_5_A {
1617    #[doc = "0: ADC_5 enabled on pin PIO0_21."]
1618    ENABLED = 0,
1619    #[doc = "1: ADC_5 disabled."]
1620    DISABLED = 1,
1621}
1622impl From<ADC_5_A> for bool {
1623    #[inline(always)]
1624    fn from(variant: ADC_5_A) -> Self {
1625        variant as u8 != 0
1626    }
1627}
1628#[doc = "Field `ADC_5` reader - ADC_5 function select."]
1629pub struct ADC_5_R(crate::FieldReader<bool, ADC_5_A>);
1630impl ADC_5_R {
1631    pub(crate) fn new(bits: bool) -> Self {
1632        ADC_5_R(crate::FieldReader::new(bits))
1633    }
1634    #[doc = r"Get enumerated values variant"]
1635    #[inline(always)]
1636    pub fn variant(&self) -> ADC_5_A {
1637        match self.bits {
1638            false => ADC_5_A::ENABLED,
1639            true => ADC_5_A::DISABLED,
1640        }
1641    }
1642    #[doc = "Checks if the value of the field is `ENABLED`"]
1643    #[inline(always)]
1644    pub fn is_enabled(&self) -> bool {
1645        **self == ADC_5_A::ENABLED
1646    }
1647    #[doc = "Checks if the value of the field is `DISABLED`"]
1648    #[inline(always)]
1649    pub fn is_disabled(&self) -> bool {
1650        **self == ADC_5_A::DISABLED
1651    }
1652}
1653impl core::ops::Deref for ADC_5_R {
1654    type Target = crate::FieldReader<bool, ADC_5_A>;
1655    #[inline(always)]
1656    fn deref(&self) -> &Self::Target {
1657        &self.0
1658    }
1659}
1660#[doc = "Field `ADC_5` writer - ADC_5 function select."]
1661pub struct ADC_5_W<'a> {
1662    w: &'a mut W,
1663}
1664impl<'a> ADC_5_W<'a> {
1665    #[doc = r"Writes `variant` to the field"]
1666    #[inline(always)]
1667    pub fn variant(self, variant: ADC_5_A) -> &'a mut W {
1668        self.bit(variant.into())
1669    }
1670    #[doc = "ADC_5 enabled on pin PIO0_21."]
1671    #[inline(always)]
1672    pub fn enabled(self) -> &'a mut W {
1673        self.variant(ADC_5_A::ENABLED)
1674    }
1675    #[doc = "ADC_5 disabled."]
1676    #[inline(always)]
1677    pub fn disabled(self) -> &'a mut W {
1678        self.variant(ADC_5_A::DISABLED)
1679    }
1680    #[doc = r"Sets the field bit"]
1681    #[inline(always)]
1682    pub fn set_bit(self) -> &'a mut W {
1683        self.bit(true)
1684    }
1685    #[doc = r"Clears the field bit"]
1686    #[inline(always)]
1687    pub fn clear_bit(self) -> &'a mut W {
1688        self.bit(false)
1689    }
1690    #[doc = r"Writes raw bits to the field"]
1691    #[inline(always)]
1692    pub fn bit(self, value: bool) -> &'a mut W {
1693        self.w.bits = (self.w.bits & !(0x01 << 19)) | ((value as u32 & 0x01) << 19);
1694        self.w
1695    }
1696}
1697#[doc = "ADC_6 function select.\n\nValue on reset: 1"]
1698#[derive(Clone, Copy, Debug, PartialEq)]
1699pub enum ADC_6_A {
1700    #[doc = "0: ADC_6 enabled on pin PIO0_20."]
1701    ENABLED = 0,
1702    #[doc = "1: ADC_6 disabled."]
1703    DISABLED = 1,
1704}
1705impl From<ADC_6_A> for bool {
1706    #[inline(always)]
1707    fn from(variant: ADC_6_A) -> Self {
1708        variant as u8 != 0
1709    }
1710}
1711#[doc = "Field `ADC_6` reader - ADC_6 function select."]
1712pub struct ADC_6_R(crate::FieldReader<bool, ADC_6_A>);
1713impl ADC_6_R {
1714    pub(crate) fn new(bits: bool) -> Self {
1715        ADC_6_R(crate::FieldReader::new(bits))
1716    }
1717    #[doc = r"Get enumerated values variant"]
1718    #[inline(always)]
1719    pub fn variant(&self) -> ADC_6_A {
1720        match self.bits {
1721            false => ADC_6_A::ENABLED,
1722            true => ADC_6_A::DISABLED,
1723        }
1724    }
1725    #[doc = "Checks if the value of the field is `ENABLED`"]
1726    #[inline(always)]
1727    pub fn is_enabled(&self) -> bool {
1728        **self == ADC_6_A::ENABLED
1729    }
1730    #[doc = "Checks if the value of the field is `DISABLED`"]
1731    #[inline(always)]
1732    pub fn is_disabled(&self) -> bool {
1733        **self == ADC_6_A::DISABLED
1734    }
1735}
1736impl core::ops::Deref for ADC_6_R {
1737    type Target = crate::FieldReader<bool, ADC_6_A>;
1738    #[inline(always)]
1739    fn deref(&self) -> &Self::Target {
1740        &self.0
1741    }
1742}
1743#[doc = "Field `ADC_6` writer - ADC_6 function select."]
1744pub struct ADC_6_W<'a> {
1745    w: &'a mut W,
1746}
1747impl<'a> ADC_6_W<'a> {
1748    #[doc = r"Writes `variant` to the field"]
1749    #[inline(always)]
1750    pub fn variant(self, variant: ADC_6_A) -> &'a mut W {
1751        self.bit(variant.into())
1752    }
1753    #[doc = "ADC_6 enabled on pin PIO0_20."]
1754    #[inline(always)]
1755    pub fn enabled(self) -> &'a mut W {
1756        self.variant(ADC_6_A::ENABLED)
1757    }
1758    #[doc = "ADC_6 disabled."]
1759    #[inline(always)]
1760    pub fn disabled(self) -> &'a mut W {
1761        self.variant(ADC_6_A::DISABLED)
1762    }
1763    #[doc = r"Sets the field bit"]
1764    #[inline(always)]
1765    pub fn set_bit(self) -> &'a mut W {
1766        self.bit(true)
1767    }
1768    #[doc = r"Clears the field bit"]
1769    #[inline(always)]
1770    pub fn clear_bit(self) -> &'a mut W {
1771        self.bit(false)
1772    }
1773    #[doc = r"Writes raw bits to the field"]
1774    #[inline(always)]
1775    pub fn bit(self, value: bool) -> &'a mut W {
1776        self.w.bits = (self.w.bits & !(0x01 << 20)) | ((value as u32 & 0x01) << 20);
1777        self.w
1778    }
1779}
1780#[doc = "ADC_7 function select.\n\nValue on reset: 1"]
1781#[derive(Clone, Copy, Debug, PartialEq)]
1782pub enum ADC_7_A {
1783    #[doc = "0: ADC_7 enabled on pin PIO0_19."]
1784    ENABLED = 0,
1785    #[doc = "1: ADC_7 disabled."]
1786    DISABLED = 1,
1787}
1788impl From<ADC_7_A> for bool {
1789    #[inline(always)]
1790    fn from(variant: ADC_7_A) -> Self {
1791        variant as u8 != 0
1792    }
1793}
1794#[doc = "Field `ADC_7` reader - ADC_7 function select."]
1795pub struct ADC_7_R(crate::FieldReader<bool, ADC_7_A>);
1796impl ADC_7_R {
1797    pub(crate) fn new(bits: bool) -> Self {
1798        ADC_7_R(crate::FieldReader::new(bits))
1799    }
1800    #[doc = r"Get enumerated values variant"]
1801    #[inline(always)]
1802    pub fn variant(&self) -> ADC_7_A {
1803        match self.bits {
1804            false => ADC_7_A::ENABLED,
1805            true => ADC_7_A::DISABLED,
1806        }
1807    }
1808    #[doc = "Checks if the value of the field is `ENABLED`"]
1809    #[inline(always)]
1810    pub fn is_enabled(&self) -> bool {
1811        **self == ADC_7_A::ENABLED
1812    }
1813    #[doc = "Checks if the value of the field is `DISABLED`"]
1814    #[inline(always)]
1815    pub fn is_disabled(&self) -> bool {
1816        **self == ADC_7_A::DISABLED
1817    }
1818}
1819impl core::ops::Deref for ADC_7_R {
1820    type Target = crate::FieldReader<bool, ADC_7_A>;
1821    #[inline(always)]
1822    fn deref(&self) -> &Self::Target {
1823        &self.0
1824    }
1825}
1826#[doc = "Field `ADC_7` writer - ADC_7 function select."]
1827pub struct ADC_7_W<'a> {
1828    w: &'a mut W,
1829}
1830impl<'a> ADC_7_W<'a> {
1831    #[doc = r"Writes `variant` to the field"]
1832    #[inline(always)]
1833    pub fn variant(self, variant: ADC_7_A) -> &'a mut W {
1834        self.bit(variant.into())
1835    }
1836    #[doc = "ADC_7 enabled on pin PIO0_19."]
1837    #[inline(always)]
1838    pub fn enabled(self) -> &'a mut W {
1839        self.variant(ADC_7_A::ENABLED)
1840    }
1841    #[doc = "ADC_7 disabled."]
1842    #[inline(always)]
1843    pub fn disabled(self) -> &'a mut W {
1844        self.variant(ADC_7_A::DISABLED)
1845    }
1846    #[doc = r"Sets the field bit"]
1847    #[inline(always)]
1848    pub fn set_bit(self) -> &'a mut W {
1849        self.bit(true)
1850    }
1851    #[doc = r"Clears the field bit"]
1852    #[inline(always)]
1853    pub fn clear_bit(self) -> &'a mut W {
1854        self.bit(false)
1855    }
1856    #[doc = r"Writes raw bits to the field"]
1857    #[inline(always)]
1858    pub fn bit(self, value: bool) -> &'a mut W {
1859        self.w.bits = (self.w.bits & !(0x01 << 21)) | ((value as u32 & 0x01) << 21);
1860        self.w
1861    }
1862}
1863#[doc = "ADC_8 function select.\n\nValue on reset: 1"]
1864#[derive(Clone, Copy, Debug, PartialEq)]
1865pub enum ADC_8_A {
1866    #[doc = "0: ADC_8 enabled on pin PIO0_18."]
1867    ENABLED = 0,
1868    #[doc = "1: ADC_8 disabled."]
1869    DISABLED = 1,
1870}
1871impl From<ADC_8_A> for bool {
1872    #[inline(always)]
1873    fn from(variant: ADC_8_A) -> Self {
1874        variant as u8 != 0
1875    }
1876}
1877#[doc = "Field `ADC_8` reader - ADC_8 function select."]
1878pub struct ADC_8_R(crate::FieldReader<bool, ADC_8_A>);
1879impl ADC_8_R {
1880    pub(crate) fn new(bits: bool) -> Self {
1881        ADC_8_R(crate::FieldReader::new(bits))
1882    }
1883    #[doc = r"Get enumerated values variant"]
1884    #[inline(always)]
1885    pub fn variant(&self) -> ADC_8_A {
1886        match self.bits {
1887            false => ADC_8_A::ENABLED,
1888            true => ADC_8_A::DISABLED,
1889        }
1890    }
1891    #[doc = "Checks if the value of the field is `ENABLED`"]
1892    #[inline(always)]
1893    pub fn is_enabled(&self) -> bool {
1894        **self == ADC_8_A::ENABLED
1895    }
1896    #[doc = "Checks if the value of the field is `DISABLED`"]
1897    #[inline(always)]
1898    pub fn is_disabled(&self) -> bool {
1899        **self == ADC_8_A::DISABLED
1900    }
1901}
1902impl core::ops::Deref for ADC_8_R {
1903    type Target = crate::FieldReader<bool, ADC_8_A>;
1904    #[inline(always)]
1905    fn deref(&self) -> &Self::Target {
1906        &self.0
1907    }
1908}
1909#[doc = "Field `ADC_8` writer - ADC_8 function select."]
1910pub struct ADC_8_W<'a> {
1911    w: &'a mut W,
1912}
1913impl<'a> ADC_8_W<'a> {
1914    #[doc = r"Writes `variant` to the field"]
1915    #[inline(always)]
1916    pub fn variant(self, variant: ADC_8_A) -> &'a mut W {
1917        self.bit(variant.into())
1918    }
1919    #[doc = "ADC_8 enabled on pin PIO0_18."]
1920    #[inline(always)]
1921    pub fn enabled(self) -> &'a mut W {
1922        self.variant(ADC_8_A::ENABLED)
1923    }
1924    #[doc = "ADC_8 disabled."]
1925    #[inline(always)]
1926    pub fn disabled(self) -> &'a mut W {
1927        self.variant(ADC_8_A::DISABLED)
1928    }
1929    #[doc = r"Sets the field bit"]
1930    #[inline(always)]
1931    pub fn set_bit(self) -> &'a mut W {
1932        self.bit(true)
1933    }
1934    #[doc = r"Clears the field bit"]
1935    #[inline(always)]
1936    pub fn clear_bit(self) -> &'a mut W {
1937        self.bit(false)
1938    }
1939    #[doc = r"Writes raw bits to the field"]
1940    #[inline(always)]
1941    pub fn bit(self, value: bool) -> &'a mut W {
1942        self.w.bits = (self.w.bits & !(0x01 << 22)) | ((value as u32 & 0x01) << 22);
1943        self.w
1944    }
1945}
1946#[doc = "ADC_9 function select.\n\nValue on reset: 1"]
1947#[derive(Clone, Copy, Debug, PartialEq)]
1948pub enum ADC_9_A {
1949    #[doc = "0: ADC_9 enabled on pin PIO0_17."]
1950    ENABLED = 0,
1951    #[doc = "1: ADC_9 disabled."]
1952    DISABLED = 1,
1953}
1954impl From<ADC_9_A> for bool {
1955    #[inline(always)]
1956    fn from(variant: ADC_9_A) -> Self {
1957        variant as u8 != 0
1958    }
1959}
1960#[doc = "Field `ADC_9` reader - ADC_9 function select."]
1961pub struct ADC_9_R(crate::FieldReader<bool, ADC_9_A>);
1962impl ADC_9_R {
1963    pub(crate) fn new(bits: bool) -> Self {
1964        ADC_9_R(crate::FieldReader::new(bits))
1965    }
1966    #[doc = r"Get enumerated values variant"]
1967    #[inline(always)]
1968    pub fn variant(&self) -> ADC_9_A {
1969        match self.bits {
1970            false => ADC_9_A::ENABLED,
1971            true => ADC_9_A::DISABLED,
1972        }
1973    }
1974    #[doc = "Checks if the value of the field is `ENABLED`"]
1975    #[inline(always)]
1976    pub fn is_enabled(&self) -> bool {
1977        **self == ADC_9_A::ENABLED
1978    }
1979    #[doc = "Checks if the value of the field is `DISABLED`"]
1980    #[inline(always)]
1981    pub fn is_disabled(&self) -> bool {
1982        **self == ADC_9_A::DISABLED
1983    }
1984}
1985impl core::ops::Deref for ADC_9_R {
1986    type Target = crate::FieldReader<bool, ADC_9_A>;
1987    #[inline(always)]
1988    fn deref(&self) -> &Self::Target {
1989        &self.0
1990    }
1991}
1992#[doc = "Field `ADC_9` writer - ADC_9 function select."]
1993pub struct ADC_9_W<'a> {
1994    w: &'a mut W,
1995}
1996impl<'a> ADC_9_W<'a> {
1997    #[doc = r"Writes `variant` to the field"]
1998    #[inline(always)]
1999    pub fn variant(self, variant: ADC_9_A) -> &'a mut W {
2000        self.bit(variant.into())
2001    }
2002    #[doc = "ADC_9 enabled on pin PIO0_17."]
2003    #[inline(always)]
2004    pub fn enabled(self) -> &'a mut W {
2005        self.variant(ADC_9_A::ENABLED)
2006    }
2007    #[doc = "ADC_9 disabled."]
2008    #[inline(always)]
2009    pub fn disabled(self) -> &'a mut W {
2010        self.variant(ADC_9_A::DISABLED)
2011    }
2012    #[doc = r"Sets the field bit"]
2013    #[inline(always)]
2014    pub fn set_bit(self) -> &'a mut W {
2015        self.bit(true)
2016    }
2017    #[doc = r"Clears the field bit"]
2018    #[inline(always)]
2019    pub fn clear_bit(self) -> &'a mut W {
2020        self.bit(false)
2021    }
2022    #[doc = r"Writes raw bits to the field"]
2023    #[inline(always)]
2024    pub fn bit(self, value: bool) -> &'a mut W {
2025        self.w.bits = (self.w.bits & !(0x01 << 23)) | ((value as u32 & 0x01) << 23);
2026        self.w
2027    }
2028}
2029#[doc = "ADC_10 function select.\n\nValue on reset: 1"]
2030#[derive(Clone, Copy, Debug, PartialEq)]
2031pub enum ADC_10_A {
2032    #[doc = "0: ADC_10 enabled on pin PIO0_13."]
2033    ENABLED = 0,
2034    #[doc = "1: ADC_10 disabled."]
2035    DISABLED = 1,
2036}
2037impl From<ADC_10_A> for bool {
2038    #[inline(always)]
2039    fn from(variant: ADC_10_A) -> Self {
2040        variant as u8 != 0
2041    }
2042}
2043#[doc = "Field `ADC_10` reader - ADC_10 function select."]
2044pub struct ADC_10_R(crate::FieldReader<bool, ADC_10_A>);
2045impl ADC_10_R {
2046    pub(crate) fn new(bits: bool) -> Self {
2047        ADC_10_R(crate::FieldReader::new(bits))
2048    }
2049    #[doc = r"Get enumerated values variant"]
2050    #[inline(always)]
2051    pub fn variant(&self) -> ADC_10_A {
2052        match self.bits {
2053            false => ADC_10_A::ENABLED,
2054            true => ADC_10_A::DISABLED,
2055        }
2056    }
2057    #[doc = "Checks if the value of the field is `ENABLED`"]
2058    #[inline(always)]
2059    pub fn is_enabled(&self) -> bool {
2060        **self == ADC_10_A::ENABLED
2061    }
2062    #[doc = "Checks if the value of the field is `DISABLED`"]
2063    #[inline(always)]
2064    pub fn is_disabled(&self) -> bool {
2065        **self == ADC_10_A::DISABLED
2066    }
2067}
2068impl core::ops::Deref for ADC_10_R {
2069    type Target = crate::FieldReader<bool, ADC_10_A>;
2070    #[inline(always)]
2071    fn deref(&self) -> &Self::Target {
2072        &self.0
2073    }
2074}
2075#[doc = "Field `ADC_10` writer - ADC_10 function select."]
2076pub struct ADC_10_W<'a> {
2077    w: &'a mut W,
2078}
2079impl<'a> ADC_10_W<'a> {
2080    #[doc = r"Writes `variant` to the field"]
2081    #[inline(always)]
2082    pub fn variant(self, variant: ADC_10_A) -> &'a mut W {
2083        self.bit(variant.into())
2084    }
2085    #[doc = "ADC_10 enabled on pin PIO0_13."]
2086    #[inline(always)]
2087    pub fn enabled(self) -> &'a mut W {
2088        self.variant(ADC_10_A::ENABLED)
2089    }
2090    #[doc = "ADC_10 disabled."]
2091    #[inline(always)]
2092    pub fn disabled(self) -> &'a mut W {
2093        self.variant(ADC_10_A::DISABLED)
2094    }
2095    #[doc = r"Sets the field bit"]
2096    #[inline(always)]
2097    pub fn set_bit(self) -> &'a mut W {
2098        self.bit(true)
2099    }
2100    #[doc = r"Clears the field bit"]
2101    #[inline(always)]
2102    pub fn clear_bit(self) -> &'a mut W {
2103        self.bit(false)
2104    }
2105    #[doc = r"Writes raw bits to the field"]
2106    #[inline(always)]
2107    pub fn bit(self, value: bool) -> &'a mut W {
2108        self.w.bits = (self.w.bits & !(0x01 << 24)) | ((value as u32 & 0x01) << 24);
2109        self.w
2110    }
2111}
2112#[doc = "ADC_11 function select.\n\nValue on reset: 1"]
2113#[derive(Clone, Copy, Debug, PartialEq)]
2114pub enum ADC_11_A {
2115    #[doc = "0: ADC_11 enabled on pin PIO0_4."]
2116    ENABLED = 0,
2117    #[doc = "1: ADC_11 disabled."]
2118    DISABLED = 1,
2119}
2120impl From<ADC_11_A> for bool {
2121    #[inline(always)]
2122    fn from(variant: ADC_11_A) -> Self {
2123        variant as u8 != 0
2124    }
2125}
2126#[doc = "Field `ADC_11` reader - ADC_11 function select."]
2127pub struct ADC_11_R(crate::FieldReader<bool, ADC_11_A>);
2128impl ADC_11_R {
2129    pub(crate) fn new(bits: bool) -> Self {
2130        ADC_11_R(crate::FieldReader::new(bits))
2131    }
2132    #[doc = r"Get enumerated values variant"]
2133    #[inline(always)]
2134    pub fn variant(&self) -> ADC_11_A {
2135        match self.bits {
2136            false => ADC_11_A::ENABLED,
2137            true => ADC_11_A::DISABLED,
2138        }
2139    }
2140    #[doc = "Checks if the value of the field is `ENABLED`"]
2141    #[inline(always)]
2142    pub fn is_enabled(&self) -> bool {
2143        **self == ADC_11_A::ENABLED
2144    }
2145    #[doc = "Checks if the value of the field is `DISABLED`"]
2146    #[inline(always)]
2147    pub fn is_disabled(&self) -> bool {
2148        **self == ADC_11_A::DISABLED
2149    }
2150}
2151impl core::ops::Deref for ADC_11_R {
2152    type Target = crate::FieldReader<bool, ADC_11_A>;
2153    #[inline(always)]
2154    fn deref(&self) -> &Self::Target {
2155        &self.0
2156    }
2157}
2158#[doc = "Field `ADC_11` writer - ADC_11 function select."]
2159pub struct ADC_11_W<'a> {
2160    w: &'a mut W,
2161}
2162impl<'a> ADC_11_W<'a> {
2163    #[doc = r"Writes `variant` to the field"]
2164    #[inline(always)]
2165    pub fn variant(self, variant: ADC_11_A) -> &'a mut W {
2166        self.bit(variant.into())
2167    }
2168    #[doc = "ADC_11 enabled on pin PIO0_4."]
2169    #[inline(always)]
2170    pub fn enabled(self) -> &'a mut W {
2171        self.variant(ADC_11_A::ENABLED)
2172    }
2173    #[doc = "ADC_11 disabled."]
2174    #[inline(always)]
2175    pub fn disabled(self) -> &'a mut W {
2176        self.variant(ADC_11_A::DISABLED)
2177    }
2178    #[doc = r"Sets the field bit"]
2179    #[inline(always)]
2180    pub fn set_bit(self) -> &'a mut W {
2181        self.bit(true)
2182    }
2183    #[doc = r"Clears the field bit"]
2184    #[inline(always)]
2185    pub fn clear_bit(self) -> &'a mut W {
2186        self.bit(false)
2187    }
2188    #[doc = r"Writes raw bits to the field"]
2189    #[inline(always)]
2190    pub fn bit(self, value: bool) -> &'a mut W {
2191        self.w.bits = (self.w.bits & !(0x01 << 25)) | ((value as u32 & 0x01) << 25);
2192        self.w
2193    }
2194}
2195#[doc = "DACOUT0 function select.\n\nValue on reset: 1"]
2196#[derive(Clone, Copy, Debug, PartialEq)]
2197pub enum DACOUT0_A {
2198    #[doc = "0: DACOUT0 enabled on pin PIO0_17."]
2199    ENABLED = 0,
2200    #[doc = "1: DACOUT0 disabled."]
2201    DISABLED = 1,
2202}
2203impl From<DACOUT0_A> for bool {
2204    #[inline(always)]
2205    fn from(variant: DACOUT0_A) -> Self {
2206        variant as u8 != 0
2207    }
2208}
2209#[doc = "Field `DACOUT0` reader - DACOUT0 function select."]
2210pub struct DACOUT0_R(crate::FieldReader<bool, DACOUT0_A>);
2211impl DACOUT0_R {
2212    pub(crate) fn new(bits: bool) -> Self {
2213        DACOUT0_R(crate::FieldReader::new(bits))
2214    }
2215    #[doc = r"Get enumerated values variant"]
2216    #[inline(always)]
2217    pub fn variant(&self) -> DACOUT0_A {
2218        match self.bits {
2219            false => DACOUT0_A::ENABLED,
2220            true => DACOUT0_A::DISABLED,
2221        }
2222    }
2223    #[doc = "Checks if the value of the field is `ENABLED`"]
2224    #[inline(always)]
2225    pub fn is_enabled(&self) -> bool {
2226        **self == DACOUT0_A::ENABLED
2227    }
2228    #[doc = "Checks if the value of the field is `DISABLED`"]
2229    #[inline(always)]
2230    pub fn is_disabled(&self) -> bool {
2231        **self == DACOUT0_A::DISABLED
2232    }
2233}
2234impl core::ops::Deref for DACOUT0_R {
2235    type Target = crate::FieldReader<bool, DACOUT0_A>;
2236    #[inline(always)]
2237    fn deref(&self) -> &Self::Target {
2238        &self.0
2239    }
2240}
2241#[doc = "Field `DACOUT0` writer - DACOUT0 function select."]
2242pub struct DACOUT0_W<'a> {
2243    w: &'a mut W,
2244}
2245impl<'a> DACOUT0_W<'a> {
2246    #[doc = r"Writes `variant` to the field"]
2247    #[inline(always)]
2248    pub fn variant(self, variant: DACOUT0_A) -> &'a mut W {
2249        self.bit(variant.into())
2250    }
2251    #[doc = "DACOUT0 enabled on pin PIO0_17."]
2252    #[inline(always)]
2253    pub fn enabled(self) -> &'a mut W {
2254        self.variant(DACOUT0_A::ENABLED)
2255    }
2256    #[doc = "DACOUT0 disabled."]
2257    #[inline(always)]
2258    pub fn disabled(self) -> &'a mut W {
2259        self.variant(DACOUT0_A::DISABLED)
2260    }
2261    #[doc = r"Sets the field bit"]
2262    #[inline(always)]
2263    pub fn set_bit(self) -> &'a mut W {
2264        self.bit(true)
2265    }
2266    #[doc = r"Clears the field bit"]
2267    #[inline(always)]
2268    pub fn clear_bit(self) -> &'a mut W {
2269        self.bit(false)
2270    }
2271    #[doc = r"Writes raw bits to the field"]
2272    #[inline(always)]
2273    pub fn bit(self, value: bool) -> &'a mut W {
2274        self.w.bits = (self.w.bits & !(0x01 << 26)) | ((value as u32 & 0x01) << 26);
2275        self.w
2276    }
2277}
2278#[doc = "DACOUT1 function select.\n\nValue on reset: 1"]
2279#[derive(Clone, Copy, Debug, PartialEq)]
2280pub enum DACOUT1_A {
2281    #[doc = "0: DACOUT1 enabled on pin PIO0_29."]
2282    ENABLED = 0,
2283    #[doc = "1: DACOUT1 disabled."]
2284    DISABLED = 1,
2285}
2286impl From<DACOUT1_A> for bool {
2287    #[inline(always)]
2288    fn from(variant: DACOUT1_A) -> Self {
2289        variant as u8 != 0
2290    }
2291}
2292#[doc = "Field `DACOUT1` reader - DACOUT1 function select."]
2293pub struct DACOUT1_R(crate::FieldReader<bool, DACOUT1_A>);
2294impl DACOUT1_R {
2295    pub(crate) fn new(bits: bool) -> Self {
2296        DACOUT1_R(crate::FieldReader::new(bits))
2297    }
2298    #[doc = r"Get enumerated values variant"]
2299    #[inline(always)]
2300    pub fn variant(&self) -> DACOUT1_A {
2301        match self.bits {
2302            false => DACOUT1_A::ENABLED,
2303            true => DACOUT1_A::DISABLED,
2304        }
2305    }
2306    #[doc = "Checks if the value of the field is `ENABLED`"]
2307    #[inline(always)]
2308    pub fn is_enabled(&self) -> bool {
2309        **self == DACOUT1_A::ENABLED
2310    }
2311    #[doc = "Checks if the value of the field is `DISABLED`"]
2312    #[inline(always)]
2313    pub fn is_disabled(&self) -> bool {
2314        **self == DACOUT1_A::DISABLED
2315    }
2316}
2317impl core::ops::Deref for DACOUT1_R {
2318    type Target = crate::FieldReader<bool, DACOUT1_A>;
2319    #[inline(always)]
2320    fn deref(&self) -> &Self::Target {
2321        &self.0
2322    }
2323}
2324#[doc = "Field `DACOUT1` writer - DACOUT1 function select."]
2325pub struct DACOUT1_W<'a> {
2326    w: &'a mut W,
2327}
2328impl<'a> DACOUT1_W<'a> {
2329    #[doc = r"Writes `variant` to the field"]
2330    #[inline(always)]
2331    pub fn variant(self, variant: DACOUT1_A) -> &'a mut W {
2332        self.bit(variant.into())
2333    }
2334    #[doc = "DACOUT1 enabled on pin PIO0_29."]
2335    #[inline(always)]
2336    pub fn enabled(self) -> &'a mut W {
2337        self.variant(DACOUT1_A::ENABLED)
2338    }
2339    #[doc = "DACOUT1 disabled."]
2340    #[inline(always)]
2341    pub fn disabled(self) -> &'a mut W {
2342        self.variant(DACOUT1_A::DISABLED)
2343    }
2344    #[doc = r"Sets the field bit"]
2345    #[inline(always)]
2346    pub fn set_bit(self) -> &'a mut W {
2347        self.bit(true)
2348    }
2349    #[doc = r"Clears the field bit"]
2350    #[inline(always)]
2351    pub fn clear_bit(self) -> &'a mut W {
2352        self.bit(false)
2353    }
2354    #[doc = r"Writes raw bits to the field"]
2355    #[inline(always)]
2356    pub fn bit(self, value: bool) -> &'a mut W {
2357        self.w.bits = (self.w.bits & !(0x01 << 27)) | ((value as u32 & 0x01) << 27);
2358        self.w
2359    }
2360}
2361#[doc = "CAPT_X0 function select.\n\nValue on reset: 1"]
2362#[derive(Clone, Copy, Debug, PartialEq)]
2363pub enum CAPT_X0_A {
2364    #[doc = "0: CAPT_X0 enabled on pin PIO0_31."]
2365    ENABLED = 0,
2366    #[doc = "1: CAPT_X0 disabled."]
2367    DISABLED = 1,
2368}
2369impl From<CAPT_X0_A> for bool {
2370    #[inline(always)]
2371    fn from(variant: CAPT_X0_A) -> Self {
2372        variant as u8 != 0
2373    }
2374}
2375#[doc = "Field `CAPT_X0` reader - CAPT_X0 function select."]
2376pub struct CAPT_X0_R(crate::FieldReader<bool, CAPT_X0_A>);
2377impl CAPT_X0_R {
2378    pub(crate) fn new(bits: bool) -> Self {
2379        CAPT_X0_R(crate::FieldReader::new(bits))
2380    }
2381    #[doc = r"Get enumerated values variant"]
2382    #[inline(always)]
2383    pub fn variant(&self) -> CAPT_X0_A {
2384        match self.bits {
2385            false => CAPT_X0_A::ENABLED,
2386            true => CAPT_X0_A::DISABLED,
2387        }
2388    }
2389    #[doc = "Checks if the value of the field is `ENABLED`"]
2390    #[inline(always)]
2391    pub fn is_enabled(&self) -> bool {
2392        **self == CAPT_X0_A::ENABLED
2393    }
2394    #[doc = "Checks if the value of the field is `DISABLED`"]
2395    #[inline(always)]
2396    pub fn is_disabled(&self) -> bool {
2397        **self == CAPT_X0_A::DISABLED
2398    }
2399}
2400impl core::ops::Deref for CAPT_X0_R {
2401    type Target = crate::FieldReader<bool, CAPT_X0_A>;
2402    #[inline(always)]
2403    fn deref(&self) -> &Self::Target {
2404        &self.0
2405    }
2406}
2407#[doc = "Field `CAPT_X0` writer - CAPT_X0 function select."]
2408pub struct CAPT_X0_W<'a> {
2409    w: &'a mut W,
2410}
2411impl<'a> CAPT_X0_W<'a> {
2412    #[doc = r"Writes `variant` to the field"]
2413    #[inline(always)]
2414    pub fn variant(self, variant: CAPT_X0_A) -> &'a mut W {
2415        self.bit(variant.into())
2416    }
2417    #[doc = "CAPT_X0 enabled on pin PIO0_31."]
2418    #[inline(always)]
2419    pub fn enabled(self) -> &'a mut W {
2420        self.variant(CAPT_X0_A::ENABLED)
2421    }
2422    #[doc = "CAPT_X0 disabled."]
2423    #[inline(always)]
2424    pub fn disabled(self) -> &'a mut W {
2425        self.variant(CAPT_X0_A::DISABLED)
2426    }
2427    #[doc = r"Sets the field bit"]
2428    #[inline(always)]
2429    pub fn set_bit(self) -> &'a mut W {
2430        self.bit(true)
2431    }
2432    #[doc = r"Clears the field bit"]
2433    #[inline(always)]
2434    pub fn clear_bit(self) -> &'a mut W {
2435        self.bit(false)
2436    }
2437    #[doc = r"Writes raw bits to the field"]
2438    #[inline(always)]
2439    pub fn bit(self, value: bool) -> &'a mut W {
2440        self.w.bits = (self.w.bits & !(0x01 << 28)) | ((value as u32 & 0x01) << 28);
2441        self.w
2442    }
2443}
2444#[doc = "CAPT_X1 function select.\n\nValue on reset: 1"]
2445#[derive(Clone, Copy, Debug, PartialEq)]
2446pub enum CAPT_X1_A {
2447    #[doc = "0: CAPT_X1 enabled on pin PIO1_0."]
2448    ENABLED = 0,
2449    #[doc = "1: CAPT_X1 disabled."]
2450    DISABLED = 1,
2451}
2452impl From<CAPT_X1_A> for bool {
2453    #[inline(always)]
2454    fn from(variant: CAPT_X1_A) -> Self {
2455        variant as u8 != 0
2456    }
2457}
2458#[doc = "Field `CAPT_X1` reader - CAPT_X1 function select."]
2459pub struct CAPT_X1_R(crate::FieldReader<bool, CAPT_X1_A>);
2460impl CAPT_X1_R {
2461    pub(crate) fn new(bits: bool) -> Self {
2462        CAPT_X1_R(crate::FieldReader::new(bits))
2463    }
2464    #[doc = r"Get enumerated values variant"]
2465    #[inline(always)]
2466    pub fn variant(&self) -> CAPT_X1_A {
2467        match self.bits {
2468            false => CAPT_X1_A::ENABLED,
2469            true => CAPT_X1_A::DISABLED,
2470        }
2471    }
2472    #[doc = "Checks if the value of the field is `ENABLED`"]
2473    #[inline(always)]
2474    pub fn is_enabled(&self) -> bool {
2475        **self == CAPT_X1_A::ENABLED
2476    }
2477    #[doc = "Checks if the value of the field is `DISABLED`"]
2478    #[inline(always)]
2479    pub fn is_disabled(&self) -> bool {
2480        **self == CAPT_X1_A::DISABLED
2481    }
2482}
2483impl core::ops::Deref for CAPT_X1_R {
2484    type Target = crate::FieldReader<bool, CAPT_X1_A>;
2485    #[inline(always)]
2486    fn deref(&self) -> &Self::Target {
2487        &self.0
2488    }
2489}
2490#[doc = "Field `CAPT_X1` writer - CAPT_X1 function select."]
2491pub struct CAPT_X1_W<'a> {
2492    w: &'a mut W,
2493}
2494impl<'a> CAPT_X1_W<'a> {
2495    #[doc = r"Writes `variant` to the field"]
2496    #[inline(always)]
2497    pub fn variant(self, variant: CAPT_X1_A) -> &'a mut W {
2498        self.bit(variant.into())
2499    }
2500    #[doc = "CAPT_X1 enabled on pin PIO1_0."]
2501    #[inline(always)]
2502    pub fn enabled(self) -> &'a mut W {
2503        self.variant(CAPT_X1_A::ENABLED)
2504    }
2505    #[doc = "CAPT_X1 disabled."]
2506    #[inline(always)]
2507    pub fn disabled(self) -> &'a mut W {
2508        self.variant(CAPT_X1_A::DISABLED)
2509    }
2510    #[doc = r"Sets the field bit"]
2511    #[inline(always)]
2512    pub fn set_bit(self) -> &'a mut W {
2513        self.bit(true)
2514    }
2515    #[doc = r"Clears the field bit"]
2516    #[inline(always)]
2517    pub fn clear_bit(self) -> &'a mut W {
2518        self.bit(false)
2519    }
2520    #[doc = r"Writes raw bits to the field"]
2521    #[inline(always)]
2522    pub fn bit(self, value: bool) -> &'a mut W {
2523        self.w.bits = (self.w.bits & !(0x01 << 29)) | ((value as u32 & 0x01) << 29);
2524        self.w
2525    }
2526}
2527#[doc = "CAPT_X2 function select.\n\nValue on reset: 1"]
2528#[derive(Clone, Copy, Debug, PartialEq)]
2529pub enum CAPT_X2_A {
2530    #[doc = "0: CAPT_X2 enabled on pin PIO1_1."]
2531    ENABLED = 0,
2532    #[doc = "1: CAPT_X2 disabled."]
2533    DISABLED = 1,
2534}
2535impl From<CAPT_X2_A> for bool {
2536    #[inline(always)]
2537    fn from(variant: CAPT_X2_A) -> Self {
2538        variant as u8 != 0
2539    }
2540}
2541#[doc = "Field `CAPT_X2` reader - CAPT_X2 function select."]
2542pub struct CAPT_X2_R(crate::FieldReader<bool, CAPT_X2_A>);
2543impl CAPT_X2_R {
2544    pub(crate) fn new(bits: bool) -> Self {
2545        CAPT_X2_R(crate::FieldReader::new(bits))
2546    }
2547    #[doc = r"Get enumerated values variant"]
2548    #[inline(always)]
2549    pub fn variant(&self) -> CAPT_X2_A {
2550        match self.bits {
2551            false => CAPT_X2_A::ENABLED,
2552            true => CAPT_X2_A::DISABLED,
2553        }
2554    }
2555    #[doc = "Checks if the value of the field is `ENABLED`"]
2556    #[inline(always)]
2557    pub fn is_enabled(&self) -> bool {
2558        **self == CAPT_X2_A::ENABLED
2559    }
2560    #[doc = "Checks if the value of the field is `DISABLED`"]
2561    #[inline(always)]
2562    pub fn is_disabled(&self) -> bool {
2563        **self == CAPT_X2_A::DISABLED
2564    }
2565}
2566impl core::ops::Deref for CAPT_X2_R {
2567    type Target = crate::FieldReader<bool, CAPT_X2_A>;
2568    #[inline(always)]
2569    fn deref(&self) -> &Self::Target {
2570        &self.0
2571    }
2572}
2573#[doc = "Field `CAPT_X2` writer - CAPT_X2 function select."]
2574pub struct CAPT_X2_W<'a> {
2575    w: &'a mut W,
2576}
2577impl<'a> CAPT_X2_W<'a> {
2578    #[doc = r"Writes `variant` to the field"]
2579    #[inline(always)]
2580    pub fn variant(self, variant: CAPT_X2_A) -> &'a mut W {
2581        self.bit(variant.into())
2582    }
2583    #[doc = "CAPT_X2 enabled on pin PIO1_1."]
2584    #[inline(always)]
2585    pub fn enabled(self) -> &'a mut W {
2586        self.variant(CAPT_X2_A::ENABLED)
2587    }
2588    #[doc = "CAPT_X2 disabled."]
2589    #[inline(always)]
2590    pub fn disabled(self) -> &'a mut W {
2591        self.variant(CAPT_X2_A::DISABLED)
2592    }
2593    #[doc = r"Sets the field bit"]
2594    #[inline(always)]
2595    pub fn set_bit(self) -> &'a mut W {
2596        self.bit(true)
2597    }
2598    #[doc = r"Clears the field bit"]
2599    #[inline(always)]
2600    pub fn clear_bit(self) -> &'a mut W {
2601        self.bit(false)
2602    }
2603    #[doc = r"Writes raw bits to the field"]
2604    #[inline(always)]
2605    pub fn bit(self, value: bool) -> &'a mut W {
2606        self.w.bits = (self.w.bits & !(0x01 << 30)) | ((value as u32 & 0x01) << 30);
2607        self.w
2608    }
2609}
2610#[doc = "CAPT_X3 function select.\n\nValue on reset: 1"]
2611#[derive(Clone, Copy, Debug, PartialEq)]
2612pub enum CAPT_X3_A {
2613    #[doc = "0: CAPT_X3 enabled on pin PIO1_2."]
2614    ENABLED = 0,
2615    #[doc = "1: CAPT_X3 disabled."]
2616    DISABLED = 1,
2617}
2618impl From<CAPT_X3_A> for bool {
2619    #[inline(always)]
2620    fn from(variant: CAPT_X3_A) -> Self {
2621        variant as u8 != 0
2622    }
2623}
2624#[doc = "Field `CAPT_X3` reader - CAPT_X3 function select."]
2625pub struct CAPT_X3_R(crate::FieldReader<bool, CAPT_X3_A>);
2626impl CAPT_X3_R {
2627    pub(crate) fn new(bits: bool) -> Self {
2628        CAPT_X3_R(crate::FieldReader::new(bits))
2629    }
2630    #[doc = r"Get enumerated values variant"]
2631    #[inline(always)]
2632    pub fn variant(&self) -> CAPT_X3_A {
2633        match self.bits {
2634            false => CAPT_X3_A::ENABLED,
2635            true => CAPT_X3_A::DISABLED,
2636        }
2637    }
2638    #[doc = "Checks if the value of the field is `ENABLED`"]
2639    #[inline(always)]
2640    pub fn is_enabled(&self) -> bool {
2641        **self == CAPT_X3_A::ENABLED
2642    }
2643    #[doc = "Checks if the value of the field is `DISABLED`"]
2644    #[inline(always)]
2645    pub fn is_disabled(&self) -> bool {
2646        **self == CAPT_X3_A::DISABLED
2647    }
2648}
2649impl core::ops::Deref for CAPT_X3_R {
2650    type Target = crate::FieldReader<bool, CAPT_X3_A>;
2651    #[inline(always)]
2652    fn deref(&self) -> &Self::Target {
2653        &self.0
2654    }
2655}
2656#[doc = "Field `CAPT_X3` writer - CAPT_X3 function select."]
2657pub struct CAPT_X3_W<'a> {
2658    w: &'a mut W,
2659}
2660impl<'a> CAPT_X3_W<'a> {
2661    #[doc = r"Writes `variant` to the field"]
2662    #[inline(always)]
2663    pub fn variant(self, variant: CAPT_X3_A) -> &'a mut W {
2664        self.bit(variant.into())
2665    }
2666    #[doc = "CAPT_X3 enabled on pin PIO1_2."]
2667    #[inline(always)]
2668    pub fn enabled(self) -> &'a mut W {
2669        self.variant(CAPT_X3_A::ENABLED)
2670    }
2671    #[doc = "CAPT_X3 disabled."]
2672    #[inline(always)]
2673    pub fn disabled(self) -> &'a mut W {
2674        self.variant(CAPT_X3_A::DISABLED)
2675    }
2676    #[doc = r"Sets the field bit"]
2677    #[inline(always)]
2678    pub fn set_bit(self) -> &'a mut W {
2679        self.bit(true)
2680    }
2681    #[doc = r"Clears the field bit"]
2682    #[inline(always)]
2683    pub fn clear_bit(self) -> &'a mut W {
2684        self.bit(false)
2685    }
2686    #[doc = r"Writes raw bits to the field"]
2687    #[inline(always)]
2688    pub fn bit(self, value: bool) -> &'a mut W {
2689        self.w.bits = (self.w.bits & !(0x01 << 31)) | ((value as u32 & 0x01) << 31);
2690        self.w
2691    }
2692}
2693impl R {
2694    #[doc = "Bit 0 - ACMP_I1 function select."]
2695    #[inline(always)]
2696    pub fn acmp_i1(&self) -> ACMP_I1_R {
2697        ACMP_I1_R::new((self.bits & 0x01) != 0)
2698    }
2699    #[doc = "Bit 1 - ACMP_I2 function select."]
2700    #[inline(always)]
2701    pub fn acmp_i2(&self) -> ACMP_I2_R {
2702        ACMP_I2_R::new(((self.bits >> 1) & 0x01) != 0)
2703    }
2704    #[doc = "Bit 2 - ACMP_I3 function select."]
2705    #[inline(always)]
2706    pub fn acmp_i3(&self) -> ACMP_I3_R {
2707        ACMP_I3_R::new(((self.bits >> 2) & 0x01) != 0)
2708    }
2709    #[doc = "Bit 3 - ACMP_I4 function select."]
2710    #[inline(always)]
2711    pub fn acmp_i4(&self) -> ACMP_I4_R {
2712        ACMP_I4_R::new(((self.bits >> 3) & 0x01) != 0)
2713    }
2714    #[doc = "Bit 4 - ACMP_I5 function select."]
2715    #[inline(always)]
2716    pub fn acmp_i5(&self) -> ACMP_I5_R {
2717        ACMP_I5_R::new(((self.bits >> 4) & 0x01) != 0)
2718    }
2719    #[doc = "Bit 5 - SWCLK function select."]
2720    #[inline(always)]
2721    pub fn swclk(&self) -> SWCLK_R {
2722        SWCLK_R::new(((self.bits >> 5) & 0x01) != 0)
2723    }
2724    #[doc = "Bit 6 - SWDIO function select."]
2725    #[inline(always)]
2726    pub fn swdio(&self) -> SWDIO_R {
2727        SWDIO_R::new(((self.bits >> 6) & 0x01) != 0)
2728    }
2729    #[doc = "Bit 7 - XTALIN function select."]
2730    #[inline(always)]
2731    pub fn xtalin(&self) -> XTALIN_R {
2732        XTALIN_R::new(((self.bits >> 7) & 0x01) != 0)
2733    }
2734    #[doc = "Bit 8 - XTALOUT function select."]
2735    #[inline(always)]
2736    pub fn xtalout(&self) -> XTALOUT_R {
2737        XTALOUT_R::new(((self.bits >> 8) & 0x01) != 0)
2738    }
2739    #[doc = "Bit 9 - RESETN function select."]
2740    #[inline(always)]
2741    pub fn resetn(&self) -> RESETN_R {
2742        RESETN_R::new(((self.bits >> 9) & 0x01) != 0)
2743    }
2744    #[doc = "Bit 10 - CLKIN function select."]
2745    #[inline(always)]
2746    pub fn clkin(&self) -> CLKIN_R {
2747        CLKIN_R::new(((self.bits >> 10) & 0x01) != 0)
2748    }
2749    #[doc = "Bit 11 - VDDCMP function select."]
2750    #[inline(always)]
2751    pub fn vddcmp(&self) -> VDDCMP_R {
2752        VDDCMP_R::new(((self.bits >> 11) & 0x01) != 0)
2753    }
2754    #[doc = "Bit 12 - I2C0_SDA function select."]
2755    #[inline(always)]
2756    pub fn i2c0_sda(&self) -> I2C0_SDA_R {
2757        I2C0_SDA_R::new(((self.bits >> 12) & 0x01) != 0)
2758    }
2759    #[doc = "Bit 13 - I2C0_SCL function select."]
2760    #[inline(always)]
2761    pub fn i2c0_scl(&self) -> I2C0_SCL_R {
2762        I2C0_SCL_R::new(((self.bits >> 13) & 0x01) != 0)
2763    }
2764    #[doc = "Bit 14 - ADC_0 function select."]
2765    #[inline(always)]
2766    pub fn adc_0(&self) -> ADC_0_R {
2767        ADC_0_R::new(((self.bits >> 14) & 0x01) != 0)
2768    }
2769    #[doc = "Bit 15 - ADC_1 function select."]
2770    #[inline(always)]
2771    pub fn adc_1(&self) -> ADC_1_R {
2772        ADC_1_R::new(((self.bits >> 15) & 0x01) != 0)
2773    }
2774    #[doc = "Bit 16 - ADC_2 function select."]
2775    #[inline(always)]
2776    pub fn adc_2(&self) -> ADC_2_R {
2777        ADC_2_R::new(((self.bits >> 16) & 0x01) != 0)
2778    }
2779    #[doc = "Bit 17 - ADC_3 function select."]
2780    #[inline(always)]
2781    pub fn adc_3(&self) -> ADC_3_R {
2782        ADC_3_R::new(((self.bits >> 17) & 0x01) != 0)
2783    }
2784    #[doc = "Bit 18 - ADC_4 function select."]
2785    #[inline(always)]
2786    pub fn adc_4(&self) -> ADC_4_R {
2787        ADC_4_R::new(((self.bits >> 18) & 0x01) != 0)
2788    }
2789    #[doc = "Bit 19 - ADC_5 function select."]
2790    #[inline(always)]
2791    pub fn adc_5(&self) -> ADC_5_R {
2792        ADC_5_R::new(((self.bits >> 19) & 0x01) != 0)
2793    }
2794    #[doc = "Bit 20 - ADC_6 function select."]
2795    #[inline(always)]
2796    pub fn adc_6(&self) -> ADC_6_R {
2797        ADC_6_R::new(((self.bits >> 20) & 0x01) != 0)
2798    }
2799    #[doc = "Bit 21 - ADC_7 function select."]
2800    #[inline(always)]
2801    pub fn adc_7(&self) -> ADC_7_R {
2802        ADC_7_R::new(((self.bits >> 21) & 0x01) != 0)
2803    }
2804    #[doc = "Bit 22 - ADC_8 function select."]
2805    #[inline(always)]
2806    pub fn adc_8(&self) -> ADC_8_R {
2807        ADC_8_R::new(((self.bits >> 22) & 0x01) != 0)
2808    }
2809    #[doc = "Bit 23 - ADC_9 function select."]
2810    #[inline(always)]
2811    pub fn adc_9(&self) -> ADC_9_R {
2812        ADC_9_R::new(((self.bits >> 23) & 0x01) != 0)
2813    }
2814    #[doc = "Bit 24 - ADC_10 function select."]
2815    #[inline(always)]
2816    pub fn adc_10(&self) -> ADC_10_R {
2817        ADC_10_R::new(((self.bits >> 24) & 0x01) != 0)
2818    }
2819    #[doc = "Bit 25 - ADC_11 function select."]
2820    #[inline(always)]
2821    pub fn adc_11(&self) -> ADC_11_R {
2822        ADC_11_R::new(((self.bits >> 25) & 0x01) != 0)
2823    }
2824    #[doc = "Bit 26 - DACOUT0 function select."]
2825    #[inline(always)]
2826    pub fn dacout0(&self) -> DACOUT0_R {
2827        DACOUT0_R::new(((self.bits >> 26) & 0x01) != 0)
2828    }
2829    #[doc = "Bit 27 - DACOUT1 function select."]
2830    #[inline(always)]
2831    pub fn dacout1(&self) -> DACOUT1_R {
2832        DACOUT1_R::new(((self.bits >> 27) & 0x01) != 0)
2833    }
2834    #[doc = "Bit 28 - CAPT_X0 function select."]
2835    #[inline(always)]
2836    pub fn capt_x0(&self) -> CAPT_X0_R {
2837        CAPT_X0_R::new(((self.bits >> 28) & 0x01) != 0)
2838    }
2839    #[doc = "Bit 29 - CAPT_X1 function select."]
2840    #[inline(always)]
2841    pub fn capt_x1(&self) -> CAPT_X1_R {
2842        CAPT_X1_R::new(((self.bits >> 29) & 0x01) != 0)
2843    }
2844    #[doc = "Bit 30 - CAPT_X2 function select."]
2845    #[inline(always)]
2846    pub fn capt_x2(&self) -> CAPT_X2_R {
2847        CAPT_X2_R::new(((self.bits >> 30) & 0x01) != 0)
2848    }
2849    #[doc = "Bit 31 - CAPT_X3 function select."]
2850    #[inline(always)]
2851    pub fn capt_x3(&self) -> CAPT_X3_R {
2852        CAPT_X3_R::new(((self.bits >> 31) & 0x01) != 0)
2853    }
2854}
2855impl W {
2856    #[doc = "Bit 0 - ACMP_I1 function select."]
2857    #[inline(always)]
2858    pub fn acmp_i1(&mut self) -> ACMP_I1_W {
2859        ACMP_I1_W { w: self }
2860    }
2861    #[doc = "Bit 1 - ACMP_I2 function select."]
2862    #[inline(always)]
2863    pub fn acmp_i2(&mut self) -> ACMP_I2_W {
2864        ACMP_I2_W { w: self }
2865    }
2866    #[doc = "Bit 2 - ACMP_I3 function select."]
2867    #[inline(always)]
2868    pub fn acmp_i3(&mut self) -> ACMP_I3_W {
2869        ACMP_I3_W { w: self }
2870    }
2871    #[doc = "Bit 3 - ACMP_I4 function select."]
2872    #[inline(always)]
2873    pub fn acmp_i4(&mut self) -> ACMP_I4_W {
2874        ACMP_I4_W { w: self }
2875    }
2876    #[doc = "Bit 4 - ACMP_I5 function select."]
2877    #[inline(always)]
2878    pub fn acmp_i5(&mut self) -> ACMP_I5_W {
2879        ACMP_I5_W { w: self }
2880    }
2881    #[doc = "Bit 5 - SWCLK function select."]
2882    #[inline(always)]
2883    pub fn swclk(&mut self) -> SWCLK_W {
2884        SWCLK_W { w: self }
2885    }
2886    #[doc = "Bit 6 - SWDIO function select."]
2887    #[inline(always)]
2888    pub fn swdio(&mut self) -> SWDIO_W {
2889        SWDIO_W { w: self }
2890    }
2891    #[doc = "Bit 7 - XTALIN function select."]
2892    #[inline(always)]
2893    pub fn xtalin(&mut self) -> XTALIN_W {
2894        XTALIN_W { w: self }
2895    }
2896    #[doc = "Bit 8 - XTALOUT function select."]
2897    #[inline(always)]
2898    pub fn xtalout(&mut self) -> XTALOUT_W {
2899        XTALOUT_W { w: self }
2900    }
2901    #[doc = "Bit 9 - RESETN function select."]
2902    #[inline(always)]
2903    pub fn resetn(&mut self) -> RESETN_W {
2904        RESETN_W { w: self }
2905    }
2906    #[doc = "Bit 10 - CLKIN function select."]
2907    #[inline(always)]
2908    pub fn clkin(&mut self) -> CLKIN_W {
2909        CLKIN_W { w: self }
2910    }
2911    #[doc = "Bit 11 - VDDCMP function select."]
2912    #[inline(always)]
2913    pub fn vddcmp(&mut self) -> VDDCMP_W {
2914        VDDCMP_W { w: self }
2915    }
2916    #[doc = "Bit 12 - I2C0_SDA function select."]
2917    #[inline(always)]
2918    pub fn i2c0_sda(&mut self) -> I2C0_SDA_W {
2919        I2C0_SDA_W { w: self }
2920    }
2921    #[doc = "Bit 13 - I2C0_SCL function select."]
2922    #[inline(always)]
2923    pub fn i2c0_scl(&mut self) -> I2C0_SCL_W {
2924        I2C0_SCL_W { w: self }
2925    }
2926    #[doc = "Bit 14 - ADC_0 function select."]
2927    #[inline(always)]
2928    pub fn adc_0(&mut self) -> ADC_0_W {
2929        ADC_0_W { w: self }
2930    }
2931    #[doc = "Bit 15 - ADC_1 function select."]
2932    #[inline(always)]
2933    pub fn adc_1(&mut self) -> ADC_1_W {
2934        ADC_1_W { w: self }
2935    }
2936    #[doc = "Bit 16 - ADC_2 function select."]
2937    #[inline(always)]
2938    pub fn adc_2(&mut self) -> ADC_2_W {
2939        ADC_2_W { w: self }
2940    }
2941    #[doc = "Bit 17 - ADC_3 function select."]
2942    #[inline(always)]
2943    pub fn adc_3(&mut self) -> ADC_3_W {
2944        ADC_3_W { w: self }
2945    }
2946    #[doc = "Bit 18 - ADC_4 function select."]
2947    #[inline(always)]
2948    pub fn adc_4(&mut self) -> ADC_4_W {
2949        ADC_4_W { w: self }
2950    }
2951    #[doc = "Bit 19 - ADC_5 function select."]
2952    #[inline(always)]
2953    pub fn adc_5(&mut self) -> ADC_5_W {
2954        ADC_5_W { w: self }
2955    }
2956    #[doc = "Bit 20 - ADC_6 function select."]
2957    #[inline(always)]
2958    pub fn adc_6(&mut self) -> ADC_6_W {
2959        ADC_6_W { w: self }
2960    }
2961    #[doc = "Bit 21 - ADC_7 function select."]
2962    #[inline(always)]
2963    pub fn adc_7(&mut self) -> ADC_7_W {
2964        ADC_7_W { w: self }
2965    }
2966    #[doc = "Bit 22 - ADC_8 function select."]
2967    #[inline(always)]
2968    pub fn adc_8(&mut self) -> ADC_8_W {
2969        ADC_8_W { w: self }
2970    }
2971    #[doc = "Bit 23 - ADC_9 function select."]
2972    #[inline(always)]
2973    pub fn adc_9(&mut self) -> ADC_9_W {
2974        ADC_9_W { w: self }
2975    }
2976    #[doc = "Bit 24 - ADC_10 function select."]
2977    #[inline(always)]
2978    pub fn adc_10(&mut self) -> ADC_10_W {
2979        ADC_10_W { w: self }
2980    }
2981    #[doc = "Bit 25 - ADC_11 function select."]
2982    #[inline(always)]
2983    pub fn adc_11(&mut self) -> ADC_11_W {
2984        ADC_11_W { w: self }
2985    }
2986    #[doc = "Bit 26 - DACOUT0 function select."]
2987    #[inline(always)]
2988    pub fn dacout0(&mut self) -> DACOUT0_W {
2989        DACOUT0_W { w: self }
2990    }
2991    #[doc = "Bit 27 - DACOUT1 function select."]
2992    #[inline(always)]
2993    pub fn dacout1(&mut self) -> DACOUT1_W {
2994        DACOUT1_W { w: self }
2995    }
2996    #[doc = "Bit 28 - CAPT_X0 function select."]
2997    #[inline(always)]
2998    pub fn capt_x0(&mut self) -> CAPT_X0_W {
2999        CAPT_X0_W { w: self }
3000    }
3001    #[doc = "Bit 29 - CAPT_X1 function select."]
3002    #[inline(always)]
3003    pub fn capt_x1(&mut self) -> CAPT_X1_W {
3004        CAPT_X1_W { w: self }
3005    }
3006    #[doc = "Bit 30 - CAPT_X2 function select."]
3007    #[inline(always)]
3008    pub fn capt_x2(&mut self) -> CAPT_X2_W {
3009        CAPT_X2_W { w: self }
3010    }
3011    #[doc = "Bit 31 - CAPT_X3 function select."]
3012    #[inline(always)]
3013    pub fn capt_x3(&mut self) -> CAPT_X3_W {
3014        CAPT_X3_W { w: self }
3015    }
3016    #[doc = "Writes raw bits to the register."]
3017    #[inline(always)]
3018    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
3019        self.0.bits(bits);
3020        self
3021    }
3022}
3023#[doc = "Pin enable register 0. Enables fixed-pin functions ACMP_I0, ACMP_I1, SWCLK, SWDIO, XTALIN, XTALOUT, RESET, CLKIN, VDDCMP and so on.\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [pinenable0](index.html) module"]
3024pub struct PINENABLE0_SPEC;
3025impl crate::RegisterSpec for PINENABLE0_SPEC {
3026    type Ux = u32;
3027}
3028#[doc = "`read()` method returns [pinenable0::R](R) reader structure"]
3029impl crate::Readable for PINENABLE0_SPEC {
3030    type Reader = R;
3031}
3032#[doc = "`write(|w| ..)` method takes [pinenable0::W](W) writer structure"]
3033impl crate::Writable for PINENABLE0_SPEC {
3034    type Writer = W;
3035}
3036#[doc = "`reset()` method sets PINENABLE0 to value 0xffff_fd9f"]
3037impl crate::Resettable for PINENABLE0_SPEC {
3038    #[inline(always)]
3039    fn reset_value() -> Self::Ux {
3040        0xffff_fd9f
3041    }
3042}