xmc4700/port14/
pdisc.rs

1#[doc = "Register `PDISC` reader"]
2pub type R = crate::R<PDISC_SPEC>;
3#[doc = "Register `PDISC` writer"]
4pub type W = crate::W<PDISC_SPEC>;
5#[doc = "Pad Disable for Port 14 Pin 0\n\nValue on reset: 0"]
6#[derive(Clone, Copy, Debug, PartialEq, Eq)]
7pub enum PDIS0_A {
8    #[doc = "0: Pad is enabled, digital input selected."]
9    VALUE1 = 0,
10    #[doc = "1: Pad is disabled, ADC 0 analog input 0 selected."]
11    VALUE2 = 1,
12}
13impl From<PDIS0_A> for bool {
14    #[inline(always)]
15    fn from(variant: PDIS0_A) -> Self {
16        variant as u8 != 0
17    }
18}
19#[doc = "Field `PDIS0` reader - Pad Disable for Port 14 Pin 0"]
20pub type PDIS0_R = crate::BitReader<PDIS0_A>;
21impl PDIS0_R {
22    #[doc = "Get enumerated values variant"]
23    #[inline(always)]
24    pub const fn variant(&self) -> PDIS0_A {
25        match self.bits {
26            false => PDIS0_A::VALUE1,
27            true => PDIS0_A::VALUE2,
28        }
29    }
30    #[doc = "Pad is enabled, digital input selected."]
31    #[inline(always)]
32    pub fn is_value1(&self) -> bool {
33        *self == PDIS0_A::VALUE1
34    }
35    #[doc = "Pad is disabled, ADC 0 analog input 0 selected."]
36    #[inline(always)]
37    pub fn is_value2(&self) -> bool {
38        *self == PDIS0_A::VALUE2
39    }
40}
41#[doc = "Field `PDIS0` writer - Pad Disable for Port 14 Pin 0"]
42pub type PDIS0_W<'a, REG> = crate::BitWriter<'a, REG, PDIS0_A>;
43impl<'a, REG> PDIS0_W<'a, REG>
44where
45    REG: crate::Writable + crate::RegisterSpec,
46{
47    #[doc = "Pad is enabled, digital input selected."]
48    #[inline(always)]
49    pub fn value1(self) -> &'a mut crate::W<REG> {
50        self.variant(PDIS0_A::VALUE1)
51    }
52    #[doc = "Pad is disabled, ADC 0 analog input 0 selected."]
53    #[inline(always)]
54    pub fn value2(self) -> &'a mut crate::W<REG> {
55        self.variant(PDIS0_A::VALUE2)
56    }
57}
58#[doc = "Pad Disable for Port 14 Pin 1\n\nValue on reset: 0"]
59#[derive(Clone, Copy, Debug, PartialEq, Eq)]
60pub enum PDIS1_A {
61    #[doc = "0: Pad is enabled, digital input selected."]
62    VALUE1 = 0,
63    #[doc = "1: Pad is disabled, ADC 0 analog input 1 selected."]
64    VALUE2 = 1,
65}
66impl From<PDIS1_A> for bool {
67    #[inline(always)]
68    fn from(variant: PDIS1_A) -> Self {
69        variant as u8 != 0
70    }
71}
72#[doc = "Field `PDIS1` reader - Pad Disable for Port 14 Pin 1"]
73pub type PDIS1_R = crate::BitReader<PDIS1_A>;
74impl PDIS1_R {
75    #[doc = "Get enumerated values variant"]
76    #[inline(always)]
77    pub const fn variant(&self) -> PDIS1_A {
78        match self.bits {
79            false => PDIS1_A::VALUE1,
80            true => PDIS1_A::VALUE2,
81        }
82    }
83    #[doc = "Pad is enabled, digital input selected."]
84    #[inline(always)]
85    pub fn is_value1(&self) -> bool {
86        *self == PDIS1_A::VALUE1
87    }
88    #[doc = "Pad is disabled, ADC 0 analog input 1 selected."]
89    #[inline(always)]
90    pub fn is_value2(&self) -> bool {
91        *self == PDIS1_A::VALUE2
92    }
93}
94#[doc = "Field `PDIS1` writer - Pad Disable for Port 14 Pin 1"]
95pub type PDIS1_W<'a, REG> = crate::BitWriter<'a, REG, PDIS1_A>;
96impl<'a, REG> PDIS1_W<'a, REG>
97where
98    REG: crate::Writable + crate::RegisterSpec,
99{
100    #[doc = "Pad is enabled, digital input selected."]
101    #[inline(always)]
102    pub fn value1(self) -> &'a mut crate::W<REG> {
103        self.variant(PDIS1_A::VALUE1)
104    }
105    #[doc = "Pad is disabled, ADC 0 analog input 1 selected."]
106    #[inline(always)]
107    pub fn value2(self) -> &'a mut crate::W<REG> {
108        self.variant(PDIS1_A::VALUE2)
109    }
110}
111#[doc = "Pad Disable for Port 14 Pin 2\n\nValue on reset: 0"]
112#[derive(Clone, Copy, Debug, PartialEq, Eq)]
113pub enum PDIS2_A {
114    #[doc = "0: Pad is enabled, digital input selected."]
115    VALUE1 = 0,
116    #[doc = "1: Pad is disabled, ADC 0 and ADC 1 analog input 2 selected."]
117    VALUE2 = 1,
118}
119impl From<PDIS2_A> for bool {
120    #[inline(always)]
121    fn from(variant: PDIS2_A) -> Self {
122        variant as u8 != 0
123    }
124}
125#[doc = "Field `PDIS2` reader - Pad Disable for Port 14 Pin 2"]
126pub type PDIS2_R = crate::BitReader<PDIS2_A>;
127impl PDIS2_R {
128    #[doc = "Get enumerated values variant"]
129    #[inline(always)]
130    pub const fn variant(&self) -> PDIS2_A {
131        match self.bits {
132            false => PDIS2_A::VALUE1,
133            true => PDIS2_A::VALUE2,
134        }
135    }
136    #[doc = "Pad is enabled, digital input selected."]
137    #[inline(always)]
138    pub fn is_value1(&self) -> bool {
139        *self == PDIS2_A::VALUE1
140    }
141    #[doc = "Pad is disabled, ADC 0 and ADC 1 analog input 2 selected."]
142    #[inline(always)]
143    pub fn is_value2(&self) -> bool {
144        *self == PDIS2_A::VALUE2
145    }
146}
147#[doc = "Field `PDIS2` writer - Pad Disable for Port 14 Pin 2"]
148pub type PDIS2_W<'a, REG> = crate::BitWriter<'a, REG, PDIS2_A>;
149impl<'a, REG> PDIS2_W<'a, REG>
150where
151    REG: crate::Writable + crate::RegisterSpec,
152{
153    #[doc = "Pad is enabled, digital input selected."]
154    #[inline(always)]
155    pub fn value1(self) -> &'a mut crate::W<REG> {
156        self.variant(PDIS2_A::VALUE1)
157    }
158    #[doc = "Pad is disabled, ADC 0 and ADC 1 analog input 2 selected."]
159    #[inline(always)]
160    pub fn value2(self) -> &'a mut crate::W<REG> {
161        self.variant(PDIS2_A::VALUE2)
162    }
163}
164#[doc = "Pad Disable for Port 14 Pin 3\n\nValue on reset: 0"]
165#[derive(Clone, Copy, Debug, PartialEq, Eq)]
166pub enum PDIS3_A {
167    #[doc = "0: Pad is enabled, digital input selected."]
168    VALUE1 = 0,
169    #[doc = "1: Pad is disabled, ADC 0 and ADC 1 analog input 3 selected."]
170    VALUE2 = 1,
171}
172impl From<PDIS3_A> for bool {
173    #[inline(always)]
174    fn from(variant: PDIS3_A) -> Self {
175        variant as u8 != 0
176    }
177}
178#[doc = "Field `PDIS3` reader - Pad Disable for Port 14 Pin 3"]
179pub type PDIS3_R = crate::BitReader<PDIS3_A>;
180impl PDIS3_R {
181    #[doc = "Get enumerated values variant"]
182    #[inline(always)]
183    pub const fn variant(&self) -> PDIS3_A {
184        match self.bits {
185            false => PDIS3_A::VALUE1,
186            true => PDIS3_A::VALUE2,
187        }
188    }
189    #[doc = "Pad is enabled, digital input selected."]
190    #[inline(always)]
191    pub fn is_value1(&self) -> bool {
192        *self == PDIS3_A::VALUE1
193    }
194    #[doc = "Pad is disabled, ADC 0 and ADC 1 analog input 3 selected."]
195    #[inline(always)]
196    pub fn is_value2(&self) -> bool {
197        *self == PDIS3_A::VALUE2
198    }
199}
200#[doc = "Field `PDIS3` writer - Pad Disable for Port 14 Pin 3"]
201pub type PDIS3_W<'a, REG> = crate::BitWriter<'a, REG, PDIS3_A>;
202impl<'a, REG> PDIS3_W<'a, REG>
203where
204    REG: crate::Writable + crate::RegisterSpec,
205{
206    #[doc = "Pad is enabled, digital input selected."]
207    #[inline(always)]
208    pub fn value1(self) -> &'a mut crate::W<REG> {
209        self.variant(PDIS3_A::VALUE1)
210    }
211    #[doc = "Pad is disabled, ADC 0 and ADC 1 analog input 3 selected."]
212    #[inline(always)]
213    pub fn value2(self) -> &'a mut crate::W<REG> {
214        self.variant(PDIS3_A::VALUE2)
215    }
216}
217#[doc = "Pad Disable for Port 14 Pin 4\n\nValue on reset: 0"]
218#[derive(Clone, Copy, Debug, PartialEq, Eq)]
219pub enum PDIS4_A {
220    #[doc = "0: Pad is enabled, digital input selected."]
221    VALUE1 = 0,
222    #[doc = "1: Pad is disabled, ADC 0 analog input 4 and ADC 2 analog input 0 and DAC Reference selected."]
223    VALUE2 = 1,
224}
225impl From<PDIS4_A> for bool {
226    #[inline(always)]
227    fn from(variant: PDIS4_A) -> Self {
228        variant as u8 != 0
229    }
230}
231#[doc = "Field `PDIS4` reader - Pad Disable for Port 14 Pin 4"]
232pub type PDIS4_R = crate::BitReader<PDIS4_A>;
233impl PDIS4_R {
234    #[doc = "Get enumerated values variant"]
235    #[inline(always)]
236    pub const fn variant(&self) -> PDIS4_A {
237        match self.bits {
238            false => PDIS4_A::VALUE1,
239            true => PDIS4_A::VALUE2,
240        }
241    }
242    #[doc = "Pad is enabled, digital input selected."]
243    #[inline(always)]
244    pub fn is_value1(&self) -> bool {
245        *self == PDIS4_A::VALUE1
246    }
247    #[doc = "Pad is disabled, ADC 0 analog input 4 and ADC 2 analog input 0 and DAC Reference selected."]
248    #[inline(always)]
249    pub fn is_value2(&self) -> bool {
250        *self == PDIS4_A::VALUE2
251    }
252}
253#[doc = "Field `PDIS4` writer - Pad Disable for Port 14 Pin 4"]
254pub type PDIS4_W<'a, REG> = crate::BitWriter<'a, REG, PDIS4_A>;
255impl<'a, REG> PDIS4_W<'a, REG>
256where
257    REG: crate::Writable + crate::RegisterSpec,
258{
259    #[doc = "Pad is enabled, digital input selected."]
260    #[inline(always)]
261    pub fn value1(self) -> &'a mut crate::W<REG> {
262        self.variant(PDIS4_A::VALUE1)
263    }
264    #[doc = "Pad is disabled, ADC 0 analog input 4 and ADC 2 analog input 0 and DAC Reference selected."]
265    #[inline(always)]
266    pub fn value2(self) -> &'a mut crate::W<REG> {
267        self.variant(PDIS4_A::VALUE2)
268    }
269}
270#[doc = "Pad Disable for Port 14 Pin 5\n\nValue on reset: 0"]
271#[derive(Clone, Copy, Debug, PartialEq, Eq)]
272pub enum PDIS5_A {
273    #[doc = "0: Pad is enabled, digital input selected."]
274    VALUE1 = 0,
275    #[doc = "1: Pad is disabled, ADC 0 analog input 5 and ADC 2 analog input 1 selected."]
276    VALUE2 = 1,
277}
278impl From<PDIS5_A> for bool {
279    #[inline(always)]
280    fn from(variant: PDIS5_A) -> Self {
281        variant as u8 != 0
282    }
283}
284#[doc = "Field `PDIS5` reader - Pad Disable for Port 14 Pin 5"]
285pub type PDIS5_R = crate::BitReader<PDIS5_A>;
286impl PDIS5_R {
287    #[doc = "Get enumerated values variant"]
288    #[inline(always)]
289    pub const fn variant(&self) -> PDIS5_A {
290        match self.bits {
291            false => PDIS5_A::VALUE1,
292            true => PDIS5_A::VALUE2,
293        }
294    }
295    #[doc = "Pad is enabled, digital input selected."]
296    #[inline(always)]
297    pub fn is_value1(&self) -> bool {
298        *self == PDIS5_A::VALUE1
299    }
300    #[doc = "Pad is disabled, ADC 0 analog input 5 and ADC 2 analog input 1 selected."]
301    #[inline(always)]
302    pub fn is_value2(&self) -> bool {
303        *self == PDIS5_A::VALUE2
304    }
305}
306#[doc = "Field `PDIS5` writer - Pad Disable for Port 14 Pin 5"]
307pub type PDIS5_W<'a, REG> = crate::BitWriter<'a, REG, PDIS5_A>;
308impl<'a, REG> PDIS5_W<'a, REG>
309where
310    REG: crate::Writable + crate::RegisterSpec,
311{
312    #[doc = "Pad is enabled, digital input selected."]
313    #[inline(always)]
314    pub fn value1(self) -> &'a mut crate::W<REG> {
315        self.variant(PDIS5_A::VALUE1)
316    }
317    #[doc = "Pad is disabled, ADC 0 analog input 5 and ADC 2 analog input 1 selected."]
318    #[inline(always)]
319    pub fn value2(self) -> &'a mut crate::W<REG> {
320        self.variant(PDIS5_A::VALUE2)
321    }
322}
323#[doc = "Pad Disable for Port 14 Pin 6\n\nValue on reset: 0"]
324#[derive(Clone, Copy, Debug, PartialEq, Eq)]
325pub enum PDIS6_A {
326    #[doc = "0: Pad is enabled, digital input selected."]
327    VALUE1 = 0,
328    #[doc = "1: Pad is disabled, ADC 0 analog input 6 selected."]
329    VALUE2 = 1,
330}
331impl From<PDIS6_A> for bool {
332    #[inline(always)]
333    fn from(variant: PDIS6_A) -> Self {
334        variant as u8 != 0
335    }
336}
337#[doc = "Field `PDIS6` reader - Pad Disable for Port 14 Pin 6"]
338pub type PDIS6_R = crate::BitReader<PDIS6_A>;
339impl PDIS6_R {
340    #[doc = "Get enumerated values variant"]
341    #[inline(always)]
342    pub const fn variant(&self) -> PDIS6_A {
343        match self.bits {
344            false => PDIS6_A::VALUE1,
345            true => PDIS6_A::VALUE2,
346        }
347    }
348    #[doc = "Pad is enabled, digital input selected."]
349    #[inline(always)]
350    pub fn is_value1(&self) -> bool {
351        *self == PDIS6_A::VALUE1
352    }
353    #[doc = "Pad is disabled, ADC 0 analog input 6 selected."]
354    #[inline(always)]
355    pub fn is_value2(&self) -> bool {
356        *self == PDIS6_A::VALUE2
357    }
358}
359#[doc = "Field `PDIS6` writer - Pad Disable for Port 14 Pin 6"]
360pub type PDIS6_W<'a, REG> = crate::BitWriter<'a, REG, PDIS6_A>;
361impl<'a, REG> PDIS6_W<'a, REG>
362where
363    REG: crate::Writable + crate::RegisterSpec,
364{
365    #[doc = "Pad is enabled, digital input selected."]
366    #[inline(always)]
367    pub fn value1(self) -> &'a mut crate::W<REG> {
368        self.variant(PDIS6_A::VALUE1)
369    }
370    #[doc = "Pad is disabled, ADC 0 analog input 6 selected."]
371    #[inline(always)]
372    pub fn value2(self) -> &'a mut crate::W<REG> {
373        self.variant(PDIS6_A::VALUE2)
374    }
375}
376#[doc = "Pad Disable for Port 14 Pin 7\n\nValue on reset: 0"]
377#[derive(Clone, Copy, Debug, PartialEq, Eq)]
378pub enum PDIS7_A {
379    #[doc = "0: Pad is enabled, digital input selected."]
380    VALUE1 = 0,
381    #[doc = "1: Pad is disabled, ADC0 analog input 7 selected."]
382    VALUE2 = 1,
383}
384impl From<PDIS7_A> for bool {
385    #[inline(always)]
386    fn from(variant: PDIS7_A) -> Self {
387        variant as u8 != 0
388    }
389}
390#[doc = "Field `PDIS7` reader - Pad Disable for Port 14 Pin 7"]
391pub type PDIS7_R = crate::BitReader<PDIS7_A>;
392impl PDIS7_R {
393    #[doc = "Get enumerated values variant"]
394    #[inline(always)]
395    pub const fn variant(&self) -> PDIS7_A {
396        match self.bits {
397            false => PDIS7_A::VALUE1,
398            true => PDIS7_A::VALUE2,
399        }
400    }
401    #[doc = "Pad is enabled, digital input selected."]
402    #[inline(always)]
403    pub fn is_value1(&self) -> bool {
404        *self == PDIS7_A::VALUE1
405    }
406    #[doc = "Pad is disabled, ADC0 analog input 7 selected."]
407    #[inline(always)]
408    pub fn is_value2(&self) -> bool {
409        *self == PDIS7_A::VALUE2
410    }
411}
412#[doc = "Field `PDIS7` writer - Pad Disable for Port 14 Pin 7"]
413pub type PDIS7_W<'a, REG> = crate::BitWriter<'a, REG, PDIS7_A>;
414impl<'a, REG> PDIS7_W<'a, REG>
415where
416    REG: crate::Writable + crate::RegisterSpec,
417{
418    #[doc = "Pad is enabled, digital input selected."]
419    #[inline(always)]
420    pub fn value1(self) -> &'a mut crate::W<REG> {
421        self.variant(PDIS7_A::VALUE1)
422    }
423    #[doc = "Pad is disabled, ADC0 analog input 7 selected."]
424    #[inline(always)]
425    pub fn value2(self) -> &'a mut crate::W<REG> {
426        self.variant(PDIS7_A::VALUE2)
427    }
428}
429#[doc = "Pad Disable for Port 14 Pin 8\n\nValue on reset: 0"]
430#[derive(Clone, Copy, Debug, PartialEq, Eq)]
431pub enum PDIS8_A {
432    #[doc = "0: Pad is enabled, digital input selected."]
433    VALUE1 = 0,
434    #[doc = "1: Pad is disabled, ADC 1 analog input 0 and ADC 2 analog input 4 and DAC output 0 selected."]
435    VALUE2 = 1,
436}
437impl From<PDIS8_A> for bool {
438    #[inline(always)]
439    fn from(variant: PDIS8_A) -> Self {
440        variant as u8 != 0
441    }
442}
443#[doc = "Field `PDIS8` reader - Pad Disable for Port 14 Pin 8"]
444pub type PDIS8_R = crate::BitReader<PDIS8_A>;
445impl PDIS8_R {
446    #[doc = "Get enumerated values variant"]
447    #[inline(always)]
448    pub const fn variant(&self) -> PDIS8_A {
449        match self.bits {
450            false => PDIS8_A::VALUE1,
451            true => PDIS8_A::VALUE2,
452        }
453    }
454    #[doc = "Pad is enabled, digital input selected."]
455    #[inline(always)]
456    pub fn is_value1(&self) -> bool {
457        *self == PDIS8_A::VALUE1
458    }
459    #[doc = "Pad is disabled, ADC 1 analog input 0 and ADC 2 analog input 4 and DAC output 0 selected."]
460    #[inline(always)]
461    pub fn is_value2(&self) -> bool {
462        *self == PDIS8_A::VALUE2
463    }
464}
465#[doc = "Field `PDIS8` writer - Pad Disable for Port 14 Pin 8"]
466pub type PDIS8_W<'a, REG> = crate::BitWriter<'a, REG, PDIS8_A>;
467impl<'a, REG> PDIS8_W<'a, REG>
468where
469    REG: crate::Writable + crate::RegisterSpec,
470{
471    #[doc = "Pad is enabled, digital input selected."]
472    #[inline(always)]
473    pub fn value1(self) -> &'a mut crate::W<REG> {
474        self.variant(PDIS8_A::VALUE1)
475    }
476    #[doc = "Pad is disabled, ADC 1 analog input 0 and ADC 2 analog input 4 and DAC output 0 selected."]
477    #[inline(always)]
478    pub fn value2(self) -> &'a mut crate::W<REG> {
479        self.variant(PDIS8_A::VALUE2)
480    }
481}
482#[doc = "Pad Disable for Port 14 Pin 9\n\nValue on reset: 0"]
483#[derive(Clone, Copy, Debug, PartialEq, Eq)]
484pub enum PDIS9_A {
485    #[doc = "0: Pad is enabled, digital input selected."]
486    VALUE1 = 0,
487    #[doc = "1: Pad is disabled, ADC 1 analog input 1 and ADC 2 analog input 5 and DAC output 1 selected."]
488    VALUE2 = 1,
489}
490impl From<PDIS9_A> for bool {
491    #[inline(always)]
492    fn from(variant: PDIS9_A) -> Self {
493        variant as u8 != 0
494    }
495}
496#[doc = "Field `PDIS9` reader - Pad Disable for Port 14 Pin 9"]
497pub type PDIS9_R = crate::BitReader<PDIS9_A>;
498impl PDIS9_R {
499    #[doc = "Get enumerated values variant"]
500    #[inline(always)]
501    pub const fn variant(&self) -> PDIS9_A {
502        match self.bits {
503            false => PDIS9_A::VALUE1,
504            true => PDIS9_A::VALUE2,
505        }
506    }
507    #[doc = "Pad is enabled, digital input selected."]
508    #[inline(always)]
509    pub fn is_value1(&self) -> bool {
510        *self == PDIS9_A::VALUE1
511    }
512    #[doc = "Pad is disabled, ADC 1 analog input 1 and ADC 2 analog input 5 and DAC output 1 selected."]
513    #[inline(always)]
514    pub fn is_value2(&self) -> bool {
515        *self == PDIS9_A::VALUE2
516    }
517}
518#[doc = "Field `PDIS9` writer - Pad Disable for Port 14 Pin 9"]
519pub type PDIS9_W<'a, REG> = crate::BitWriter<'a, REG, PDIS9_A>;
520impl<'a, REG> PDIS9_W<'a, REG>
521where
522    REG: crate::Writable + crate::RegisterSpec,
523{
524    #[doc = "Pad is enabled, digital input selected."]
525    #[inline(always)]
526    pub fn value1(self) -> &'a mut crate::W<REG> {
527        self.variant(PDIS9_A::VALUE1)
528    }
529    #[doc = "Pad is disabled, ADC 1 analog input 1 and ADC 2 analog input 5 and DAC output 1 selected."]
530    #[inline(always)]
531    pub fn value2(self) -> &'a mut crate::W<REG> {
532        self.variant(PDIS9_A::VALUE2)
533    }
534}
535#[doc = "Pad Disable for Port 14 Pin 12\n\nValue on reset: 0"]
536#[derive(Clone, Copy, Debug, PartialEq, Eq)]
537pub enum PDIS12_A {
538    #[doc = "0: Pad is enabled, digital input selected."]
539    VALUE1 = 0,
540    #[doc = "1: Pad is disabled, ADC 1 analog input 4 selected."]
541    VALUE2 = 1,
542}
543impl From<PDIS12_A> for bool {
544    #[inline(always)]
545    fn from(variant: PDIS12_A) -> Self {
546        variant as u8 != 0
547    }
548}
549#[doc = "Field `PDIS12` reader - Pad Disable for Port 14 Pin 12"]
550pub type PDIS12_R = crate::BitReader<PDIS12_A>;
551impl PDIS12_R {
552    #[doc = "Get enumerated values variant"]
553    #[inline(always)]
554    pub const fn variant(&self) -> PDIS12_A {
555        match self.bits {
556            false => PDIS12_A::VALUE1,
557            true => PDIS12_A::VALUE2,
558        }
559    }
560    #[doc = "Pad is enabled, digital input selected."]
561    #[inline(always)]
562    pub fn is_value1(&self) -> bool {
563        *self == PDIS12_A::VALUE1
564    }
565    #[doc = "Pad is disabled, ADC 1 analog input 4 selected."]
566    #[inline(always)]
567    pub fn is_value2(&self) -> bool {
568        *self == PDIS12_A::VALUE2
569    }
570}
571#[doc = "Field `PDIS12` writer - Pad Disable for Port 14 Pin 12"]
572pub type PDIS12_W<'a, REG> = crate::BitWriter<'a, REG, PDIS12_A>;
573impl<'a, REG> PDIS12_W<'a, REG>
574where
575    REG: crate::Writable + crate::RegisterSpec,
576{
577    #[doc = "Pad is enabled, digital input selected."]
578    #[inline(always)]
579    pub fn value1(self) -> &'a mut crate::W<REG> {
580        self.variant(PDIS12_A::VALUE1)
581    }
582    #[doc = "Pad is disabled, ADC 1 analog input 4 selected."]
583    #[inline(always)]
584    pub fn value2(self) -> &'a mut crate::W<REG> {
585        self.variant(PDIS12_A::VALUE2)
586    }
587}
588#[doc = "Pad Disable for Port 14 Pin 13\n\nValue on reset: 0"]
589#[derive(Clone, Copy, Debug, PartialEq, Eq)]
590pub enum PDIS13_A {
591    #[doc = "0: Pad is enabled, digital input selected."]
592    VALUE1 = 0,
593    #[doc = "1: Pad is disabled, ADC 1 analog input 5 selected."]
594    VALUE2 = 1,
595}
596impl From<PDIS13_A> for bool {
597    #[inline(always)]
598    fn from(variant: PDIS13_A) -> Self {
599        variant as u8 != 0
600    }
601}
602#[doc = "Field `PDIS13` reader - Pad Disable for Port 14 Pin 13"]
603pub type PDIS13_R = crate::BitReader<PDIS13_A>;
604impl PDIS13_R {
605    #[doc = "Get enumerated values variant"]
606    #[inline(always)]
607    pub const fn variant(&self) -> PDIS13_A {
608        match self.bits {
609            false => PDIS13_A::VALUE1,
610            true => PDIS13_A::VALUE2,
611        }
612    }
613    #[doc = "Pad is enabled, digital input selected."]
614    #[inline(always)]
615    pub fn is_value1(&self) -> bool {
616        *self == PDIS13_A::VALUE1
617    }
618    #[doc = "Pad is disabled, ADC 1 analog input 5 selected."]
619    #[inline(always)]
620    pub fn is_value2(&self) -> bool {
621        *self == PDIS13_A::VALUE2
622    }
623}
624#[doc = "Field `PDIS13` writer - Pad Disable for Port 14 Pin 13"]
625pub type PDIS13_W<'a, REG> = crate::BitWriter<'a, REG, PDIS13_A>;
626impl<'a, REG> PDIS13_W<'a, REG>
627where
628    REG: crate::Writable + crate::RegisterSpec,
629{
630    #[doc = "Pad is enabled, digital input selected."]
631    #[inline(always)]
632    pub fn value1(self) -> &'a mut crate::W<REG> {
633        self.variant(PDIS13_A::VALUE1)
634    }
635    #[doc = "Pad is disabled, ADC 1 analog input 5 selected."]
636    #[inline(always)]
637    pub fn value2(self) -> &'a mut crate::W<REG> {
638        self.variant(PDIS13_A::VALUE2)
639    }
640}
641#[doc = "Pad Disable for Port 14 Pin 14\n\nValue on reset: 0"]
642#[derive(Clone, Copy, Debug, PartialEq, Eq)]
643pub enum PDIS14_A {
644    #[doc = "0: Pad is enabled, digital input selected."]
645    VALUE1 = 0,
646    #[doc = "1: Pad is disabled, ADC 1 analog input 6 selected."]
647    VALUE2 = 1,
648}
649impl From<PDIS14_A> for bool {
650    #[inline(always)]
651    fn from(variant: PDIS14_A) -> Self {
652        variant as u8 != 0
653    }
654}
655#[doc = "Field `PDIS14` reader - Pad Disable for Port 14 Pin 14"]
656pub type PDIS14_R = crate::BitReader<PDIS14_A>;
657impl PDIS14_R {
658    #[doc = "Get enumerated values variant"]
659    #[inline(always)]
660    pub const fn variant(&self) -> PDIS14_A {
661        match self.bits {
662            false => PDIS14_A::VALUE1,
663            true => PDIS14_A::VALUE2,
664        }
665    }
666    #[doc = "Pad is enabled, digital input selected."]
667    #[inline(always)]
668    pub fn is_value1(&self) -> bool {
669        *self == PDIS14_A::VALUE1
670    }
671    #[doc = "Pad is disabled, ADC 1 analog input 6 selected."]
672    #[inline(always)]
673    pub fn is_value2(&self) -> bool {
674        *self == PDIS14_A::VALUE2
675    }
676}
677#[doc = "Field `PDIS14` writer - Pad Disable for Port 14 Pin 14"]
678pub type PDIS14_W<'a, REG> = crate::BitWriter<'a, REG, PDIS14_A>;
679impl<'a, REG> PDIS14_W<'a, REG>
680where
681    REG: crate::Writable + crate::RegisterSpec,
682{
683    #[doc = "Pad is enabled, digital input selected."]
684    #[inline(always)]
685    pub fn value1(self) -> &'a mut crate::W<REG> {
686        self.variant(PDIS14_A::VALUE1)
687    }
688    #[doc = "Pad is disabled, ADC 1 analog input 6 selected."]
689    #[inline(always)]
690    pub fn value2(self) -> &'a mut crate::W<REG> {
691        self.variant(PDIS14_A::VALUE2)
692    }
693}
694#[doc = "Pad Disable for Port 14 Pin 15\n\nValue on reset: 0"]
695#[derive(Clone, Copy, Debug, PartialEq, Eq)]
696pub enum PDIS15_A {
697    #[doc = "0: Pad is enabled, digital input selected."]
698    VALUE1 = 0,
699    #[doc = "1: Pad is disabled, ADC 1 analog input 7 selected."]
700    VALUE2 = 1,
701}
702impl From<PDIS15_A> for bool {
703    #[inline(always)]
704    fn from(variant: PDIS15_A) -> Self {
705        variant as u8 != 0
706    }
707}
708#[doc = "Field `PDIS15` reader - Pad Disable for Port 14 Pin 15"]
709pub type PDIS15_R = crate::BitReader<PDIS15_A>;
710impl PDIS15_R {
711    #[doc = "Get enumerated values variant"]
712    #[inline(always)]
713    pub const fn variant(&self) -> PDIS15_A {
714        match self.bits {
715            false => PDIS15_A::VALUE1,
716            true => PDIS15_A::VALUE2,
717        }
718    }
719    #[doc = "Pad is enabled, digital input selected."]
720    #[inline(always)]
721    pub fn is_value1(&self) -> bool {
722        *self == PDIS15_A::VALUE1
723    }
724    #[doc = "Pad is disabled, ADC 1 analog input 7 selected."]
725    #[inline(always)]
726    pub fn is_value2(&self) -> bool {
727        *self == PDIS15_A::VALUE2
728    }
729}
730#[doc = "Field `PDIS15` writer - Pad Disable for Port 14 Pin 15"]
731pub type PDIS15_W<'a, REG> = crate::BitWriter<'a, REG, PDIS15_A>;
732impl<'a, REG> PDIS15_W<'a, REG>
733where
734    REG: crate::Writable + crate::RegisterSpec,
735{
736    #[doc = "Pad is enabled, digital input selected."]
737    #[inline(always)]
738    pub fn value1(self) -> &'a mut crate::W<REG> {
739        self.variant(PDIS15_A::VALUE1)
740    }
741    #[doc = "Pad is disabled, ADC 1 analog input 7 selected."]
742    #[inline(always)]
743    pub fn value2(self) -> &'a mut crate::W<REG> {
744        self.variant(PDIS15_A::VALUE2)
745    }
746}
747impl R {
748    #[doc = "Bit 0 - Pad Disable for Port 14 Pin 0"]
749    #[inline(always)]
750    pub fn pdis0(&self) -> PDIS0_R {
751        PDIS0_R::new((self.bits & 1) != 0)
752    }
753    #[doc = "Bit 1 - Pad Disable for Port 14 Pin 1"]
754    #[inline(always)]
755    pub fn pdis1(&self) -> PDIS1_R {
756        PDIS1_R::new(((self.bits >> 1) & 1) != 0)
757    }
758    #[doc = "Bit 2 - Pad Disable for Port 14 Pin 2"]
759    #[inline(always)]
760    pub fn pdis2(&self) -> PDIS2_R {
761        PDIS2_R::new(((self.bits >> 2) & 1) != 0)
762    }
763    #[doc = "Bit 3 - Pad Disable for Port 14 Pin 3"]
764    #[inline(always)]
765    pub fn pdis3(&self) -> PDIS3_R {
766        PDIS3_R::new(((self.bits >> 3) & 1) != 0)
767    }
768    #[doc = "Bit 4 - Pad Disable for Port 14 Pin 4"]
769    #[inline(always)]
770    pub fn pdis4(&self) -> PDIS4_R {
771        PDIS4_R::new(((self.bits >> 4) & 1) != 0)
772    }
773    #[doc = "Bit 5 - Pad Disable for Port 14 Pin 5"]
774    #[inline(always)]
775    pub fn pdis5(&self) -> PDIS5_R {
776        PDIS5_R::new(((self.bits >> 5) & 1) != 0)
777    }
778    #[doc = "Bit 6 - Pad Disable for Port 14 Pin 6"]
779    #[inline(always)]
780    pub fn pdis6(&self) -> PDIS6_R {
781        PDIS6_R::new(((self.bits >> 6) & 1) != 0)
782    }
783    #[doc = "Bit 7 - Pad Disable for Port 14 Pin 7"]
784    #[inline(always)]
785    pub fn pdis7(&self) -> PDIS7_R {
786        PDIS7_R::new(((self.bits >> 7) & 1) != 0)
787    }
788    #[doc = "Bit 8 - Pad Disable for Port 14 Pin 8"]
789    #[inline(always)]
790    pub fn pdis8(&self) -> PDIS8_R {
791        PDIS8_R::new(((self.bits >> 8) & 1) != 0)
792    }
793    #[doc = "Bit 9 - Pad Disable for Port 14 Pin 9"]
794    #[inline(always)]
795    pub fn pdis9(&self) -> PDIS9_R {
796        PDIS9_R::new(((self.bits >> 9) & 1) != 0)
797    }
798    #[doc = "Bit 12 - Pad Disable for Port 14 Pin 12"]
799    #[inline(always)]
800    pub fn pdis12(&self) -> PDIS12_R {
801        PDIS12_R::new(((self.bits >> 12) & 1) != 0)
802    }
803    #[doc = "Bit 13 - Pad Disable for Port 14 Pin 13"]
804    #[inline(always)]
805    pub fn pdis13(&self) -> PDIS13_R {
806        PDIS13_R::new(((self.bits >> 13) & 1) != 0)
807    }
808    #[doc = "Bit 14 - Pad Disable for Port 14 Pin 14"]
809    #[inline(always)]
810    pub fn pdis14(&self) -> PDIS14_R {
811        PDIS14_R::new(((self.bits >> 14) & 1) != 0)
812    }
813    #[doc = "Bit 15 - Pad Disable for Port 14 Pin 15"]
814    #[inline(always)]
815    pub fn pdis15(&self) -> PDIS15_R {
816        PDIS15_R::new(((self.bits >> 15) & 1) != 0)
817    }
818}
819impl W {
820    #[doc = "Bit 0 - Pad Disable for Port 14 Pin 0"]
821    #[inline(always)]
822    pub fn pdis0(&mut self) -> PDIS0_W<PDISC_SPEC> {
823        PDIS0_W::new(self, 0)
824    }
825    #[doc = "Bit 1 - Pad Disable for Port 14 Pin 1"]
826    #[inline(always)]
827    pub fn pdis1(&mut self) -> PDIS1_W<PDISC_SPEC> {
828        PDIS1_W::new(self, 1)
829    }
830    #[doc = "Bit 2 - Pad Disable for Port 14 Pin 2"]
831    #[inline(always)]
832    pub fn pdis2(&mut self) -> PDIS2_W<PDISC_SPEC> {
833        PDIS2_W::new(self, 2)
834    }
835    #[doc = "Bit 3 - Pad Disable for Port 14 Pin 3"]
836    #[inline(always)]
837    pub fn pdis3(&mut self) -> PDIS3_W<PDISC_SPEC> {
838        PDIS3_W::new(self, 3)
839    }
840    #[doc = "Bit 4 - Pad Disable for Port 14 Pin 4"]
841    #[inline(always)]
842    pub fn pdis4(&mut self) -> PDIS4_W<PDISC_SPEC> {
843        PDIS4_W::new(self, 4)
844    }
845    #[doc = "Bit 5 - Pad Disable for Port 14 Pin 5"]
846    #[inline(always)]
847    pub fn pdis5(&mut self) -> PDIS5_W<PDISC_SPEC> {
848        PDIS5_W::new(self, 5)
849    }
850    #[doc = "Bit 6 - Pad Disable for Port 14 Pin 6"]
851    #[inline(always)]
852    pub fn pdis6(&mut self) -> PDIS6_W<PDISC_SPEC> {
853        PDIS6_W::new(self, 6)
854    }
855    #[doc = "Bit 7 - Pad Disable for Port 14 Pin 7"]
856    #[inline(always)]
857    pub fn pdis7(&mut self) -> PDIS7_W<PDISC_SPEC> {
858        PDIS7_W::new(self, 7)
859    }
860    #[doc = "Bit 8 - Pad Disable for Port 14 Pin 8"]
861    #[inline(always)]
862    pub fn pdis8(&mut self) -> PDIS8_W<PDISC_SPEC> {
863        PDIS8_W::new(self, 8)
864    }
865    #[doc = "Bit 9 - Pad Disable for Port 14 Pin 9"]
866    #[inline(always)]
867    pub fn pdis9(&mut self) -> PDIS9_W<PDISC_SPEC> {
868        PDIS9_W::new(self, 9)
869    }
870    #[doc = "Bit 12 - Pad Disable for Port 14 Pin 12"]
871    #[inline(always)]
872    pub fn pdis12(&mut self) -> PDIS12_W<PDISC_SPEC> {
873        PDIS12_W::new(self, 12)
874    }
875    #[doc = "Bit 13 - Pad Disable for Port 14 Pin 13"]
876    #[inline(always)]
877    pub fn pdis13(&mut self) -> PDIS13_W<PDISC_SPEC> {
878        PDIS13_W::new(self, 13)
879    }
880    #[doc = "Bit 14 - Pad Disable for Port 14 Pin 14"]
881    #[inline(always)]
882    pub fn pdis14(&mut self) -> PDIS14_W<PDISC_SPEC> {
883        PDIS14_W::new(self, 14)
884    }
885    #[doc = "Bit 15 - Pad Disable for Port 14 Pin 15"]
886    #[inline(always)]
887    pub fn pdis15(&mut self) -> PDIS15_W<PDISC_SPEC> {
888        PDIS15_W::new(self, 15)
889    }
890}
891#[doc = "Port 14 Pin Function Decision Control Register\n\nYou can [`read`](crate::Reg::read) this register and get [`pdisc::R`](R). You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`pdisc::W`](W). You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
892pub struct PDISC_SPEC;
893impl crate::RegisterSpec for PDISC_SPEC {
894    type Ux = u32;
895}
896#[doc = "`read()` method returns [`pdisc::R`](R) reader structure"]
897impl crate::Readable for PDISC_SPEC {}
898#[doc = "`write(|w| ..)` method takes [`pdisc::W`](W) writer structure"]
899impl crate::Writable for PDISC_SPEC {
900    type Safety = crate::Unsafe;
901    const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
902    const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
903}
904#[doc = "`reset()` method sets PDISC to value 0"]
905impl crate::Resettable for PDISC_SPEC {
906    const RESET_VALUE: u32 = 0;
907}