ra2e1/poeg/
poegga.rs

1#[doc = "Register `POEGGA` reader"]
2pub struct R(crate::R<POEGGA_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<POEGGA_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<POEGGA_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<POEGGA_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `POEGGA` writer"]
17pub struct W(crate::W<POEGGA_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<POEGGA_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<POEGGA_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<POEGGA_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `PIDF` reader - Port Input Detection Flag"]
38pub type PIDF_R = crate::BitReader<PIDF_A>;
39#[doc = "Port Input Detection Flag\n\nValue on reset: 0"]
40#[derive(Clone, Copy, Debug, PartialEq, Eq)]
41pub enum PIDF_A {
42    #[doc = "0: No output-disable request from the GTETRGn pin occurred"]
43    _0 = 0,
44    #[doc = "1: Output-disable request from the GTETRGn pin occurred."]
45    _1 = 1,
46}
47impl From<PIDF_A> for bool {
48    #[inline(always)]
49    fn from(variant: PIDF_A) -> Self {
50        variant as u8 != 0
51    }
52}
53impl PIDF_R {
54    #[doc = "Get enumerated values variant"]
55    #[inline(always)]
56    pub fn variant(&self) -> PIDF_A {
57        match self.bits {
58            false => PIDF_A::_0,
59            true => PIDF_A::_1,
60        }
61    }
62    #[doc = "Checks if the value of the field is `_0`"]
63    #[inline(always)]
64    pub fn is_0(&self) -> bool {
65        *self == PIDF_A::_0
66    }
67    #[doc = "Checks if the value of the field is `_1`"]
68    #[inline(always)]
69    pub fn is_1(&self) -> bool {
70        *self == PIDF_A::_1
71    }
72}
73#[doc = "Field `PIDF` writer - Port Input Detection Flag"]
74pub type PIDF_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, PIDF_A, O>;
75impl<'a, const O: u8> PIDF_W<'a, O> {
76    #[doc = "No output-disable request from the GTETRGn pin occurred"]
77    #[inline(always)]
78    pub fn _0(self) -> &'a mut W {
79        self.variant(PIDF_A::_0)
80    }
81    #[doc = "Output-disable request from the GTETRGn pin occurred."]
82    #[inline(always)]
83    pub fn _1(self) -> &'a mut W {
84        self.variant(PIDF_A::_1)
85    }
86}
87#[doc = "Field `IOCF` reader - Detection Flag for GPT Output-Disable Request"]
88pub type IOCF_R = crate::BitReader<IOCF_A>;
89#[doc = "Detection Flag for GPT Output-Disable Request\n\nValue on reset: 0"]
90#[derive(Clone, Copy, Debug, PartialEq, Eq)]
91pub enum IOCF_A {
92    #[doc = "0: No output-disable request from GPT occurred."]
93    _0 = 0,
94    #[doc = "1: Output-disable request from GPT occurred."]
95    _1 = 1,
96}
97impl From<IOCF_A> for bool {
98    #[inline(always)]
99    fn from(variant: IOCF_A) -> Self {
100        variant as u8 != 0
101    }
102}
103impl IOCF_R {
104    #[doc = "Get enumerated values variant"]
105    #[inline(always)]
106    pub fn variant(&self) -> IOCF_A {
107        match self.bits {
108            false => IOCF_A::_0,
109            true => IOCF_A::_1,
110        }
111    }
112    #[doc = "Checks if the value of the field is `_0`"]
113    #[inline(always)]
114    pub fn is_0(&self) -> bool {
115        *self == IOCF_A::_0
116    }
117    #[doc = "Checks if the value of the field is `_1`"]
118    #[inline(always)]
119    pub fn is_1(&self) -> bool {
120        *self == IOCF_A::_1
121    }
122}
123#[doc = "Field `IOCF` writer - Detection Flag for GPT Output-Disable Request"]
124pub type IOCF_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, IOCF_A, O>;
125impl<'a, const O: u8> IOCF_W<'a, O> {
126    #[doc = "No output-disable request from GPT occurred."]
127    #[inline(always)]
128    pub fn _0(self) -> &'a mut W {
129        self.variant(IOCF_A::_0)
130    }
131    #[doc = "Output-disable request from GPT occurred."]
132    #[inline(always)]
133    pub fn _1(self) -> &'a mut W {
134        self.variant(IOCF_A::_1)
135    }
136}
137#[doc = "Field `OSTPF` reader - Oscillation Stop Detection Flag"]
138pub type OSTPF_R = crate::BitReader<OSTPF_A>;
139#[doc = "Oscillation Stop Detection Flag\n\nValue on reset: 0"]
140#[derive(Clone, Copy, Debug, PartialEq, Eq)]
141pub enum OSTPF_A {
142    #[doc = "0: No output-disable request from oscillation stop detection occurred"]
143    _0 = 0,
144    #[doc = "1: Output-disable request from oscillation stop detection occurred"]
145    _1 = 1,
146}
147impl From<OSTPF_A> for bool {
148    #[inline(always)]
149    fn from(variant: OSTPF_A) -> Self {
150        variant as u8 != 0
151    }
152}
153impl OSTPF_R {
154    #[doc = "Get enumerated values variant"]
155    #[inline(always)]
156    pub fn variant(&self) -> OSTPF_A {
157        match self.bits {
158            false => OSTPF_A::_0,
159            true => OSTPF_A::_1,
160        }
161    }
162    #[doc = "Checks if the value of the field is `_0`"]
163    #[inline(always)]
164    pub fn is_0(&self) -> bool {
165        *self == OSTPF_A::_0
166    }
167    #[doc = "Checks if the value of the field is `_1`"]
168    #[inline(always)]
169    pub fn is_1(&self) -> bool {
170        *self == OSTPF_A::_1
171    }
172}
173#[doc = "Field `OSTPF` writer - Oscillation Stop Detection Flag"]
174pub type OSTPF_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, OSTPF_A, O>;
175impl<'a, const O: u8> OSTPF_W<'a, O> {
176    #[doc = "No output-disable request from oscillation stop detection occurred"]
177    #[inline(always)]
178    pub fn _0(self) -> &'a mut W {
179        self.variant(OSTPF_A::_0)
180    }
181    #[doc = "Output-disable request from oscillation stop detection occurred"]
182    #[inline(always)]
183    pub fn _1(self) -> &'a mut W {
184        self.variant(OSTPF_A::_1)
185    }
186}
187#[doc = "Field `SSF` reader - Software Stop Flag"]
188pub type SSF_R = crate::BitReader<SSF_A>;
189#[doc = "Software Stop Flag\n\nValue on reset: 0"]
190#[derive(Clone, Copy, Debug, PartialEq, Eq)]
191pub enum SSF_A {
192    #[doc = "0: No output-disable request from software occurred"]
193    _0 = 0,
194    #[doc = "1: Output-disable request from software occurred"]
195    _1 = 1,
196}
197impl From<SSF_A> for bool {
198    #[inline(always)]
199    fn from(variant: SSF_A) -> Self {
200        variant as u8 != 0
201    }
202}
203impl SSF_R {
204    #[doc = "Get enumerated values variant"]
205    #[inline(always)]
206    pub fn variant(&self) -> SSF_A {
207        match self.bits {
208            false => SSF_A::_0,
209            true => SSF_A::_1,
210        }
211    }
212    #[doc = "Checks if the value of the field is `_0`"]
213    #[inline(always)]
214    pub fn is_0(&self) -> bool {
215        *self == SSF_A::_0
216    }
217    #[doc = "Checks if the value of the field is `_1`"]
218    #[inline(always)]
219    pub fn is_1(&self) -> bool {
220        *self == SSF_A::_1
221    }
222}
223#[doc = "Field `SSF` writer - Software Stop Flag"]
224pub type SSF_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, SSF_A, O>;
225impl<'a, const O: u8> SSF_W<'a, O> {
226    #[doc = "No output-disable request from software occurred"]
227    #[inline(always)]
228    pub fn _0(self) -> &'a mut W {
229        self.variant(SSF_A::_0)
230    }
231    #[doc = "Output-disable request from software occurred"]
232    #[inline(always)]
233    pub fn _1(self) -> &'a mut W {
234        self.variant(SSF_A::_1)
235    }
236}
237#[doc = "Field `PIDE` reader - Port Input Detection Enable"]
238pub type PIDE_R = crate::BitReader<PIDE_A>;
239#[doc = "Port Input Detection Enable\n\nValue on reset: 0"]
240#[derive(Clone, Copy, Debug, PartialEq, Eq)]
241pub enum PIDE_A {
242    #[doc = "0: Disable output-disable requests from the GTETRGn pins"]
243    _0 = 0,
244    #[doc = "1: Enable output-disable requests from the GTETRGn pins"]
245    _1 = 1,
246}
247impl From<PIDE_A> for bool {
248    #[inline(always)]
249    fn from(variant: PIDE_A) -> Self {
250        variant as u8 != 0
251    }
252}
253impl PIDE_R {
254    #[doc = "Get enumerated values variant"]
255    #[inline(always)]
256    pub fn variant(&self) -> PIDE_A {
257        match self.bits {
258            false => PIDE_A::_0,
259            true => PIDE_A::_1,
260        }
261    }
262    #[doc = "Checks if the value of the field is `_0`"]
263    #[inline(always)]
264    pub fn is_0(&self) -> bool {
265        *self == PIDE_A::_0
266    }
267    #[doc = "Checks if the value of the field is `_1`"]
268    #[inline(always)]
269    pub fn is_1(&self) -> bool {
270        *self == PIDE_A::_1
271    }
272}
273#[doc = "Field `PIDE` writer - Port Input Detection Enable"]
274pub type PIDE_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, PIDE_A, O>;
275impl<'a, const O: u8> PIDE_W<'a, O> {
276    #[doc = "Disable output-disable requests from the GTETRGn pins"]
277    #[inline(always)]
278    pub fn _0(self) -> &'a mut W {
279        self.variant(PIDE_A::_0)
280    }
281    #[doc = "Enable output-disable requests from the GTETRGn pins"]
282    #[inline(always)]
283    pub fn _1(self) -> &'a mut W {
284        self.variant(PIDE_A::_1)
285    }
286}
287#[doc = "Field `IOCE` reader - Enable for GPT Output-Disable Request"]
288pub type IOCE_R = crate::BitReader<IOCE_A>;
289#[doc = "Enable for GPT Output-Disable Request\n\nValue on reset: 0"]
290#[derive(Clone, Copy, Debug, PartialEq, Eq)]
291pub enum IOCE_A {
292    #[doc = "0: Disable output-disable requests from GPT"]
293    _0 = 0,
294    #[doc = "1: Enable output-disable requests from GPT"]
295    _1 = 1,
296}
297impl From<IOCE_A> for bool {
298    #[inline(always)]
299    fn from(variant: IOCE_A) -> Self {
300        variant as u8 != 0
301    }
302}
303impl IOCE_R {
304    #[doc = "Get enumerated values variant"]
305    #[inline(always)]
306    pub fn variant(&self) -> IOCE_A {
307        match self.bits {
308            false => IOCE_A::_0,
309            true => IOCE_A::_1,
310        }
311    }
312    #[doc = "Checks if the value of the field is `_0`"]
313    #[inline(always)]
314    pub fn is_0(&self) -> bool {
315        *self == IOCE_A::_0
316    }
317    #[doc = "Checks if the value of the field is `_1`"]
318    #[inline(always)]
319    pub fn is_1(&self) -> bool {
320        *self == IOCE_A::_1
321    }
322}
323#[doc = "Field `IOCE` writer - Enable for GPT Output-Disable Request"]
324pub type IOCE_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, IOCE_A, O>;
325impl<'a, const O: u8> IOCE_W<'a, O> {
326    #[doc = "Disable output-disable requests from GPT"]
327    #[inline(always)]
328    pub fn _0(self) -> &'a mut W {
329        self.variant(IOCE_A::_0)
330    }
331    #[doc = "Enable output-disable requests from GPT"]
332    #[inline(always)]
333    pub fn _1(self) -> &'a mut W {
334        self.variant(IOCE_A::_1)
335    }
336}
337#[doc = "Field `OSTPE` reader - Oscillation Stop Detection Enable"]
338pub type OSTPE_R = crate::BitReader<OSTPE_A>;
339#[doc = "Oscillation Stop Detection Enable\n\nValue on reset: 0"]
340#[derive(Clone, Copy, Debug, PartialEq, Eq)]
341pub enum OSTPE_A {
342    #[doc = "0: Disable output-disable requests from oscillation stop detection"]
343    _0 = 0,
344    #[doc = "1: Enable output-disable requests from oscillation stop detection"]
345    _1 = 1,
346}
347impl From<OSTPE_A> for bool {
348    #[inline(always)]
349    fn from(variant: OSTPE_A) -> Self {
350        variant as u8 != 0
351    }
352}
353impl OSTPE_R {
354    #[doc = "Get enumerated values variant"]
355    #[inline(always)]
356    pub fn variant(&self) -> OSTPE_A {
357        match self.bits {
358            false => OSTPE_A::_0,
359            true => OSTPE_A::_1,
360        }
361    }
362    #[doc = "Checks if the value of the field is `_0`"]
363    #[inline(always)]
364    pub fn is_0(&self) -> bool {
365        *self == OSTPE_A::_0
366    }
367    #[doc = "Checks if the value of the field is `_1`"]
368    #[inline(always)]
369    pub fn is_1(&self) -> bool {
370        *self == OSTPE_A::_1
371    }
372}
373#[doc = "Field `OSTPE` writer - Oscillation Stop Detection Enable"]
374pub type OSTPE_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, OSTPE_A, O>;
375impl<'a, const O: u8> OSTPE_W<'a, O> {
376    #[doc = "Disable output-disable requests from oscillation stop detection"]
377    #[inline(always)]
378    pub fn _0(self) -> &'a mut W {
379        self.variant(OSTPE_A::_0)
380    }
381    #[doc = "Enable output-disable requests from oscillation stop detection"]
382    #[inline(always)]
383    pub fn _1(self) -> &'a mut W {
384        self.variant(OSTPE_A::_1)
385    }
386}
387#[doc = "Field `ST` reader - GTETRGn Input Status Flag"]
388pub type ST_R = crate::BitReader<ST_A>;
389#[doc = "GTETRGn Input Status Flag\n\nValue on reset: 0"]
390#[derive(Clone, Copy, Debug, PartialEq, Eq)]
391pub enum ST_A {
392    #[doc = "0: GTETRGn input after filtering was 0"]
393    _0 = 0,
394    #[doc = "1: GTETRGn input after filtering was 1"]
395    _1 = 1,
396}
397impl From<ST_A> for bool {
398    #[inline(always)]
399    fn from(variant: ST_A) -> Self {
400        variant as u8 != 0
401    }
402}
403impl ST_R {
404    #[doc = "Get enumerated values variant"]
405    #[inline(always)]
406    pub fn variant(&self) -> ST_A {
407        match self.bits {
408            false => ST_A::_0,
409            true => ST_A::_1,
410        }
411    }
412    #[doc = "Checks if the value of the field is `_0`"]
413    #[inline(always)]
414    pub fn is_0(&self) -> bool {
415        *self == ST_A::_0
416    }
417    #[doc = "Checks if the value of the field is `_1`"]
418    #[inline(always)]
419    pub fn is_1(&self) -> bool {
420        *self == ST_A::_1
421    }
422}
423#[doc = "Field `INV` reader - GTETRGn Input Reverse"]
424pub type INV_R = crate::BitReader<INV_A>;
425#[doc = "GTETRGn Input Reverse\n\nValue on reset: 0"]
426#[derive(Clone, Copy, Debug, PartialEq, Eq)]
427pub enum INV_A {
428    #[doc = "0: Input GTETRGn as-is"]
429    _0 = 0,
430    #[doc = "1: Input GTETRGn in reverse"]
431    _1 = 1,
432}
433impl From<INV_A> for bool {
434    #[inline(always)]
435    fn from(variant: INV_A) -> Self {
436        variant as u8 != 0
437    }
438}
439impl INV_R {
440    #[doc = "Get enumerated values variant"]
441    #[inline(always)]
442    pub fn variant(&self) -> INV_A {
443        match self.bits {
444            false => INV_A::_0,
445            true => INV_A::_1,
446        }
447    }
448    #[doc = "Checks if the value of the field is `_0`"]
449    #[inline(always)]
450    pub fn is_0(&self) -> bool {
451        *self == INV_A::_0
452    }
453    #[doc = "Checks if the value of the field is `_1`"]
454    #[inline(always)]
455    pub fn is_1(&self) -> bool {
456        *self == INV_A::_1
457    }
458}
459#[doc = "Field `INV` writer - GTETRGn Input Reverse"]
460pub type INV_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, INV_A, O>;
461impl<'a, const O: u8> INV_W<'a, O> {
462    #[doc = "Input GTETRGn as-is"]
463    #[inline(always)]
464    pub fn _0(self) -> &'a mut W {
465        self.variant(INV_A::_0)
466    }
467    #[doc = "Input GTETRGn in reverse"]
468    #[inline(always)]
469    pub fn _1(self) -> &'a mut W {
470        self.variant(INV_A::_1)
471    }
472}
473#[doc = "Field `NFEN` reader - Noise Filter Enable"]
474pub type NFEN_R = crate::BitReader<NFEN_A>;
475#[doc = "Noise Filter Enable\n\nValue on reset: 0"]
476#[derive(Clone, Copy, Debug, PartialEq, Eq)]
477pub enum NFEN_A {
478    #[doc = "0: Disable noise filtering"]
479    _0 = 0,
480    #[doc = "1: Enable noise filtering"]
481    _1 = 1,
482}
483impl From<NFEN_A> for bool {
484    #[inline(always)]
485    fn from(variant: NFEN_A) -> Self {
486        variant as u8 != 0
487    }
488}
489impl NFEN_R {
490    #[doc = "Get enumerated values variant"]
491    #[inline(always)]
492    pub fn variant(&self) -> NFEN_A {
493        match self.bits {
494            false => NFEN_A::_0,
495            true => NFEN_A::_1,
496        }
497    }
498    #[doc = "Checks if the value of the field is `_0`"]
499    #[inline(always)]
500    pub fn is_0(&self) -> bool {
501        *self == NFEN_A::_0
502    }
503    #[doc = "Checks if the value of the field is `_1`"]
504    #[inline(always)]
505    pub fn is_1(&self) -> bool {
506        *self == NFEN_A::_1
507    }
508}
509#[doc = "Field `NFEN` writer - Noise Filter Enable"]
510pub type NFEN_W<'a, const O: u8> = crate::BitWriter<'a, u32, POEGGA_SPEC, NFEN_A, O>;
511impl<'a, const O: u8> NFEN_W<'a, O> {
512    #[doc = "Disable noise filtering"]
513    #[inline(always)]
514    pub fn _0(self) -> &'a mut W {
515        self.variant(NFEN_A::_0)
516    }
517    #[doc = "Enable noise filtering"]
518    #[inline(always)]
519    pub fn _1(self) -> &'a mut W {
520        self.variant(NFEN_A::_1)
521    }
522}
523#[doc = "Field `NFCS` reader - Noise Filter Clock Select"]
524pub type NFCS_R = crate::FieldReader<u8, NFCS_A>;
525#[doc = "Noise Filter Clock Select\n\nValue on reset: 0"]
526#[derive(Clone, Copy, Debug, PartialEq, Eq)]
527#[repr(u8)]
528pub enum NFCS_A {
529    #[doc = "0: Sample GTETRGn pin input level three times every PCLKB"]
530    _00 = 0,
531    #[doc = "1: Sample GTETRGn pin input level three times every PCLKB/8"]
532    _01 = 1,
533    #[doc = "2: Sample GTETRGn pin input level three times every PCLKB/32"]
534    _10 = 2,
535    #[doc = "3: Sample GTETRGn pin input level three times every PCLKB/128"]
536    _11 = 3,
537}
538impl From<NFCS_A> for u8 {
539    #[inline(always)]
540    fn from(variant: NFCS_A) -> Self {
541        variant as _
542    }
543}
544impl NFCS_R {
545    #[doc = "Get enumerated values variant"]
546    #[inline(always)]
547    pub fn variant(&self) -> NFCS_A {
548        match self.bits {
549            0 => NFCS_A::_00,
550            1 => NFCS_A::_01,
551            2 => NFCS_A::_10,
552            3 => NFCS_A::_11,
553            _ => unreachable!(),
554        }
555    }
556    #[doc = "Checks if the value of the field is `_00`"]
557    #[inline(always)]
558    pub fn is_00(&self) -> bool {
559        *self == NFCS_A::_00
560    }
561    #[doc = "Checks if the value of the field is `_01`"]
562    #[inline(always)]
563    pub fn is_01(&self) -> bool {
564        *self == NFCS_A::_01
565    }
566    #[doc = "Checks if the value of the field is `_10`"]
567    #[inline(always)]
568    pub fn is_10(&self) -> bool {
569        *self == NFCS_A::_10
570    }
571    #[doc = "Checks if the value of the field is `_11`"]
572    #[inline(always)]
573    pub fn is_11(&self) -> bool {
574        *self == NFCS_A::_11
575    }
576}
577#[doc = "Field `NFCS` writer - Noise Filter Clock Select"]
578pub type NFCS_W<'a, const O: u8> = crate::FieldWriterSafe<'a, u32, POEGGA_SPEC, u8, NFCS_A, 2, O>;
579impl<'a, const O: u8> NFCS_W<'a, O> {
580    #[doc = "Sample GTETRGn pin input level three times every PCLKB"]
581    #[inline(always)]
582    pub fn _00(self) -> &'a mut W {
583        self.variant(NFCS_A::_00)
584    }
585    #[doc = "Sample GTETRGn pin input level three times every PCLKB/8"]
586    #[inline(always)]
587    pub fn _01(self) -> &'a mut W {
588        self.variant(NFCS_A::_01)
589    }
590    #[doc = "Sample GTETRGn pin input level three times every PCLKB/32"]
591    #[inline(always)]
592    pub fn _10(self) -> &'a mut W {
593        self.variant(NFCS_A::_10)
594    }
595    #[doc = "Sample GTETRGn pin input level three times every PCLKB/128"]
596    #[inline(always)]
597    pub fn _11(self) -> &'a mut W {
598        self.variant(NFCS_A::_11)
599    }
600}
601impl R {
602    #[doc = "Bit 0 - Port Input Detection Flag"]
603    #[inline(always)]
604    pub fn pidf(&self) -> PIDF_R {
605        PIDF_R::new((self.bits & 1) != 0)
606    }
607    #[doc = "Bit 1 - Detection Flag for GPT Output-Disable Request"]
608    #[inline(always)]
609    pub fn iocf(&self) -> IOCF_R {
610        IOCF_R::new(((self.bits >> 1) & 1) != 0)
611    }
612    #[doc = "Bit 2 - Oscillation Stop Detection Flag"]
613    #[inline(always)]
614    pub fn ostpf(&self) -> OSTPF_R {
615        OSTPF_R::new(((self.bits >> 2) & 1) != 0)
616    }
617    #[doc = "Bit 3 - Software Stop Flag"]
618    #[inline(always)]
619    pub fn ssf(&self) -> SSF_R {
620        SSF_R::new(((self.bits >> 3) & 1) != 0)
621    }
622    #[doc = "Bit 4 - Port Input Detection Enable"]
623    #[inline(always)]
624    pub fn pide(&self) -> PIDE_R {
625        PIDE_R::new(((self.bits >> 4) & 1) != 0)
626    }
627    #[doc = "Bit 5 - Enable for GPT Output-Disable Request"]
628    #[inline(always)]
629    pub fn ioce(&self) -> IOCE_R {
630        IOCE_R::new(((self.bits >> 5) & 1) != 0)
631    }
632    #[doc = "Bit 6 - Oscillation Stop Detection Enable"]
633    #[inline(always)]
634    pub fn ostpe(&self) -> OSTPE_R {
635        OSTPE_R::new(((self.bits >> 6) & 1) != 0)
636    }
637    #[doc = "Bit 16 - GTETRGn Input Status Flag"]
638    #[inline(always)]
639    pub fn st(&self) -> ST_R {
640        ST_R::new(((self.bits >> 16) & 1) != 0)
641    }
642    #[doc = "Bit 28 - GTETRGn Input Reverse"]
643    #[inline(always)]
644    pub fn inv(&self) -> INV_R {
645        INV_R::new(((self.bits >> 28) & 1) != 0)
646    }
647    #[doc = "Bit 29 - Noise Filter Enable"]
648    #[inline(always)]
649    pub fn nfen(&self) -> NFEN_R {
650        NFEN_R::new(((self.bits >> 29) & 1) != 0)
651    }
652    #[doc = "Bits 30:31 - Noise Filter Clock Select"]
653    #[inline(always)]
654    pub fn nfcs(&self) -> NFCS_R {
655        NFCS_R::new(((self.bits >> 30) & 3) as u8)
656    }
657}
658impl W {
659    #[doc = "Bit 0 - Port Input Detection Flag"]
660    #[inline(always)]
661    #[must_use]
662    pub fn pidf(&mut self) -> PIDF_W<0> {
663        PIDF_W::new(self)
664    }
665    #[doc = "Bit 1 - Detection Flag for GPT Output-Disable Request"]
666    #[inline(always)]
667    #[must_use]
668    pub fn iocf(&mut self) -> IOCF_W<1> {
669        IOCF_W::new(self)
670    }
671    #[doc = "Bit 2 - Oscillation Stop Detection Flag"]
672    #[inline(always)]
673    #[must_use]
674    pub fn ostpf(&mut self) -> OSTPF_W<2> {
675        OSTPF_W::new(self)
676    }
677    #[doc = "Bit 3 - Software Stop Flag"]
678    #[inline(always)]
679    #[must_use]
680    pub fn ssf(&mut self) -> SSF_W<3> {
681        SSF_W::new(self)
682    }
683    #[doc = "Bit 4 - Port Input Detection Enable"]
684    #[inline(always)]
685    #[must_use]
686    pub fn pide(&mut self) -> PIDE_W<4> {
687        PIDE_W::new(self)
688    }
689    #[doc = "Bit 5 - Enable for GPT Output-Disable Request"]
690    #[inline(always)]
691    #[must_use]
692    pub fn ioce(&mut self) -> IOCE_W<5> {
693        IOCE_W::new(self)
694    }
695    #[doc = "Bit 6 - Oscillation Stop Detection Enable"]
696    #[inline(always)]
697    #[must_use]
698    pub fn ostpe(&mut self) -> OSTPE_W<6> {
699        OSTPE_W::new(self)
700    }
701    #[doc = "Bit 28 - GTETRGn Input Reverse"]
702    #[inline(always)]
703    #[must_use]
704    pub fn inv(&mut self) -> INV_W<28> {
705        INV_W::new(self)
706    }
707    #[doc = "Bit 29 - Noise Filter Enable"]
708    #[inline(always)]
709    #[must_use]
710    pub fn nfen(&mut self) -> NFEN_W<29> {
711        NFEN_W::new(self)
712    }
713    #[doc = "Bits 30:31 - Noise Filter Clock Select"]
714    #[inline(always)]
715    #[must_use]
716    pub fn nfcs(&mut self) -> NFCS_W<30> {
717        NFCS_W::new(self)
718    }
719    #[doc = "Writes raw bits to the register."]
720    #[inline(always)]
721    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
722        self.0.bits(bits);
723        self
724    }
725}
726#[doc = "POEG Group A Setting Register\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 [poegga](index.html) module"]
727pub struct POEGGA_SPEC;
728impl crate::RegisterSpec for POEGGA_SPEC {
729    type Ux = u32;
730}
731#[doc = "`read()` method returns [poegga::R](R) reader structure"]
732impl crate::Readable for POEGGA_SPEC {
733    type Reader = R;
734}
735#[doc = "`write(|w| ..)` method takes [poegga::W](W) writer structure"]
736impl crate::Writable for POEGGA_SPEC {
737    type Writer = W;
738    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
739    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
740}
741#[doc = "`reset()` method sets POEGGA to value 0"]
742impl crate::Resettable for POEGGA_SPEC {
743    const RESET_VALUE: Self::Ux = 0;
744}