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