nrf52840_pac/usbd/
inten.rs

1#[doc = "Register `INTEN` reader"]
2pub struct R(crate::R<INTEN_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<INTEN_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<INTEN_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<INTEN_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `INTEN` writer"]
17pub struct W(crate::W<INTEN_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<INTEN_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<INTEN_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<INTEN_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `USBRESET` reader - Enable or disable interrupt for USBRESET event"]
38pub type USBRESET_R = crate::BitReader<USBRESET_A>;
39#[doc = "Enable or disable interrupt for USBRESET event\n\nValue on reset: 0"]
40#[derive(Clone, Copy, Debug, PartialEq)]
41pub enum USBRESET_A {
42    #[doc = "0: Disable"]
43    DISABLED = 0,
44    #[doc = "1: Enable"]
45    ENABLED = 1,
46}
47impl From<USBRESET_A> for bool {
48    #[inline(always)]
49    fn from(variant: USBRESET_A) -> Self {
50        variant as u8 != 0
51    }
52}
53impl USBRESET_R {
54    #[doc = "Get enumerated values variant"]
55    #[inline(always)]
56    pub fn variant(&self) -> USBRESET_A {
57        match self.bits {
58            false => USBRESET_A::DISABLED,
59            true => USBRESET_A::ENABLED,
60        }
61    }
62    #[doc = "Checks if the value of the field is `DISABLED`"]
63    #[inline(always)]
64    pub fn is_disabled(&self) -> bool {
65        *self == USBRESET_A::DISABLED
66    }
67    #[doc = "Checks if the value of the field is `ENABLED`"]
68    #[inline(always)]
69    pub fn is_enabled(&self) -> bool {
70        *self == USBRESET_A::ENABLED
71    }
72}
73#[doc = "Field `USBRESET` writer - Enable or disable interrupt for USBRESET event"]
74pub type USBRESET_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, USBRESET_A, O>;
75impl<'a, const O: u8> USBRESET_W<'a, O> {
76    #[doc = "Disable"]
77    #[inline(always)]
78    pub fn disabled(self) -> &'a mut W {
79        self.variant(USBRESET_A::DISABLED)
80    }
81    #[doc = "Enable"]
82    #[inline(always)]
83    pub fn enabled(self) -> &'a mut W {
84        self.variant(USBRESET_A::ENABLED)
85    }
86}
87#[doc = "Field `STARTED` reader - Enable or disable interrupt for STARTED event"]
88pub type STARTED_R = crate::BitReader<STARTED_A>;
89#[doc = "Enable or disable interrupt for STARTED event\n\nValue on reset: 0"]
90#[derive(Clone, Copy, Debug, PartialEq)]
91pub enum STARTED_A {
92    #[doc = "0: Disable"]
93    DISABLED = 0,
94    #[doc = "1: Enable"]
95    ENABLED = 1,
96}
97impl From<STARTED_A> for bool {
98    #[inline(always)]
99    fn from(variant: STARTED_A) -> Self {
100        variant as u8 != 0
101    }
102}
103impl STARTED_R {
104    #[doc = "Get enumerated values variant"]
105    #[inline(always)]
106    pub fn variant(&self) -> STARTED_A {
107        match self.bits {
108            false => STARTED_A::DISABLED,
109            true => STARTED_A::ENABLED,
110        }
111    }
112    #[doc = "Checks if the value of the field is `DISABLED`"]
113    #[inline(always)]
114    pub fn is_disabled(&self) -> bool {
115        *self == STARTED_A::DISABLED
116    }
117    #[doc = "Checks if the value of the field is `ENABLED`"]
118    #[inline(always)]
119    pub fn is_enabled(&self) -> bool {
120        *self == STARTED_A::ENABLED
121    }
122}
123#[doc = "Field `STARTED` writer - Enable or disable interrupt for STARTED event"]
124pub type STARTED_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, STARTED_A, O>;
125impl<'a, const O: u8> STARTED_W<'a, O> {
126    #[doc = "Disable"]
127    #[inline(always)]
128    pub fn disabled(self) -> &'a mut W {
129        self.variant(STARTED_A::DISABLED)
130    }
131    #[doc = "Enable"]
132    #[inline(always)]
133    pub fn enabled(self) -> &'a mut W {
134        self.variant(STARTED_A::ENABLED)
135    }
136}
137#[doc = "Field `ENDEPIN0` reader - Enable or disable interrupt for ENDEPIN\\[0\\]
138event"]
139pub type ENDEPIN0_R = crate::BitReader<ENDEPIN0_A>;
140#[doc = "Enable or disable interrupt for ENDEPIN\\[0\\]
141event\n\nValue on reset: 0"]
142#[derive(Clone, Copy, Debug, PartialEq)]
143pub enum ENDEPIN0_A {
144    #[doc = "0: Disable"]
145    DISABLED = 0,
146    #[doc = "1: Enable"]
147    ENABLED = 1,
148}
149impl From<ENDEPIN0_A> for bool {
150    #[inline(always)]
151    fn from(variant: ENDEPIN0_A) -> Self {
152        variant as u8 != 0
153    }
154}
155impl ENDEPIN0_R {
156    #[doc = "Get enumerated values variant"]
157    #[inline(always)]
158    pub fn variant(&self) -> ENDEPIN0_A {
159        match self.bits {
160            false => ENDEPIN0_A::DISABLED,
161            true => ENDEPIN0_A::ENABLED,
162        }
163    }
164    #[doc = "Checks if the value of the field is `DISABLED`"]
165    #[inline(always)]
166    pub fn is_disabled(&self) -> bool {
167        *self == ENDEPIN0_A::DISABLED
168    }
169    #[doc = "Checks if the value of the field is `ENABLED`"]
170    #[inline(always)]
171    pub fn is_enabled(&self) -> bool {
172        *self == ENDEPIN0_A::ENABLED
173    }
174}
175#[doc = "Field `ENDEPIN0` writer - Enable or disable interrupt for ENDEPIN\\[0\\]
176event"]
177pub type ENDEPIN0_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN0_A, O>;
178impl<'a, const O: u8> ENDEPIN0_W<'a, O> {
179    #[doc = "Disable"]
180    #[inline(always)]
181    pub fn disabled(self) -> &'a mut W {
182        self.variant(ENDEPIN0_A::DISABLED)
183    }
184    #[doc = "Enable"]
185    #[inline(always)]
186    pub fn enabled(self) -> &'a mut W {
187        self.variant(ENDEPIN0_A::ENABLED)
188    }
189}
190#[doc = "Field `ENDEPIN1` reader - Enable or disable interrupt for ENDEPIN\\[1\\]
191event"]
192pub type ENDEPIN1_R = crate::BitReader<ENDEPIN1_A>;
193#[doc = "Enable or disable interrupt for ENDEPIN\\[1\\]
194event\n\nValue on reset: 0"]
195#[derive(Clone, Copy, Debug, PartialEq)]
196pub enum ENDEPIN1_A {
197    #[doc = "0: Disable"]
198    DISABLED = 0,
199    #[doc = "1: Enable"]
200    ENABLED = 1,
201}
202impl From<ENDEPIN1_A> for bool {
203    #[inline(always)]
204    fn from(variant: ENDEPIN1_A) -> Self {
205        variant as u8 != 0
206    }
207}
208impl ENDEPIN1_R {
209    #[doc = "Get enumerated values variant"]
210    #[inline(always)]
211    pub fn variant(&self) -> ENDEPIN1_A {
212        match self.bits {
213            false => ENDEPIN1_A::DISABLED,
214            true => ENDEPIN1_A::ENABLED,
215        }
216    }
217    #[doc = "Checks if the value of the field is `DISABLED`"]
218    #[inline(always)]
219    pub fn is_disabled(&self) -> bool {
220        *self == ENDEPIN1_A::DISABLED
221    }
222    #[doc = "Checks if the value of the field is `ENABLED`"]
223    #[inline(always)]
224    pub fn is_enabled(&self) -> bool {
225        *self == ENDEPIN1_A::ENABLED
226    }
227}
228#[doc = "Field `ENDEPIN1` writer - Enable or disable interrupt for ENDEPIN\\[1\\]
229event"]
230pub type ENDEPIN1_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN1_A, O>;
231impl<'a, const O: u8> ENDEPIN1_W<'a, O> {
232    #[doc = "Disable"]
233    #[inline(always)]
234    pub fn disabled(self) -> &'a mut W {
235        self.variant(ENDEPIN1_A::DISABLED)
236    }
237    #[doc = "Enable"]
238    #[inline(always)]
239    pub fn enabled(self) -> &'a mut W {
240        self.variant(ENDEPIN1_A::ENABLED)
241    }
242}
243#[doc = "Field `ENDEPIN2` reader - Enable or disable interrupt for ENDEPIN\\[2\\]
244event"]
245pub type ENDEPIN2_R = crate::BitReader<ENDEPIN2_A>;
246#[doc = "Enable or disable interrupt for ENDEPIN\\[2\\]
247event\n\nValue on reset: 0"]
248#[derive(Clone, Copy, Debug, PartialEq)]
249pub enum ENDEPIN2_A {
250    #[doc = "0: Disable"]
251    DISABLED = 0,
252    #[doc = "1: Enable"]
253    ENABLED = 1,
254}
255impl From<ENDEPIN2_A> for bool {
256    #[inline(always)]
257    fn from(variant: ENDEPIN2_A) -> Self {
258        variant as u8 != 0
259    }
260}
261impl ENDEPIN2_R {
262    #[doc = "Get enumerated values variant"]
263    #[inline(always)]
264    pub fn variant(&self) -> ENDEPIN2_A {
265        match self.bits {
266            false => ENDEPIN2_A::DISABLED,
267            true => ENDEPIN2_A::ENABLED,
268        }
269    }
270    #[doc = "Checks if the value of the field is `DISABLED`"]
271    #[inline(always)]
272    pub fn is_disabled(&self) -> bool {
273        *self == ENDEPIN2_A::DISABLED
274    }
275    #[doc = "Checks if the value of the field is `ENABLED`"]
276    #[inline(always)]
277    pub fn is_enabled(&self) -> bool {
278        *self == ENDEPIN2_A::ENABLED
279    }
280}
281#[doc = "Field `ENDEPIN2` writer - Enable or disable interrupt for ENDEPIN\\[2\\]
282event"]
283pub type ENDEPIN2_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN2_A, O>;
284impl<'a, const O: u8> ENDEPIN2_W<'a, O> {
285    #[doc = "Disable"]
286    #[inline(always)]
287    pub fn disabled(self) -> &'a mut W {
288        self.variant(ENDEPIN2_A::DISABLED)
289    }
290    #[doc = "Enable"]
291    #[inline(always)]
292    pub fn enabled(self) -> &'a mut W {
293        self.variant(ENDEPIN2_A::ENABLED)
294    }
295}
296#[doc = "Field `ENDEPIN3` reader - Enable or disable interrupt for ENDEPIN\\[3\\]
297event"]
298pub type ENDEPIN3_R = crate::BitReader<ENDEPIN3_A>;
299#[doc = "Enable or disable interrupt for ENDEPIN\\[3\\]
300event\n\nValue on reset: 0"]
301#[derive(Clone, Copy, Debug, PartialEq)]
302pub enum ENDEPIN3_A {
303    #[doc = "0: Disable"]
304    DISABLED = 0,
305    #[doc = "1: Enable"]
306    ENABLED = 1,
307}
308impl From<ENDEPIN3_A> for bool {
309    #[inline(always)]
310    fn from(variant: ENDEPIN3_A) -> Self {
311        variant as u8 != 0
312    }
313}
314impl ENDEPIN3_R {
315    #[doc = "Get enumerated values variant"]
316    #[inline(always)]
317    pub fn variant(&self) -> ENDEPIN3_A {
318        match self.bits {
319            false => ENDEPIN3_A::DISABLED,
320            true => ENDEPIN3_A::ENABLED,
321        }
322    }
323    #[doc = "Checks if the value of the field is `DISABLED`"]
324    #[inline(always)]
325    pub fn is_disabled(&self) -> bool {
326        *self == ENDEPIN3_A::DISABLED
327    }
328    #[doc = "Checks if the value of the field is `ENABLED`"]
329    #[inline(always)]
330    pub fn is_enabled(&self) -> bool {
331        *self == ENDEPIN3_A::ENABLED
332    }
333}
334#[doc = "Field `ENDEPIN3` writer - Enable or disable interrupt for ENDEPIN\\[3\\]
335event"]
336pub type ENDEPIN3_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN3_A, O>;
337impl<'a, const O: u8> ENDEPIN3_W<'a, O> {
338    #[doc = "Disable"]
339    #[inline(always)]
340    pub fn disabled(self) -> &'a mut W {
341        self.variant(ENDEPIN3_A::DISABLED)
342    }
343    #[doc = "Enable"]
344    #[inline(always)]
345    pub fn enabled(self) -> &'a mut W {
346        self.variant(ENDEPIN3_A::ENABLED)
347    }
348}
349#[doc = "Field `ENDEPIN4` reader - Enable or disable interrupt for ENDEPIN\\[4\\]
350event"]
351pub type ENDEPIN4_R = crate::BitReader<ENDEPIN4_A>;
352#[doc = "Enable or disable interrupt for ENDEPIN\\[4\\]
353event\n\nValue on reset: 0"]
354#[derive(Clone, Copy, Debug, PartialEq)]
355pub enum ENDEPIN4_A {
356    #[doc = "0: Disable"]
357    DISABLED = 0,
358    #[doc = "1: Enable"]
359    ENABLED = 1,
360}
361impl From<ENDEPIN4_A> for bool {
362    #[inline(always)]
363    fn from(variant: ENDEPIN4_A) -> Self {
364        variant as u8 != 0
365    }
366}
367impl ENDEPIN4_R {
368    #[doc = "Get enumerated values variant"]
369    #[inline(always)]
370    pub fn variant(&self) -> ENDEPIN4_A {
371        match self.bits {
372            false => ENDEPIN4_A::DISABLED,
373            true => ENDEPIN4_A::ENABLED,
374        }
375    }
376    #[doc = "Checks if the value of the field is `DISABLED`"]
377    #[inline(always)]
378    pub fn is_disabled(&self) -> bool {
379        *self == ENDEPIN4_A::DISABLED
380    }
381    #[doc = "Checks if the value of the field is `ENABLED`"]
382    #[inline(always)]
383    pub fn is_enabled(&self) -> bool {
384        *self == ENDEPIN4_A::ENABLED
385    }
386}
387#[doc = "Field `ENDEPIN4` writer - Enable or disable interrupt for ENDEPIN\\[4\\]
388event"]
389pub type ENDEPIN4_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN4_A, O>;
390impl<'a, const O: u8> ENDEPIN4_W<'a, O> {
391    #[doc = "Disable"]
392    #[inline(always)]
393    pub fn disabled(self) -> &'a mut W {
394        self.variant(ENDEPIN4_A::DISABLED)
395    }
396    #[doc = "Enable"]
397    #[inline(always)]
398    pub fn enabled(self) -> &'a mut W {
399        self.variant(ENDEPIN4_A::ENABLED)
400    }
401}
402#[doc = "Field `ENDEPIN5` reader - Enable or disable interrupt for ENDEPIN\\[5\\]
403event"]
404pub type ENDEPIN5_R = crate::BitReader<ENDEPIN5_A>;
405#[doc = "Enable or disable interrupt for ENDEPIN\\[5\\]
406event\n\nValue on reset: 0"]
407#[derive(Clone, Copy, Debug, PartialEq)]
408pub enum ENDEPIN5_A {
409    #[doc = "0: Disable"]
410    DISABLED = 0,
411    #[doc = "1: Enable"]
412    ENABLED = 1,
413}
414impl From<ENDEPIN5_A> for bool {
415    #[inline(always)]
416    fn from(variant: ENDEPIN5_A) -> Self {
417        variant as u8 != 0
418    }
419}
420impl ENDEPIN5_R {
421    #[doc = "Get enumerated values variant"]
422    #[inline(always)]
423    pub fn variant(&self) -> ENDEPIN5_A {
424        match self.bits {
425            false => ENDEPIN5_A::DISABLED,
426            true => ENDEPIN5_A::ENABLED,
427        }
428    }
429    #[doc = "Checks if the value of the field is `DISABLED`"]
430    #[inline(always)]
431    pub fn is_disabled(&self) -> bool {
432        *self == ENDEPIN5_A::DISABLED
433    }
434    #[doc = "Checks if the value of the field is `ENABLED`"]
435    #[inline(always)]
436    pub fn is_enabled(&self) -> bool {
437        *self == ENDEPIN5_A::ENABLED
438    }
439}
440#[doc = "Field `ENDEPIN5` writer - Enable or disable interrupt for ENDEPIN\\[5\\]
441event"]
442pub type ENDEPIN5_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN5_A, O>;
443impl<'a, const O: u8> ENDEPIN5_W<'a, O> {
444    #[doc = "Disable"]
445    #[inline(always)]
446    pub fn disabled(self) -> &'a mut W {
447        self.variant(ENDEPIN5_A::DISABLED)
448    }
449    #[doc = "Enable"]
450    #[inline(always)]
451    pub fn enabled(self) -> &'a mut W {
452        self.variant(ENDEPIN5_A::ENABLED)
453    }
454}
455#[doc = "Field `ENDEPIN6` reader - Enable or disable interrupt for ENDEPIN\\[6\\]
456event"]
457pub type ENDEPIN6_R = crate::BitReader<ENDEPIN6_A>;
458#[doc = "Enable or disable interrupt for ENDEPIN\\[6\\]
459event\n\nValue on reset: 0"]
460#[derive(Clone, Copy, Debug, PartialEq)]
461pub enum ENDEPIN6_A {
462    #[doc = "0: Disable"]
463    DISABLED = 0,
464    #[doc = "1: Enable"]
465    ENABLED = 1,
466}
467impl From<ENDEPIN6_A> for bool {
468    #[inline(always)]
469    fn from(variant: ENDEPIN6_A) -> Self {
470        variant as u8 != 0
471    }
472}
473impl ENDEPIN6_R {
474    #[doc = "Get enumerated values variant"]
475    #[inline(always)]
476    pub fn variant(&self) -> ENDEPIN6_A {
477        match self.bits {
478            false => ENDEPIN6_A::DISABLED,
479            true => ENDEPIN6_A::ENABLED,
480        }
481    }
482    #[doc = "Checks if the value of the field is `DISABLED`"]
483    #[inline(always)]
484    pub fn is_disabled(&self) -> bool {
485        *self == ENDEPIN6_A::DISABLED
486    }
487    #[doc = "Checks if the value of the field is `ENABLED`"]
488    #[inline(always)]
489    pub fn is_enabled(&self) -> bool {
490        *self == ENDEPIN6_A::ENABLED
491    }
492}
493#[doc = "Field `ENDEPIN6` writer - Enable or disable interrupt for ENDEPIN\\[6\\]
494event"]
495pub type ENDEPIN6_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN6_A, O>;
496impl<'a, const O: u8> ENDEPIN6_W<'a, O> {
497    #[doc = "Disable"]
498    #[inline(always)]
499    pub fn disabled(self) -> &'a mut W {
500        self.variant(ENDEPIN6_A::DISABLED)
501    }
502    #[doc = "Enable"]
503    #[inline(always)]
504    pub fn enabled(self) -> &'a mut W {
505        self.variant(ENDEPIN6_A::ENABLED)
506    }
507}
508#[doc = "Field `ENDEPIN7` reader - Enable or disable interrupt for ENDEPIN\\[7\\]
509event"]
510pub type ENDEPIN7_R = crate::BitReader<ENDEPIN7_A>;
511#[doc = "Enable or disable interrupt for ENDEPIN\\[7\\]
512event\n\nValue on reset: 0"]
513#[derive(Clone, Copy, Debug, PartialEq)]
514pub enum ENDEPIN7_A {
515    #[doc = "0: Disable"]
516    DISABLED = 0,
517    #[doc = "1: Enable"]
518    ENABLED = 1,
519}
520impl From<ENDEPIN7_A> for bool {
521    #[inline(always)]
522    fn from(variant: ENDEPIN7_A) -> Self {
523        variant as u8 != 0
524    }
525}
526impl ENDEPIN7_R {
527    #[doc = "Get enumerated values variant"]
528    #[inline(always)]
529    pub fn variant(&self) -> ENDEPIN7_A {
530        match self.bits {
531            false => ENDEPIN7_A::DISABLED,
532            true => ENDEPIN7_A::ENABLED,
533        }
534    }
535    #[doc = "Checks if the value of the field is `DISABLED`"]
536    #[inline(always)]
537    pub fn is_disabled(&self) -> bool {
538        *self == ENDEPIN7_A::DISABLED
539    }
540    #[doc = "Checks if the value of the field is `ENABLED`"]
541    #[inline(always)]
542    pub fn is_enabled(&self) -> bool {
543        *self == ENDEPIN7_A::ENABLED
544    }
545}
546#[doc = "Field `ENDEPIN7` writer - Enable or disable interrupt for ENDEPIN\\[7\\]
547event"]
548pub type ENDEPIN7_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPIN7_A, O>;
549impl<'a, const O: u8> ENDEPIN7_W<'a, O> {
550    #[doc = "Disable"]
551    #[inline(always)]
552    pub fn disabled(self) -> &'a mut W {
553        self.variant(ENDEPIN7_A::DISABLED)
554    }
555    #[doc = "Enable"]
556    #[inline(always)]
557    pub fn enabled(self) -> &'a mut W {
558        self.variant(ENDEPIN7_A::ENABLED)
559    }
560}
561#[doc = "Field `EP0DATADONE` reader - Enable or disable interrupt for EP0DATADONE event"]
562pub type EP0DATADONE_R = crate::BitReader<EP0DATADONE_A>;
563#[doc = "Enable or disable interrupt for EP0DATADONE event\n\nValue on reset: 0"]
564#[derive(Clone, Copy, Debug, PartialEq)]
565pub enum EP0DATADONE_A {
566    #[doc = "0: Disable"]
567    DISABLED = 0,
568    #[doc = "1: Enable"]
569    ENABLED = 1,
570}
571impl From<EP0DATADONE_A> for bool {
572    #[inline(always)]
573    fn from(variant: EP0DATADONE_A) -> Self {
574        variant as u8 != 0
575    }
576}
577impl EP0DATADONE_R {
578    #[doc = "Get enumerated values variant"]
579    #[inline(always)]
580    pub fn variant(&self) -> EP0DATADONE_A {
581        match self.bits {
582            false => EP0DATADONE_A::DISABLED,
583            true => EP0DATADONE_A::ENABLED,
584        }
585    }
586    #[doc = "Checks if the value of the field is `DISABLED`"]
587    #[inline(always)]
588    pub fn is_disabled(&self) -> bool {
589        *self == EP0DATADONE_A::DISABLED
590    }
591    #[doc = "Checks if the value of the field is `ENABLED`"]
592    #[inline(always)]
593    pub fn is_enabled(&self) -> bool {
594        *self == EP0DATADONE_A::ENABLED
595    }
596}
597#[doc = "Field `EP0DATADONE` writer - Enable or disable interrupt for EP0DATADONE event"]
598pub type EP0DATADONE_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, EP0DATADONE_A, O>;
599impl<'a, const O: u8> EP0DATADONE_W<'a, O> {
600    #[doc = "Disable"]
601    #[inline(always)]
602    pub fn disabled(self) -> &'a mut W {
603        self.variant(EP0DATADONE_A::DISABLED)
604    }
605    #[doc = "Enable"]
606    #[inline(always)]
607    pub fn enabled(self) -> &'a mut W {
608        self.variant(EP0DATADONE_A::ENABLED)
609    }
610}
611#[doc = "Field `ENDISOIN` reader - Enable or disable interrupt for ENDISOIN event"]
612pub type ENDISOIN_R = crate::BitReader<ENDISOIN_A>;
613#[doc = "Enable or disable interrupt for ENDISOIN event\n\nValue on reset: 0"]
614#[derive(Clone, Copy, Debug, PartialEq)]
615pub enum ENDISOIN_A {
616    #[doc = "0: Disable"]
617    DISABLED = 0,
618    #[doc = "1: Enable"]
619    ENABLED = 1,
620}
621impl From<ENDISOIN_A> for bool {
622    #[inline(always)]
623    fn from(variant: ENDISOIN_A) -> Self {
624        variant as u8 != 0
625    }
626}
627impl ENDISOIN_R {
628    #[doc = "Get enumerated values variant"]
629    #[inline(always)]
630    pub fn variant(&self) -> ENDISOIN_A {
631        match self.bits {
632            false => ENDISOIN_A::DISABLED,
633            true => ENDISOIN_A::ENABLED,
634        }
635    }
636    #[doc = "Checks if the value of the field is `DISABLED`"]
637    #[inline(always)]
638    pub fn is_disabled(&self) -> bool {
639        *self == ENDISOIN_A::DISABLED
640    }
641    #[doc = "Checks if the value of the field is `ENABLED`"]
642    #[inline(always)]
643    pub fn is_enabled(&self) -> bool {
644        *self == ENDISOIN_A::ENABLED
645    }
646}
647#[doc = "Field `ENDISOIN` writer - Enable or disable interrupt for ENDISOIN event"]
648pub type ENDISOIN_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDISOIN_A, O>;
649impl<'a, const O: u8> ENDISOIN_W<'a, O> {
650    #[doc = "Disable"]
651    #[inline(always)]
652    pub fn disabled(self) -> &'a mut W {
653        self.variant(ENDISOIN_A::DISABLED)
654    }
655    #[doc = "Enable"]
656    #[inline(always)]
657    pub fn enabled(self) -> &'a mut W {
658        self.variant(ENDISOIN_A::ENABLED)
659    }
660}
661#[doc = "Field `ENDEPOUT0` reader - Enable or disable interrupt for ENDEPOUT\\[0\\]
662event"]
663pub type ENDEPOUT0_R = crate::BitReader<ENDEPOUT0_A>;
664#[doc = "Enable or disable interrupt for ENDEPOUT\\[0\\]
665event\n\nValue on reset: 0"]
666#[derive(Clone, Copy, Debug, PartialEq)]
667pub enum ENDEPOUT0_A {
668    #[doc = "0: Disable"]
669    DISABLED = 0,
670    #[doc = "1: Enable"]
671    ENABLED = 1,
672}
673impl From<ENDEPOUT0_A> for bool {
674    #[inline(always)]
675    fn from(variant: ENDEPOUT0_A) -> Self {
676        variant as u8 != 0
677    }
678}
679impl ENDEPOUT0_R {
680    #[doc = "Get enumerated values variant"]
681    #[inline(always)]
682    pub fn variant(&self) -> ENDEPOUT0_A {
683        match self.bits {
684            false => ENDEPOUT0_A::DISABLED,
685            true => ENDEPOUT0_A::ENABLED,
686        }
687    }
688    #[doc = "Checks if the value of the field is `DISABLED`"]
689    #[inline(always)]
690    pub fn is_disabled(&self) -> bool {
691        *self == ENDEPOUT0_A::DISABLED
692    }
693    #[doc = "Checks if the value of the field is `ENABLED`"]
694    #[inline(always)]
695    pub fn is_enabled(&self) -> bool {
696        *self == ENDEPOUT0_A::ENABLED
697    }
698}
699#[doc = "Field `ENDEPOUT0` writer - Enable or disable interrupt for ENDEPOUT\\[0\\]
700event"]
701pub type ENDEPOUT0_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT0_A, O>;
702impl<'a, const O: u8> ENDEPOUT0_W<'a, O> {
703    #[doc = "Disable"]
704    #[inline(always)]
705    pub fn disabled(self) -> &'a mut W {
706        self.variant(ENDEPOUT0_A::DISABLED)
707    }
708    #[doc = "Enable"]
709    #[inline(always)]
710    pub fn enabled(self) -> &'a mut W {
711        self.variant(ENDEPOUT0_A::ENABLED)
712    }
713}
714#[doc = "Field `ENDEPOUT1` reader - Enable or disable interrupt for ENDEPOUT\\[1\\]
715event"]
716pub type ENDEPOUT1_R = crate::BitReader<ENDEPOUT1_A>;
717#[doc = "Enable or disable interrupt for ENDEPOUT\\[1\\]
718event\n\nValue on reset: 0"]
719#[derive(Clone, Copy, Debug, PartialEq)]
720pub enum ENDEPOUT1_A {
721    #[doc = "0: Disable"]
722    DISABLED = 0,
723    #[doc = "1: Enable"]
724    ENABLED = 1,
725}
726impl From<ENDEPOUT1_A> for bool {
727    #[inline(always)]
728    fn from(variant: ENDEPOUT1_A) -> Self {
729        variant as u8 != 0
730    }
731}
732impl ENDEPOUT1_R {
733    #[doc = "Get enumerated values variant"]
734    #[inline(always)]
735    pub fn variant(&self) -> ENDEPOUT1_A {
736        match self.bits {
737            false => ENDEPOUT1_A::DISABLED,
738            true => ENDEPOUT1_A::ENABLED,
739        }
740    }
741    #[doc = "Checks if the value of the field is `DISABLED`"]
742    #[inline(always)]
743    pub fn is_disabled(&self) -> bool {
744        *self == ENDEPOUT1_A::DISABLED
745    }
746    #[doc = "Checks if the value of the field is `ENABLED`"]
747    #[inline(always)]
748    pub fn is_enabled(&self) -> bool {
749        *self == ENDEPOUT1_A::ENABLED
750    }
751}
752#[doc = "Field `ENDEPOUT1` writer - Enable or disable interrupt for ENDEPOUT\\[1\\]
753event"]
754pub type ENDEPOUT1_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT1_A, O>;
755impl<'a, const O: u8> ENDEPOUT1_W<'a, O> {
756    #[doc = "Disable"]
757    #[inline(always)]
758    pub fn disabled(self) -> &'a mut W {
759        self.variant(ENDEPOUT1_A::DISABLED)
760    }
761    #[doc = "Enable"]
762    #[inline(always)]
763    pub fn enabled(self) -> &'a mut W {
764        self.variant(ENDEPOUT1_A::ENABLED)
765    }
766}
767#[doc = "Field `ENDEPOUT2` reader - Enable or disable interrupt for ENDEPOUT\\[2\\]
768event"]
769pub type ENDEPOUT2_R = crate::BitReader<ENDEPOUT2_A>;
770#[doc = "Enable or disable interrupt for ENDEPOUT\\[2\\]
771event\n\nValue on reset: 0"]
772#[derive(Clone, Copy, Debug, PartialEq)]
773pub enum ENDEPOUT2_A {
774    #[doc = "0: Disable"]
775    DISABLED = 0,
776    #[doc = "1: Enable"]
777    ENABLED = 1,
778}
779impl From<ENDEPOUT2_A> for bool {
780    #[inline(always)]
781    fn from(variant: ENDEPOUT2_A) -> Self {
782        variant as u8 != 0
783    }
784}
785impl ENDEPOUT2_R {
786    #[doc = "Get enumerated values variant"]
787    #[inline(always)]
788    pub fn variant(&self) -> ENDEPOUT2_A {
789        match self.bits {
790            false => ENDEPOUT2_A::DISABLED,
791            true => ENDEPOUT2_A::ENABLED,
792        }
793    }
794    #[doc = "Checks if the value of the field is `DISABLED`"]
795    #[inline(always)]
796    pub fn is_disabled(&self) -> bool {
797        *self == ENDEPOUT2_A::DISABLED
798    }
799    #[doc = "Checks if the value of the field is `ENABLED`"]
800    #[inline(always)]
801    pub fn is_enabled(&self) -> bool {
802        *self == ENDEPOUT2_A::ENABLED
803    }
804}
805#[doc = "Field `ENDEPOUT2` writer - Enable or disable interrupt for ENDEPOUT\\[2\\]
806event"]
807pub type ENDEPOUT2_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT2_A, O>;
808impl<'a, const O: u8> ENDEPOUT2_W<'a, O> {
809    #[doc = "Disable"]
810    #[inline(always)]
811    pub fn disabled(self) -> &'a mut W {
812        self.variant(ENDEPOUT2_A::DISABLED)
813    }
814    #[doc = "Enable"]
815    #[inline(always)]
816    pub fn enabled(self) -> &'a mut W {
817        self.variant(ENDEPOUT2_A::ENABLED)
818    }
819}
820#[doc = "Field `ENDEPOUT3` reader - Enable or disable interrupt for ENDEPOUT\\[3\\]
821event"]
822pub type ENDEPOUT3_R = crate::BitReader<ENDEPOUT3_A>;
823#[doc = "Enable or disable interrupt for ENDEPOUT\\[3\\]
824event\n\nValue on reset: 0"]
825#[derive(Clone, Copy, Debug, PartialEq)]
826pub enum ENDEPOUT3_A {
827    #[doc = "0: Disable"]
828    DISABLED = 0,
829    #[doc = "1: Enable"]
830    ENABLED = 1,
831}
832impl From<ENDEPOUT3_A> for bool {
833    #[inline(always)]
834    fn from(variant: ENDEPOUT3_A) -> Self {
835        variant as u8 != 0
836    }
837}
838impl ENDEPOUT3_R {
839    #[doc = "Get enumerated values variant"]
840    #[inline(always)]
841    pub fn variant(&self) -> ENDEPOUT3_A {
842        match self.bits {
843            false => ENDEPOUT3_A::DISABLED,
844            true => ENDEPOUT3_A::ENABLED,
845        }
846    }
847    #[doc = "Checks if the value of the field is `DISABLED`"]
848    #[inline(always)]
849    pub fn is_disabled(&self) -> bool {
850        *self == ENDEPOUT3_A::DISABLED
851    }
852    #[doc = "Checks if the value of the field is `ENABLED`"]
853    #[inline(always)]
854    pub fn is_enabled(&self) -> bool {
855        *self == ENDEPOUT3_A::ENABLED
856    }
857}
858#[doc = "Field `ENDEPOUT3` writer - Enable or disable interrupt for ENDEPOUT\\[3\\]
859event"]
860pub type ENDEPOUT3_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT3_A, O>;
861impl<'a, const O: u8> ENDEPOUT3_W<'a, O> {
862    #[doc = "Disable"]
863    #[inline(always)]
864    pub fn disabled(self) -> &'a mut W {
865        self.variant(ENDEPOUT3_A::DISABLED)
866    }
867    #[doc = "Enable"]
868    #[inline(always)]
869    pub fn enabled(self) -> &'a mut W {
870        self.variant(ENDEPOUT3_A::ENABLED)
871    }
872}
873#[doc = "Field `ENDEPOUT4` reader - Enable or disable interrupt for ENDEPOUT\\[4\\]
874event"]
875pub type ENDEPOUT4_R = crate::BitReader<ENDEPOUT4_A>;
876#[doc = "Enable or disable interrupt for ENDEPOUT\\[4\\]
877event\n\nValue on reset: 0"]
878#[derive(Clone, Copy, Debug, PartialEq)]
879pub enum ENDEPOUT4_A {
880    #[doc = "0: Disable"]
881    DISABLED = 0,
882    #[doc = "1: Enable"]
883    ENABLED = 1,
884}
885impl From<ENDEPOUT4_A> for bool {
886    #[inline(always)]
887    fn from(variant: ENDEPOUT4_A) -> Self {
888        variant as u8 != 0
889    }
890}
891impl ENDEPOUT4_R {
892    #[doc = "Get enumerated values variant"]
893    #[inline(always)]
894    pub fn variant(&self) -> ENDEPOUT4_A {
895        match self.bits {
896            false => ENDEPOUT4_A::DISABLED,
897            true => ENDEPOUT4_A::ENABLED,
898        }
899    }
900    #[doc = "Checks if the value of the field is `DISABLED`"]
901    #[inline(always)]
902    pub fn is_disabled(&self) -> bool {
903        *self == ENDEPOUT4_A::DISABLED
904    }
905    #[doc = "Checks if the value of the field is `ENABLED`"]
906    #[inline(always)]
907    pub fn is_enabled(&self) -> bool {
908        *self == ENDEPOUT4_A::ENABLED
909    }
910}
911#[doc = "Field `ENDEPOUT4` writer - Enable or disable interrupt for ENDEPOUT\\[4\\]
912event"]
913pub type ENDEPOUT4_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT4_A, O>;
914impl<'a, const O: u8> ENDEPOUT4_W<'a, O> {
915    #[doc = "Disable"]
916    #[inline(always)]
917    pub fn disabled(self) -> &'a mut W {
918        self.variant(ENDEPOUT4_A::DISABLED)
919    }
920    #[doc = "Enable"]
921    #[inline(always)]
922    pub fn enabled(self) -> &'a mut W {
923        self.variant(ENDEPOUT4_A::ENABLED)
924    }
925}
926#[doc = "Field `ENDEPOUT5` reader - Enable or disable interrupt for ENDEPOUT\\[5\\]
927event"]
928pub type ENDEPOUT5_R = crate::BitReader<ENDEPOUT5_A>;
929#[doc = "Enable or disable interrupt for ENDEPOUT\\[5\\]
930event\n\nValue on reset: 0"]
931#[derive(Clone, Copy, Debug, PartialEq)]
932pub enum ENDEPOUT5_A {
933    #[doc = "0: Disable"]
934    DISABLED = 0,
935    #[doc = "1: Enable"]
936    ENABLED = 1,
937}
938impl From<ENDEPOUT5_A> for bool {
939    #[inline(always)]
940    fn from(variant: ENDEPOUT5_A) -> Self {
941        variant as u8 != 0
942    }
943}
944impl ENDEPOUT5_R {
945    #[doc = "Get enumerated values variant"]
946    #[inline(always)]
947    pub fn variant(&self) -> ENDEPOUT5_A {
948        match self.bits {
949            false => ENDEPOUT5_A::DISABLED,
950            true => ENDEPOUT5_A::ENABLED,
951        }
952    }
953    #[doc = "Checks if the value of the field is `DISABLED`"]
954    #[inline(always)]
955    pub fn is_disabled(&self) -> bool {
956        *self == ENDEPOUT5_A::DISABLED
957    }
958    #[doc = "Checks if the value of the field is `ENABLED`"]
959    #[inline(always)]
960    pub fn is_enabled(&self) -> bool {
961        *self == ENDEPOUT5_A::ENABLED
962    }
963}
964#[doc = "Field `ENDEPOUT5` writer - Enable or disable interrupt for ENDEPOUT\\[5\\]
965event"]
966pub type ENDEPOUT5_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT5_A, O>;
967impl<'a, const O: u8> ENDEPOUT5_W<'a, O> {
968    #[doc = "Disable"]
969    #[inline(always)]
970    pub fn disabled(self) -> &'a mut W {
971        self.variant(ENDEPOUT5_A::DISABLED)
972    }
973    #[doc = "Enable"]
974    #[inline(always)]
975    pub fn enabled(self) -> &'a mut W {
976        self.variant(ENDEPOUT5_A::ENABLED)
977    }
978}
979#[doc = "Field `ENDEPOUT6` reader - Enable or disable interrupt for ENDEPOUT\\[6\\]
980event"]
981pub type ENDEPOUT6_R = crate::BitReader<ENDEPOUT6_A>;
982#[doc = "Enable or disable interrupt for ENDEPOUT\\[6\\]
983event\n\nValue on reset: 0"]
984#[derive(Clone, Copy, Debug, PartialEq)]
985pub enum ENDEPOUT6_A {
986    #[doc = "0: Disable"]
987    DISABLED = 0,
988    #[doc = "1: Enable"]
989    ENABLED = 1,
990}
991impl From<ENDEPOUT6_A> for bool {
992    #[inline(always)]
993    fn from(variant: ENDEPOUT6_A) -> Self {
994        variant as u8 != 0
995    }
996}
997impl ENDEPOUT6_R {
998    #[doc = "Get enumerated values variant"]
999    #[inline(always)]
1000    pub fn variant(&self) -> ENDEPOUT6_A {
1001        match self.bits {
1002            false => ENDEPOUT6_A::DISABLED,
1003            true => ENDEPOUT6_A::ENABLED,
1004        }
1005    }
1006    #[doc = "Checks if the value of the field is `DISABLED`"]
1007    #[inline(always)]
1008    pub fn is_disabled(&self) -> bool {
1009        *self == ENDEPOUT6_A::DISABLED
1010    }
1011    #[doc = "Checks if the value of the field is `ENABLED`"]
1012    #[inline(always)]
1013    pub fn is_enabled(&self) -> bool {
1014        *self == ENDEPOUT6_A::ENABLED
1015    }
1016}
1017#[doc = "Field `ENDEPOUT6` writer - Enable or disable interrupt for ENDEPOUT\\[6\\]
1018event"]
1019pub type ENDEPOUT6_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT6_A, O>;
1020impl<'a, const O: u8> ENDEPOUT6_W<'a, O> {
1021    #[doc = "Disable"]
1022    #[inline(always)]
1023    pub fn disabled(self) -> &'a mut W {
1024        self.variant(ENDEPOUT6_A::DISABLED)
1025    }
1026    #[doc = "Enable"]
1027    #[inline(always)]
1028    pub fn enabled(self) -> &'a mut W {
1029        self.variant(ENDEPOUT6_A::ENABLED)
1030    }
1031}
1032#[doc = "Field `ENDEPOUT7` reader - Enable or disable interrupt for ENDEPOUT\\[7\\]
1033event"]
1034pub type ENDEPOUT7_R = crate::BitReader<ENDEPOUT7_A>;
1035#[doc = "Enable or disable interrupt for ENDEPOUT\\[7\\]
1036event\n\nValue on reset: 0"]
1037#[derive(Clone, Copy, Debug, PartialEq)]
1038pub enum ENDEPOUT7_A {
1039    #[doc = "0: Disable"]
1040    DISABLED = 0,
1041    #[doc = "1: Enable"]
1042    ENABLED = 1,
1043}
1044impl From<ENDEPOUT7_A> for bool {
1045    #[inline(always)]
1046    fn from(variant: ENDEPOUT7_A) -> Self {
1047        variant as u8 != 0
1048    }
1049}
1050impl ENDEPOUT7_R {
1051    #[doc = "Get enumerated values variant"]
1052    #[inline(always)]
1053    pub fn variant(&self) -> ENDEPOUT7_A {
1054        match self.bits {
1055            false => ENDEPOUT7_A::DISABLED,
1056            true => ENDEPOUT7_A::ENABLED,
1057        }
1058    }
1059    #[doc = "Checks if the value of the field is `DISABLED`"]
1060    #[inline(always)]
1061    pub fn is_disabled(&self) -> bool {
1062        *self == ENDEPOUT7_A::DISABLED
1063    }
1064    #[doc = "Checks if the value of the field is `ENABLED`"]
1065    #[inline(always)]
1066    pub fn is_enabled(&self) -> bool {
1067        *self == ENDEPOUT7_A::ENABLED
1068    }
1069}
1070#[doc = "Field `ENDEPOUT7` writer - Enable or disable interrupt for ENDEPOUT\\[7\\]
1071event"]
1072pub type ENDEPOUT7_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDEPOUT7_A, O>;
1073impl<'a, const O: u8> ENDEPOUT7_W<'a, O> {
1074    #[doc = "Disable"]
1075    #[inline(always)]
1076    pub fn disabled(self) -> &'a mut W {
1077        self.variant(ENDEPOUT7_A::DISABLED)
1078    }
1079    #[doc = "Enable"]
1080    #[inline(always)]
1081    pub fn enabled(self) -> &'a mut W {
1082        self.variant(ENDEPOUT7_A::ENABLED)
1083    }
1084}
1085#[doc = "Field `ENDISOOUT` reader - Enable or disable interrupt for ENDISOOUT event"]
1086pub type ENDISOOUT_R = crate::BitReader<ENDISOOUT_A>;
1087#[doc = "Enable or disable interrupt for ENDISOOUT event\n\nValue on reset: 0"]
1088#[derive(Clone, Copy, Debug, PartialEq)]
1089pub enum ENDISOOUT_A {
1090    #[doc = "0: Disable"]
1091    DISABLED = 0,
1092    #[doc = "1: Enable"]
1093    ENABLED = 1,
1094}
1095impl From<ENDISOOUT_A> for bool {
1096    #[inline(always)]
1097    fn from(variant: ENDISOOUT_A) -> Self {
1098        variant as u8 != 0
1099    }
1100}
1101impl ENDISOOUT_R {
1102    #[doc = "Get enumerated values variant"]
1103    #[inline(always)]
1104    pub fn variant(&self) -> ENDISOOUT_A {
1105        match self.bits {
1106            false => ENDISOOUT_A::DISABLED,
1107            true => ENDISOOUT_A::ENABLED,
1108        }
1109    }
1110    #[doc = "Checks if the value of the field is `DISABLED`"]
1111    #[inline(always)]
1112    pub fn is_disabled(&self) -> bool {
1113        *self == ENDISOOUT_A::DISABLED
1114    }
1115    #[doc = "Checks if the value of the field is `ENABLED`"]
1116    #[inline(always)]
1117    pub fn is_enabled(&self) -> bool {
1118        *self == ENDISOOUT_A::ENABLED
1119    }
1120}
1121#[doc = "Field `ENDISOOUT` writer - Enable or disable interrupt for ENDISOOUT event"]
1122pub type ENDISOOUT_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, ENDISOOUT_A, O>;
1123impl<'a, const O: u8> ENDISOOUT_W<'a, O> {
1124    #[doc = "Disable"]
1125    #[inline(always)]
1126    pub fn disabled(self) -> &'a mut W {
1127        self.variant(ENDISOOUT_A::DISABLED)
1128    }
1129    #[doc = "Enable"]
1130    #[inline(always)]
1131    pub fn enabled(self) -> &'a mut W {
1132        self.variant(ENDISOOUT_A::ENABLED)
1133    }
1134}
1135#[doc = "Field `SOF` reader - Enable or disable interrupt for SOF event"]
1136pub type SOF_R = crate::BitReader<SOF_A>;
1137#[doc = "Enable or disable interrupt for SOF event\n\nValue on reset: 0"]
1138#[derive(Clone, Copy, Debug, PartialEq)]
1139pub enum SOF_A {
1140    #[doc = "0: Disable"]
1141    DISABLED = 0,
1142    #[doc = "1: Enable"]
1143    ENABLED = 1,
1144}
1145impl From<SOF_A> for bool {
1146    #[inline(always)]
1147    fn from(variant: SOF_A) -> Self {
1148        variant as u8 != 0
1149    }
1150}
1151impl SOF_R {
1152    #[doc = "Get enumerated values variant"]
1153    #[inline(always)]
1154    pub fn variant(&self) -> SOF_A {
1155        match self.bits {
1156            false => SOF_A::DISABLED,
1157            true => SOF_A::ENABLED,
1158        }
1159    }
1160    #[doc = "Checks if the value of the field is `DISABLED`"]
1161    #[inline(always)]
1162    pub fn is_disabled(&self) -> bool {
1163        *self == SOF_A::DISABLED
1164    }
1165    #[doc = "Checks if the value of the field is `ENABLED`"]
1166    #[inline(always)]
1167    pub fn is_enabled(&self) -> bool {
1168        *self == SOF_A::ENABLED
1169    }
1170}
1171#[doc = "Field `SOF` writer - Enable or disable interrupt for SOF event"]
1172pub type SOF_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, SOF_A, O>;
1173impl<'a, const O: u8> SOF_W<'a, O> {
1174    #[doc = "Disable"]
1175    #[inline(always)]
1176    pub fn disabled(self) -> &'a mut W {
1177        self.variant(SOF_A::DISABLED)
1178    }
1179    #[doc = "Enable"]
1180    #[inline(always)]
1181    pub fn enabled(self) -> &'a mut W {
1182        self.variant(SOF_A::ENABLED)
1183    }
1184}
1185#[doc = "Field `USBEVENT` reader - Enable or disable interrupt for USBEVENT event"]
1186pub type USBEVENT_R = crate::BitReader<USBEVENT_A>;
1187#[doc = "Enable or disable interrupt for USBEVENT event\n\nValue on reset: 0"]
1188#[derive(Clone, Copy, Debug, PartialEq)]
1189pub enum USBEVENT_A {
1190    #[doc = "0: Disable"]
1191    DISABLED = 0,
1192    #[doc = "1: Enable"]
1193    ENABLED = 1,
1194}
1195impl From<USBEVENT_A> for bool {
1196    #[inline(always)]
1197    fn from(variant: USBEVENT_A) -> Self {
1198        variant as u8 != 0
1199    }
1200}
1201impl USBEVENT_R {
1202    #[doc = "Get enumerated values variant"]
1203    #[inline(always)]
1204    pub fn variant(&self) -> USBEVENT_A {
1205        match self.bits {
1206            false => USBEVENT_A::DISABLED,
1207            true => USBEVENT_A::ENABLED,
1208        }
1209    }
1210    #[doc = "Checks if the value of the field is `DISABLED`"]
1211    #[inline(always)]
1212    pub fn is_disabled(&self) -> bool {
1213        *self == USBEVENT_A::DISABLED
1214    }
1215    #[doc = "Checks if the value of the field is `ENABLED`"]
1216    #[inline(always)]
1217    pub fn is_enabled(&self) -> bool {
1218        *self == USBEVENT_A::ENABLED
1219    }
1220}
1221#[doc = "Field `USBEVENT` writer - Enable or disable interrupt for USBEVENT event"]
1222pub type USBEVENT_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, USBEVENT_A, O>;
1223impl<'a, const O: u8> USBEVENT_W<'a, O> {
1224    #[doc = "Disable"]
1225    #[inline(always)]
1226    pub fn disabled(self) -> &'a mut W {
1227        self.variant(USBEVENT_A::DISABLED)
1228    }
1229    #[doc = "Enable"]
1230    #[inline(always)]
1231    pub fn enabled(self) -> &'a mut W {
1232        self.variant(USBEVENT_A::ENABLED)
1233    }
1234}
1235#[doc = "Field `EP0SETUP` reader - Enable or disable interrupt for EP0SETUP event"]
1236pub type EP0SETUP_R = crate::BitReader<EP0SETUP_A>;
1237#[doc = "Enable or disable interrupt for EP0SETUP event\n\nValue on reset: 0"]
1238#[derive(Clone, Copy, Debug, PartialEq)]
1239pub enum EP0SETUP_A {
1240    #[doc = "0: Disable"]
1241    DISABLED = 0,
1242    #[doc = "1: Enable"]
1243    ENABLED = 1,
1244}
1245impl From<EP0SETUP_A> for bool {
1246    #[inline(always)]
1247    fn from(variant: EP0SETUP_A) -> Self {
1248        variant as u8 != 0
1249    }
1250}
1251impl EP0SETUP_R {
1252    #[doc = "Get enumerated values variant"]
1253    #[inline(always)]
1254    pub fn variant(&self) -> EP0SETUP_A {
1255        match self.bits {
1256            false => EP0SETUP_A::DISABLED,
1257            true => EP0SETUP_A::ENABLED,
1258        }
1259    }
1260    #[doc = "Checks if the value of the field is `DISABLED`"]
1261    #[inline(always)]
1262    pub fn is_disabled(&self) -> bool {
1263        *self == EP0SETUP_A::DISABLED
1264    }
1265    #[doc = "Checks if the value of the field is `ENABLED`"]
1266    #[inline(always)]
1267    pub fn is_enabled(&self) -> bool {
1268        *self == EP0SETUP_A::ENABLED
1269    }
1270}
1271#[doc = "Field `EP0SETUP` writer - Enable or disable interrupt for EP0SETUP event"]
1272pub type EP0SETUP_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, EP0SETUP_A, O>;
1273impl<'a, const O: u8> EP0SETUP_W<'a, O> {
1274    #[doc = "Disable"]
1275    #[inline(always)]
1276    pub fn disabled(self) -> &'a mut W {
1277        self.variant(EP0SETUP_A::DISABLED)
1278    }
1279    #[doc = "Enable"]
1280    #[inline(always)]
1281    pub fn enabled(self) -> &'a mut W {
1282        self.variant(EP0SETUP_A::ENABLED)
1283    }
1284}
1285#[doc = "Field `EPDATA` reader - Enable or disable interrupt for EPDATA event"]
1286pub type EPDATA_R = crate::BitReader<EPDATA_A>;
1287#[doc = "Enable or disable interrupt for EPDATA event\n\nValue on reset: 0"]
1288#[derive(Clone, Copy, Debug, PartialEq)]
1289pub enum EPDATA_A {
1290    #[doc = "0: Disable"]
1291    DISABLED = 0,
1292    #[doc = "1: Enable"]
1293    ENABLED = 1,
1294}
1295impl From<EPDATA_A> for bool {
1296    #[inline(always)]
1297    fn from(variant: EPDATA_A) -> Self {
1298        variant as u8 != 0
1299    }
1300}
1301impl EPDATA_R {
1302    #[doc = "Get enumerated values variant"]
1303    #[inline(always)]
1304    pub fn variant(&self) -> EPDATA_A {
1305        match self.bits {
1306            false => EPDATA_A::DISABLED,
1307            true => EPDATA_A::ENABLED,
1308        }
1309    }
1310    #[doc = "Checks if the value of the field is `DISABLED`"]
1311    #[inline(always)]
1312    pub fn is_disabled(&self) -> bool {
1313        *self == EPDATA_A::DISABLED
1314    }
1315    #[doc = "Checks if the value of the field is `ENABLED`"]
1316    #[inline(always)]
1317    pub fn is_enabled(&self) -> bool {
1318        *self == EPDATA_A::ENABLED
1319    }
1320}
1321#[doc = "Field `EPDATA` writer - Enable or disable interrupt for EPDATA event"]
1322pub type EPDATA_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTEN_SPEC, EPDATA_A, O>;
1323impl<'a, const O: u8> EPDATA_W<'a, O> {
1324    #[doc = "Disable"]
1325    #[inline(always)]
1326    pub fn disabled(self) -> &'a mut W {
1327        self.variant(EPDATA_A::DISABLED)
1328    }
1329    #[doc = "Enable"]
1330    #[inline(always)]
1331    pub fn enabled(self) -> &'a mut W {
1332        self.variant(EPDATA_A::ENABLED)
1333    }
1334}
1335impl R {
1336    #[doc = "Bit 0 - Enable or disable interrupt for USBRESET event"]
1337    #[inline(always)]
1338    pub fn usbreset(&self) -> USBRESET_R {
1339        USBRESET_R::new((self.bits & 1) != 0)
1340    }
1341    #[doc = "Bit 1 - Enable or disable interrupt for STARTED event"]
1342    #[inline(always)]
1343    pub fn started(&self) -> STARTED_R {
1344        STARTED_R::new(((self.bits >> 1) & 1) != 0)
1345    }
1346    #[doc = "Bit 2 - Enable or disable interrupt for ENDEPIN\\[0\\]
1347event"]
1348    #[inline(always)]
1349    pub fn endepin0(&self) -> ENDEPIN0_R {
1350        ENDEPIN0_R::new(((self.bits >> 2) & 1) != 0)
1351    }
1352    #[doc = "Bit 3 - Enable or disable interrupt for ENDEPIN\\[1\\]
1353event"]
1354    #[inline(always)]
1355    pub fn endepin1(&self) -> ENDEPIN1_R {
1356        ENDEPIN1_R::new(((self.bits >> 3) & 1) != 0)
1357    }
1358    #[doc = "Bit 4 - Enable or disable interrupt for ENDEPIN\\[2\\]
1359event"]
1360    #[inline(always)]
1361    pub fn endepin2(&self) -> ENDEPIN2_R {
1362        ENDEPIN2_R::new(((self.bits >> 4) & 1) != 0)
1363    }
1364    #[doc = "Bit 5 - Enable or disable interrupt for ENDEPIN\\[3\\]
1365event"]
1366    #[inline(always)]
1367    pub fn endepin3(&self) -> ENDEPIN3_R {
1368        ENDEPIN3_R::new(((self.bits >> 5) & 1) != 0)
1369    }
1370    #[doc = "Bit 6 - Enable or disable interrupt for ENDEPIN\\[4\\]
1371event"]
1372    #[inline(always)]
1373    pub fn endepin4(&self) -> ENDEPIN4_R {
1374        ENDEPIN4_R::new(((self.bits >> 6) & 1) != 0)
1375    }
1376    #[doc = "Bit 7 - Enable or disable interrupt for ENDEPIN\\[5\\]
1377event"]
1378    #[inline(always)]
1379    pub fn endepin5(&self) -> ENDEPIN5_R {
1380        ENDEPIN5_R::new(((self.bits >> 7) & 1) != 0)
1381    }
1382    #[doc = "Bit 8 - Enable or disable interrupt for ENDEPIN\\[6\\]
1383event"]
1384    #[inline(always)]
1385    pub fn endepin6(&self) -> ENDEPIN6_R {
1386        ENDEPIN6_R::new(((self.bits >> 8) & 1) != 0)
1387    }
1388    #[doc = "Bit 9 - Enable or disable interrupt for ENDEPIN\\[7\\]
1389event"]
1390    #[inline(always)]
1391    pub fn endepin7(&self) -> ENDEPIN7_R {
1392        ENDEPIN7_R::new(((self.bits >> 9) & 1) != 0)
1393    }
1394    #[doc = "Bit 10 - Enable or disable interrupt for EP0DATADONE event"]
1395    #[inline(always)]
1396    pub fn ep0datadone(&self) -> EP0DATADONE_R {
1397        EP0DATADONE_R::new(((self.bits >> 10) & 1) != 0)
1398    }
1399    #[doc = "Bit 11 - Enable or disable interrupt for ENDISOIN event"]
1400    #[inline(always)]
1401    pub fn endisoin(&self) -> ENDISOIN_R {
1402        ENDISOIN_R::new(((self.bits >> 11) & 1) != 0)
1403    }
1404    #[doc = "Bit 12 - Enable or disable interrupt for ENDEPOUT\\[0\\]
1405event"]
1406    #[inline(always)]
1407    pub fn endepout0(&self) -> ENDEPOUT0_R {
1408        ENDEPOUT0_R::new(((self.bits >> 12) & 1) != 0)
1409    }
1410    #[doc = "Bit 13 - Enable or disable interrupt for ENDEPOUT\\[1\\]
1411event"]
1412    #[inline(always)]
1413    pub fn endepout1(&self) -> ENDEPOUT1_R {
1414        ENDEPOUT1_R::new(((self.bits >> 13) & 1) != 0)
1415    }
1416    #[doc = "Bit 14 - Enable or disable interrupt for ENDEPOUT\\[2\\]
1417event"]
1418    #[inline(always)]
1419    pub fn endepout2(&self) -> ENDEPOUT2_R {
1420        ENDEPOUT2_R::new(((self.bits >> 14) & 1) != 0)
1421    }
1422    #[doc = "Bit 15 - Enable or disable interrupt for ENDEPOUT\\[3\\]
1423event"]
1424    #[inline(always)]
1425    pub fn endepout3(&self) -> ENDEPOUT3_R {
1426        ENDEPOUT3_R::new(((self.bits >> 15) & 1) != 0)
1427    }
1428    #[doc = "Bit 16 - Enable or disable interrupt for ENDEPOUT\\[4\\]
1429event"]
1430    #[inline(always)]
1431    pub fn endepout4(&self) -> ENDEPOUT4_R {
1432        ENDEPOUT4_R::new(((self.bits >> 16) & 1) != 0)
1433    }
1434    #[doc = "Bit 17 - Enable or disable interrupt for ENDEPOUT\\[5\\]
1435event"]
1436    #[inline(always)]
1437    pub fn endepout5(&self) -> ENDEPOUT5_R {
1438        ENDEPOUT5_R::new(((self.bits >> 17) & 1) != 0)
1439    }
1440    #[doc = "Bit 18 - Enable or disable interrupt for ENDEPOUT\\[6\\]
1441event"]
1442    #[inline(always)]
1443    pub fn endepout6(&self) -> ENDEPOUT6_R {
1444        ENDEPOUT6_R::new(((self.bits >> 18) & 1) != 0)
1445    }
1446    #[doc = "Bit 19 - Enable or disable interrupt for ENDEPOUT\\[7\\]
1447event"]
1448    #[inline(always)]
1449    pub fn endepout7(&self) -> ENDEPOUT7_R {
1450        ENDEPOUT7_R::new(((self.bits >> 19) & 1) != 0)
1451    }
1452    #[doc = "Bit 20 - Enable or disable interrupt for ENDISOOUT event"]
1453    #[inline(always)]
1454    pub fn endisoout(&self) -> ENDISOOUT_R {
1455        ENDISOOUT_R::new(((self.bits >> 20) & 1) != 0)
1456    }
1457    #[doc = "Bit 21 - Enable or disable interrupt for SOF event"]
1458    #[inline(always)]
1459    pub fn sof(&self) -> SOF_R {
1460        SOF_R::new(((self.bits >> 21) & 1) != 0)
1461    }
1462    #[doc = "Bit 22 - Enable or disable interrupt for USBEVENT event"]
1463    #[inline(always)]
1464    pub fn usbevent(&self) -> USBEVENT_R {
1465        USBEVENT_R::new(((self.bits >> 22) & 1) != 0)
1466    }
1467    #[doc = "Bit 23 - Enable or disable interrupt for EP0SETUP event"]
1468    #[inline(always)]
1469    pub fn ep0setup(&self) -> EP0SETUP_R {
1470        EP0SETUP_R::new(((self.bits >> 23) & 1) != 0)
1471    }
1472    #[doc = "Bit 24 - Enable or disable interrupt for EPDATA event"]
1473    #[inline(always)]
1474    pub fn epdata(&self) -> EPDATA_R {
1475        EPDATA_R::new(((self.bits >> 24) & 1) != 0)
1476    }
1477}
1478impl W {
1479    #[doc = "Bit 0 - Enable or disable interrupt for USBRESET event"]
1480    #[inline(always)]
1481    pub fn usbreset(&mut self) -> USBRESET_W<0> {
1482        USBRESET_W::new(self)
1483    }
1484    #[doc = "Bit 1 - Enable or disable interrupt for STARTED event"]
1485    #[inline(always)]
1486    pub fn started(&mut self) -> STARTED_W<1> {
1487        STARTED_W::new(self)
1488    }
1489    #[doc = "Bit 2 - Enable or disable interrupt for ENDEPIN\\[0\\]
1490event"]
1491    #[inline(always)]
1492    pub fn endepin0(&mut self) -> ENDEPIN0_W<2> {
1493        ENDEPIN0_W::new(self)
1494    }
1495    #[doc = "Bit 3 - Enable or disable interrupt for ENDEPIN\\[1\\]
1496event"]
1497    #[inline(always)]
1498    pub fn endepin1(&mut self) -> ENDEPIN1_W<3> {
1499        ENDEPIN1_W::new(self)
1500    }
1501    #[doc = "Bit 4 - Enable or disable interrupt for ENDEPIN\\[2\\]
1502event"]
1503    #[inline(always)]
1504    pub fn endepin2(&mut self) -> ENDEPIN2_W<4> {
1505        ENDEPIN2_W::new(self)
1506    }
1507    #[doc = "Bit 5 - Enable or disable interrupt for ENDEPIN\\[3\\]
1508event"]
1509    #[inline(always)]
1510    pub fn endepin3(&mut self) -> ENDEPIN3_W<5> {
1511        ENDEPIN3_W::new(self)
1512    }
1513    #[doc = "Bit 6 - Enable or disable interrupt for ENDEPIN\\[4\\]
1514event"]
1515    #[inline(always)]
1516    pub fn endepin4(&mut self) -> ENDEPIN4_W<6> {
1517        ENDEPIN4_W::new(self)
1518    }
1519    #[doc = "Bit 7 - Enable or disable interrupt for ENDEPIN\\[5\\]
1520event"]
1521    #[inline(always)]
1522    pub fn endepin5(&mut self) -> ENDEPIN5_W<7> {
1523        ENDEPIN5_W::new(self)
1524    }
1525    #[doc = "Bit 8 - Enable or disable interrupt for ENDEPIN\\[6\\]
1526event"]
1527    #[inline(always)]
1528    pub fn endepin6(&mut self) -> ENDEPIN6_W<8> {
1529        ENDEPIN6_W::new(self)
1530    }
1531    #[doc = "Bit 9 - Enable or disable interrupt for ENDEPIN\\[7\\]
1532event"]
1533    #[inline(always)]
1534    pub fn endepin7(&mut self) -> ENDEPIN7_W<9> {
1535        ENDEPIN7_W::new(self)
1536    }
1537    #[doc = "Bit 10 - Enable or disable interrupt for EP0DATADONE event"]
1538    #[inline(always)]
1539    pub fn ep0datadone(&mut self) -> EP0DATADONE_W<10> {
1540        EP0DATADONE_W::new(self)
1541    }
1542    #[doc = "Bit 11 - Enable or disable interrupt for ENDISOIN event"]
1543    #[inline(always)]
1544    pub fn endisoin(&mut self) -> ENDISOIN_W<11> {
1545        ENDISOIN_W::new(self)
1546    }
1547    #[doc = "Bit 12 - Enable or disable interrupt for ENDEPOUT\\[0\\]
1548event"]
1549    #[inline(always)]
1550    pub fn endepout0(&mut self) -> ENDEPOUT0_W<12> {
1551        ENDEPOUT0_W::new(self)
1552    }
1553    #[doc = "Bit 13 - Enable or disable interrupt for ENDEPOUT\\[1\\]
1554event"]
1555    #[inline(always)]
1556    pub fn endepout1(&mut self) -> ENDEPOUT1_W<13> {
1557        ENDEPOUT1_W::new(self)
1558    }
1559    #[doc = "Bit 14 - Enable or disable interrupt for ENDEPOUT\\[2\\]
1560event"]
1561    #[inline(always)]
1562    pub fn endepout2(&mut self) -> ENDEPOUT2_W<14> {
1563        ENDEPOUT2_W::new(self)
1564    }
1565    #[doc = "Bit 15 - Enable or disable interrupt for ENDEPOUT\\[3\\]
1566event"]
1567    #[inline(always)]
1568    pub fn endepout3(&mut self) -> ENDEPOUT3_W<15> {
1569        ENDEPOUT3_W::new(self)
1570    }
1571    #[doc = "Bit 16 - Enable or disable interrupt for ENDEPOUT\\[4\\]
1572event"]
1573    #[inline(always)]
1574    pub fn endepout4(&mut self) -> ENDEPOUT4_W<16> {
1575        ENDEPOUT4_W::new(self)
1576    }
1577    #[doc = "Bit 17 - Enable or disable interrupt for ENDEPOUT\\[5\\]
1578event"]
1579    #[inline(always)]
1580    pub fn endepout5(&mut self) -> ENDEPOUT5_W<17> {
1581        ENDEPOUT5_W::new(self)
1582    }
1583    #[doc = "Bit 18 - Enable or disable interrupt for ENDEPOUT\\[6\\]
1584event"]
1585    #[inline(always)]
1586    pub fn endepout6(&mut self) -> ENDEPOUT6_W<18> {
1587        ENDEPOUT6_W::new(self)
1588    }
1589    #[doc = "Bit 19 - Enable or disable interrupt for ENDEPOUT\\[7\\]
1590event"]
1591    #[inline(always)]
1592    pub fn endepout7(&mut self) -> ENDEPOUT7_W<19> {
1593        ENDEPOUT7_W::new(self)
1594    }
1595    #[doc = "Bit 20 - Enable or disable interrupt for ENDISOOUT event"]
1596    #[inline(always)]
1597    pub fn endisoout(&mut self) -> ENDISOOUT_W<20> {
1598        ENDISOOUT_W::new(self)
1599    }
1600    #[doc = "Bit 21 - Enable or disable interrupt for SOF event"]
1601    #[inline(always)]
1602    pub fn sof(&mut self) -> SOF_W<21> {
1603        SOF_W::new(self)
1604    }
1605    #[doc = "Bit 22 - Enable or disable interrupt for USBEVENT event"]
1606    #[inline(always)]
1607    pub fn usbevent(&mut self) -> USBEVENT_W<22> {
1608        USBEVENT_W::new(self)
1609    }
1610    #[doc = "Bit 23 - Enable or disable interrupt for EP0SETUP event"]
1611    #[inline(always)]
1612    pub fn ep0setup(&mut self) -> EP0SETUP_W<23> {
1613        EP0SETUP_W::new(self)
1614    }
1615    #[doc = "Bit 24 - Enable or disable interrupt for EPDATA event"]
1616    #[inline(always)]
1617    pub fn epdata(&mut self) -> EPDATA_W<24> {
1618        EPDATA_W::new(self)
1619    }
1620    #[doc = "Writes raw bits to the register."]
1621    #[inline(always)]
1622    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
1623        self.0.bits(bits);
1624        self
1625    }
1626}
1627#[doc = "Enable or disable interrupt\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 [inten](index.html) module"]
1628pub struct INTEN_SPEC;
1629impl crate::RegisterSpec for INTEN_SPEC {
1630    type Ux = u32;
1631}
1632#[doc = "`read()` method returns [inten::R](R) reader structure"]
1633impl crate::Readable for INTEN_SPEC {
1634    type Reader = R;
1635}
1636#[doc = "`write(|w| ..)` method takes [inten::W](W) writer structure"]
1637impl crate::Writable for INTEN_SPEC {
1638    type Writer = W;
1639}
1640#[doc = "`reset()` method sets INTEN to value 0"]
1641impl crate::Resettable for INTEN_SPEC {
1642    #[inline(always)]
1643    fn reset_value() -> Self::Ux {
1644        0
1645    }
1646}