1#[doc = r" Value read from the register"]
2pub struct R {
3 bits: u32,
4}
5#[doc = r" Value to write to the register"]
6pub struct W {
7 bits: u32,
8}
9impl super::DIER {
10 #[doc = r" Modifies the contents of the register"]
11 #[inline]
12 pub fn modify<F>(&self, f: F)
13 where
14 for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W,
15 {
16 let bits = self.register.get();
17 let r = R { bits: bits };
18 let mut w = W { bits: bits };
19 f(&r, &mut w);
20 self.register.set(w.bits);
21 }
22 #[doc = r" Reads the contents of the register"]
23 #[inline]
24 pub fn read(&self) -> R {
25 R {
26 bits: self.register.get(),
27 }
28 }
29 #[doc = r" Writes to the register"]
30 #[inline]
31 pub fn write<F>(&self, f: F)
32 where
33 F: FnOnce(&mut W) -> &mut W,
34 {
35 let mut w = W::reset_value();
36 f(&mut w);
37 self.register.set(w.bits);
38 }
39 #[doc = r" Writes the reset value to the register"]
40 #[inline]
41 pub fn reset(&self) {
42 self.write(|w| w)
43 }
44}
45#[doc = r" Value of the field"]
46pub struct TDER {
47 bits: bool,
48}
49impl TDER {
50 #[doc = r" Value of the field as raw bits"]
51 #[inline]
52 pub fn bit(&self) -> bool {
53 self.bits
54 }
55 #[doc = r" Returns `true` if the bit is clear (0)"]
56 #[inline]
57 pub fn bit_is_clear(&self) -> bool {
58 !self.bit()
59 }
60 #[doc = r" Returns `true` if the bit is set (1)"]
61 #[inline]
62 pub fn bit_is_set(&self) -> bool {
63 self.bit()
64 }
65}
66#[doc = r" Value of the field"]
67pub struct COMDER {
68 bits: bool,
69}
70impl COMDER {
71 #[doc = r" Value of the field as raw bits"]
72 #[inline]
73 pub fn bit(&self) -> bool {
74 self.bits
75 }
76 #[doc = r" Returns `true` if the bit is clear (0)"]
77 #[inline]
78 pub fn bit_is_clear(&self) -> bool {
79 !self.bit()
80 }
81 #[doc = r" Returns `true` if the bit is set (1)"]
82 #[inline]
83 pub fn bit_is_set(&self) -> bool {
84 self.bit()
85 }
86}
87#[doc = "Possible values of the field `CC1DE`"]
88#[derive(Clone, Copy, Debug, PartialEq)]
89pub enum CC1DER {
90 #[doc = "CC1 DMA request disabled"]
91 DISABLED,
92 #[doc = "CC1 DMA request enabled"]
93 ENABLED,
94}
95impl CC1DER {
96 #[doc = r" Returns `true` if the bit is clear (0)"]
97 #[inline]
98 pub fn bit_is_clear(&self) -> bool {
99 !self.bit()
100 }
101 #[doc = r" Returns `true` if the bit is set (1)"]
102 #[inline]
103 pub fn bit_is_set(&self) -> bool {
104 self.bit()
105 }
106 #[doc = r" Value of the field as raw bits"]
107 #[inline]
108 pub fn bit(&self) -> bool {
109 match *self {
110 CC1DER::DISABLED => false,
111 CC1DER::ENABLED => true,
112 }
113 }
114 #[allow(missing_docs)]
115 #[doc(hidden)]
116 #[inline]
117 pub fn _from(value: bool) -> CC1DER {
118 match value {
119 false => CC1DER::DISABLED,
120 true => CC1DER::ENABLED,
121 }
122 }
123 #[doc = "Checks if the value of the field is `DISABLED`"]
124 #[inline]
125 pub fn is_disabled(&self) -> bool {
126 *self == CC1DER::DISABLED
127 }
128 #[doc = "Checks if the value of the field is `ENABLED`"]
129 #[inline]
130 pub fn is_enabled(&self) -> bool {
131 *self == CC1DER::ENABLED
132 }
133}
134#[doc = r" Value of the field"]
135pub struct UDER {
136 bits: bool,
137}
138impl UDER {
139 #[doc = r" Value of the field as raw bits"]
140 #[inline]
141 pub fn bit(&self) -> bool {
142 self.bits
143 }
144 #[doc = r" Returns `true` if the bit is clear (0)"]
145 #[inline]
146 pub fn bit_is_clear(&self) -> bool {
147 !self.bit()
148 }
149 #[doc = r" Returns `true` if the bit is set (1)"]
150 #[inline]
151 pub fn bit_is_set(&self) -> bool {
152 self.bit()
153 }
154}
155#[doc = "Possible values of the field `BIE`"]
156#[derive(Clone, Copy, Debug, PartialEq)]
157pub enum BIER {
158 #[doc = "Break interrupt disabled"]
159 DISABLED,
160 #[doc = "Break interrupt enabled"]
161 ENABLED,
162}
163impl BIER {
164 #[doc = r" Returns `true` if the bit is clear (0)"]
165 #[inline]
166 pub fn bit_is_clear(&self) -> bool {
167 !self.bit()
168 }
169 #[doc = r" Returns `true` if the bit is set (1)"]
170 #[inline]
171 pub fn bit_is_set(&self) -> bool {
172 self.bit()
173 }
174 #[doc = r" Value of the field as raw bits"]
175 #[inline]
176 pub fn bit(&self) -> bool {
177 match *self {
178 BIER::DISABLED => false,
179 BIER::ENABLED => true,
180 }
181 }
182 #[allow(missing_docs)]
183 #[doc(hidden)]
184 #[inline]
185 pub fn _from(value: bool) -> BIER {
186 match value {
187 false => BIER::DISABLED,
188 true => BIER::ENABLED,
189 }
190 }
191 #[doc = "Checks if the value of the field is `DISABLED`"]
192 #[inline]
193 pub fn is_disabled(&self) -> bool {
194 *self == BIER::DISABLED
195 }
196 #[doc = "Checks if the value of the field is `ENABLED`"]
197 #[inline]
198 pub fn is_enabled(&self) -> bool {
199 *self == BIER::ENABLED
200 }
201}
202#[doc = r" Value of the field"]
203pub struct TIER {
204 bits: bool,
205}
206impl TIER {
207 #[doc = r" Value of the field as raw bits"]
208 #[inline]
209 pub fn bit(&self) -> bool {
210 self.bits
211 }
212 #[doc = r" Returns `true` if the bit is clear (0)"]
213 #[inline]
214 pub fn bit_is_clear(&self) -> bool {
215 !self.bit()
216 }
217 #[doc = r" Returns `true` if the bit is set (1)"]
218 #[inline]
219 pub fn bit_is_set(&self) -> bool {
220 self.bit()
221 }
222}
223#[doc = "Possible values of the field `COMIE`"]
224#[derive(Clone, Copy, Debug, PartialEq)]
225pub enum COMIER {
226 #[doc = "COM interrupt disabled"]
227 DISABLED,
228 #[doc = "COM interrupt enabled"]
229 ENABLED,
230}
231impl COMIER {
232 #[doc = r" Returns `true` if the bit is clear (0)"]
233 #[inline]
234 pub fn bit_is_clear(&self) -> bool {
235 !self.bit()
236 }
237 #[doc = r" Returns `true` if the bit is set (1)"]
238 #[inline]
239 pub fn bit_is_set(&self) -> bool {
240 self.bit()
241 }
242 #[doc = r" Value of the field as raw bits"]
243 #[inline]
244 pub fn bit(&self) -> bool {
245 match *self {
246 COMIER::DISABLED => false,
247 COMIER::ENABLED => true,
248 }
249 }
250 #[allow(missing_docs)]
251 #[doc(hidden)]
252 #[inline]
253 pub fn _from(value: bool) -> COMIER {
254 match value {
255 false => COMIER::DISABLED,
256 true => COMIER::ENABLED,
257 }
258 }
259 #[doc = "Checks if the value of the field is `DISABLED`"]
260 #[inline]
261 pub fn is_disabled(&self) -> bool {
262 *self == COMIER::DISABLED
263 }
264 #[doc = "Checks if the value of the field is `ENABLED`"]
265 #[inline]
266 pub fn is_enabled(&self) -> bool {
267 *self == COMIER::ENABLED
268 }
269}
270#[doc = "Possible values of the field `CC1IE`"]
271#[derive(Clone, Copy, Debug, PartialEq)]
272pub enum CC1IER {
273 #[doc = "CC1 interrupt disabled"]
274 DISABLED,
275 #[doc = "CC1 interrupt enabled"]
276 ENABLED,
277}
278impl CC1IER {
279 #[doc = r" Returns `true` if the bit is clear (0)"]
280 #[inline]
281 pub fn bit_is_clear(&self) -> bool {
282 !self.bit()
283 }
284 #[doc = r" Returns `true` if the bit is set (1)"]
285 #[inline]
286 pub fn bit_is_set(&self) -> bool {
287 self.bit()
288 }
289 #[doc = r" Value of the field as raw bits"]
290 #[inline]
291 pub fn bit(&self) -> bool {
292 match *self {
293 CC1IER::DISABLED => false,
294 CC1IER::ENABLED => true,
295 }
296 }
297 #[allow(missing_docs)]
298 #[doc(hidden)]
299 #[inline]
300 pub fn _from(value: bool) -> CC1IER {
301 match value {
302 false => CC1IER::DISABLED,
303 true => CC1IER::ENABLED,
304 }
305 }
306 #[doc = "Checks if the value of the field is `DISABLED`"]
307 #[inline]
308 pub fn is_disabled(&self) -> bool {
309 *self == CC1IER::DISABLED
310 }
311 #[doc = "Checks if the value of the field is `ENABLED`"]
312 #[inline]
313 pub fn is_enabled(&self) -> bool {
314 *self == CC1IER::ENABLED
315 }
316}
317#[doc = "Possible values of the field `UIE`"]
318#[derive(Clone, Copy, Debug, PartialEq)]
319pub enum UIER {
320 #[doc = "Update interrupt disabled"]
321 DISABLED,
322 #[doc = "Update interrupt enabled"]
323 ENABLED,
324}
325impl UIER {
326 #[doc = r" Returns `true` if the bit is clear (0)"]
327 #[inline]
328 pub fn bit_is_clear(&self) -> bool {
329 !self.bit()
330 }
331 #[doc = r" Returns `true` if the bit is set (1)"]
332 #[inline]
333 pub fn bit_is_set(&self) -> bool {
334 self.bit()
335 }
336 #[doc = r" Value of the field as raw bits"]
337 #[inline]
338 pub fn bit(&self) -> bool {
339 match *self {
340 UIER::DISABLED => false,
341 UIER::ENABLED => true,
342 }
343 }
344 #[allow(missing_docs)]
345 #[doc(hidden)]
346 #[inline]
347 pub fn _from(value: bool) -> UIER {
348 match value {
349 false => UIER::DISABLED,
350 true => UIER::ENABLED,
351 }
352 }
353 #[doc = "Checks if the value of the field is `DISABLED`"]
354 #[inline]
355 pub fn is_disabled(&self) -> bool {
356 *self == UIER::DISABLED
357 }
358 #[doc = "Checks if the value of the field is `ENABLED`"]
359 #[inline]
360 pub fn is_enabled(&self) -> bool {
361 *self == UIER::ENABLED
362 }
363}
364#[doc = r" Proxy"]
365pub struct _TDEW<'a> {
366 w: &'a mut W,
367}
368impl<'a> _TDEW<'a> {
369 #[doc = r" Sets the field bit"]
370 pub fn set_bit(self) -> &'a mut W {
371 self.bit(true)
372 }
373 #[doc = r" Clears the field bit"]
374 pub fn clear_bit(self) -> &'a mut W {
375 self.bit(false)
376 }
377 #[doc = r" Writes raw bits to the field"]
378 #[inline]
379 pub fn bit(self, value: bool) -> &'a mut W {
380 const MASK: bool = true;
381 const OFFSET: u8 = 14;
382 self.w.bits &= !((MASK as u32) << OFFSET);
383 self.w.bits |= ((value & MASK) as u32) << OFFSET;
384 self.w
385 }
386}
387#[doc = r" Proxy"]
388pub struct _COMDEW<'a> {
389 w: &'a mut W,
390}
391impl<'a> _COMDEW<'a> {
392 #[doc = r" Sets the field bit"]
393 pub fn set_bit(self) -> &'a mut W {
394 self.bit(true)
395 }
396 #[doc = r" Clears the field bit"]
397 pub fn clear_bit(self) -> &'a mut W {
398 self.bit(false)
399 }
400 #[doc = r" Writes raw bits to the field"]
401 #[inline]
402 pub fn bit(self, value: bool) -> &'a mut W {
403 const MASK: bool = true;
404 const OFFSET: u8 = 13;
405 self.w.bits &= !((MASK as u32) << OFFSET);
406 self.w.bits |= ((value & MASK) as u32) << OFFSET;
407 self.w
408 }
409}
410#[doc = "Values that can be written to the field `CC1DE`"]
411pub enum CC1DEW {
412 #[doc = "CC1 DMA request disabled"]
413 DISABLED,
414 #[doc = "CC1 DMA request enabled"]
415 ENABLED,
416}
417impl CC1DEW {
418 #[allow(missing_docs)]
419 #[doc(hidden)]
420 #[inline]
421 pub fn _bits(&self) -> bool {
422 match *self {
423 CC1DEW::DISABLED => false,
424 CC1DEW::ENABLED => true,
425 }
426 }
427}
428#[doc = r" Proxy"]
429pub struct _CC1DEW<'a> {
430 w: &'a mut W,
431}
432impl<'a> _CC1DEW<'a> {
433 #[doc = r" Writes `variant` to the field"]
434 #[inline]
435 pub fn variant(self, variant: CC1DEW) -> &'a mut W {
436 {
437 self.bit(variant._bits())
438 }
439 }
440 #[doc = "CC1 DMA request disabled"]
441 #[inline]
442 pub fn disabled(self) -> &'a mut W {
443 self.variant(CC1DEW::DISABLED)
444 }
445 #[doc = "CC1 DMA request enabled"]
446 #[inline]
447 pub fn enabled(self) -> &'a mut W {
448 self.variant(CC1DEW::ENABLED)
449 }
450 #[doc = r" Sets the field bit"]
451 pub fn set_bit(self) -> &'a mut W {
452 self.bit(true)
453 }
454 #[doc = r" Clears the field bit"]
455 pub fn clear_bit(self) -> &'a mut W {
456 self.bit(false)
457 }
458 #[doc = r" Writes raw bits to the field"]
459 #[inline]
460 pub fn bit(self, value: bool) -> &'a mut W {
461 const MASK: bool = true;
462 const OFFSET: u8 = 9;
463 self.w.bits &= !((MASK as u32) << OFFSET);
464 self.w.bits |= ((value & MASK) as u32) << OFFSET;
465 self.w
466 }
467}
468#[doc = r" Proxy"]
469pub struct _UDEW<'a> {
470 w: &'a mut W,
471}
472impl<'a> _UDEW<'a> {
473 #[doc = r" Sets the field bit"]
474 pub fn set_bit(self) -> &'a mut W {
475 self.bit(true)
476 }
477 #[doc = r" Clears the field bit"]
478 pub fn clear_bit(self) -> &'a mut W {
479 self.bit(false)
480 }
481 #[doc = r" Writes raw bits to the field"]
482 #[inline]
483 pub fn bit(self, value: bool) -> &'a mut W {
484 const MASK: bool = true;
485 const OFFSET: u8 = 8;
486 self.w.bits &= !((MASK as u32) << OFFSET);
487 self.w.bits |= ((value & MASK) as u32) << OFFSET;
488 self.w
489 }
490}
491#[doc = "Values that can be written to the field `BIE`"]
492pub enum BIEW {
493 #[doc = "Break interrupt disabled"]
494 DISABLED,
495 #[doc = "Break interrupt enabled"]
496 ENABLED,
497}
498impl BIEW {
499 #[allow(missing_docs)]
500 #[doc(hidden)]
501 #[inline]
502 pub fn _bits(&self) -> bool {
503 match *self {
504 BIEW::DISABLED => false,
505 BIEW::ENABLED => true,
506 }
507 }
508}
509#[doc = r" Proxy"]
510pub struct _BIEW<'a> {
511 w: &'a mut W,
512}
513impl<'a> _BIEW<'a> {
514 #[doc = r" Writes `variant` to the field"]
515 #[inline]
516 pub fn variant(self, variant: BIEW) -> &'a mut W {
517 {
518 self.bit(variant._bits())
519 }
520 }
521 #[doc = "Break interrupt disabled"]
522 #[inline]
523 pub fn disabled(self) -> &'a mut W {
524 self.variant(BIEW::DISABLED)
525 }
526 #[doc = "Break interrupt enabled"]
527 #[inline]
528 pub fn enabled(self) -> &'a mut W {
529 self.variant(BIEW::ENABLED)
530 }
531 #[doc = r" Sets the field bit"]
532 pub fn set_bit(self) -> &'a mut W {
533 self.bit(true)
534 }
535 #[doc = r" Clears the field bit"]
536 pub fn clear_bit(self) -> &'a mut W {
537 self.bit(false)
538 }
539 #[doc = r" Writes raw bits to the field"]
540 #[inline]
541 pub fn bit(self, value: bool) -> &'a mut W {
542 const MASK: bool = true;
543 const OFFSET: u8 = 7;
544 self.w.bits &= !((MASK as u32) << OFFSET);
545 self.w.bits |= ((value & MASK) as u32) << OFFSET;
546 self.w
547 }
548}
549#[doc = r" Proxy"]
550pub struct _TIEW<'a> {
551 w: &'a mut W,
552}
553impl<'a> _TIEW<'a> {
554 #[doc = r" Sets the field bit"]
555 pub fn set_bit(self) -> &'a mut W {
556 self.bit(true)
557 }
558 #[doc = r" Clears the field bit"]
559 pub fn clear_bit(self) -> &'a mut W {
560 self.bit(false)
561 }
562 #[doc = r" Writes raw bits to the field"]
563 #[inline]
564 pub fn bit(self, value: bool) -> &'a mut W {
565 const MASK: bool = true;
566 const OFFSET: u8 = 6;
567 self.w.bits &= !((MASK as u32) << OFFSET);
568 self.w.bits |= ((value & MASK) as u32) << OFFSET;
569 self.w
570 }
571}
572#[doc = "Values that can be written to the field `COMIE`"]
573pub enum COMIEW {
574 #[doc = "COM interrupt disabled"]
575 DISABLED,
576 #[doc = "COM interrupt enabled"]
577 ENABLED,
578}
579impl COMIEW {
580 #[allow(missing_docs)]
581 #[doc(hidden)]
582 #[inline]
583 pub fn _bits(&self) -> bool {
584 match *self {
585 COMIEW::DISABLED => false,
586 COMIEW::ENABLED => true,
587 }
588 }
589}
590#[doc = r" Proxy"]
591pub struct _COMIEW<'a> {
592 w: &'a mut W,
593}
594impl<'a> _COMIEW<'a> {
595 #[doc = r" Writes `variant` to the field"]
596 #[inline]
597 pub fn variant(self, variant: COMIEW) -> &'a mut W {
598 {
599 self.bit(variant._bits())
600 }
601 }
602 #[doc = "COM interrupt disabled"]
603 #[inline]
604 pub fn disabled(self) -> &'a mut W {
605 self.variant(COMIEW::DISABLED)
606 }
607 #[doc = "COM interrupt enabled"]
608 #[inline]
609 pub fn enabled(self) -> &'a mut W {
610 self.variant(COMIEW::ENABLED)
611 }
612 #[doc = r" Sets the field bit"]
613 pub fn set_bit(self) -> &'a mut W {
614 self.bit(true)
615 }
616 #[doc = r" Clears the field bit"]
617 pub fn clear_bit(self) -> &'a mut W {
618 self.bit(false)
619 }
620 #[doc = r" Writes raw bits to the field"]
621 #[inline]
622 pub fn bit(self, value: bool) -> &'a mut W {
623 const MASK: bool = true;
624 const OFFSET: u8 = 5;
625 self.w.bits &= !((MASK as u32) << OFFSET);
626 self.w.bits |= ((value & MASK) as u32) << OFFSET;
627 self.w
628 }
629}
630#[doc = "Values that can be written to the field `CC1IE`"]
631pub enum CC1IEW {
632 #[doc = "CC1 interrupt disabled"]
633 DISABLED,
634 #[doc = "CC1 interrupt enabled"]
635 ENABLED,
636}
637impl CC1IEW {
638 #[allow(missing_docs)]
639 #[doc(hidden)]
640 #[inline]
641 pub fn _bits(&self) -> bool {
642 match *self {
643 CC1IEW::DISABLED => false,
644 CC1IEW::ENABLED => true,
645 }
646 }
647}
648#[doc = r" Proxy"]
649pub struct _CC1IEW<'a> {
650 w: &'a mut W,
651}
652impl<'a> _CC1IEW<'a> {
653 #[doc = r" Writes `variant` to the field"]
654 #[inline]
655 pub fn variant(self, variant: CC1IEW) -> &'a mut W {
656 {
657 self.bit(variant._bits())
658 }
659 }
660 #[doc = "CC1 interrupt disabled"]
661 #[inline]
662 pub fn disabled(self) -> &'a mut W {
663 self.variant(CC1IEW::DISABLED)
664 }
665 #[doc = "CC1 interrupt enabled"]
666 #[inline]
667 pub fn enabled(self) -> &'a mut W {
668 self.variant(CC1IEW::ENABLED)
669 }
670 #[doc = r" Sets the field bit"]
671 pub fn set_bit(self) -> &'a mut W {
672 self.bit(true)
673 }
674 #[doc = r" Clears the field bit"]
675 pub fn clear_bit(self) -> &'a mut W {
676 self.bit(false)
677 }
678 #[doc = r" Writes raw bits to the field"]
679 #[inline]
680 pub fn bit(self, value: bool) -> &'a mut W {
681 const MASK: bool = true;
682 const OFFSET: u8 = 1;
683 self.w.bits &= !((MASK as u32) << OFFSET);
684 self.w.bits |= ((value & MASK) as u32) << OFFSET;
685 self.w
686 }
687}
688#[doc = "Values that can be written to the field `UIE`"]
689pub enum UIEW {
690 #[doc = "Update interrupt disabled"]
691 DISABLED,
692 #[doc = "Update interrupt enabled"]
693 ENABLED,
694}
695impl UIEW {
696 #[allow(missing_docs)]
697 #[doc(hidden)]
698 #[inline]
699 pub fn _bits(&self) -> bool {
700 match *self {
701 UIEW::DISABLED => false,
702 UIEW::ENABLED => true,
703 }
704 }
705}
706#[doc = r" Proxy"]
707pub struct _UIEW<'a> {
708 w: &'a mut W,
709}
710impl<'a> _UIEW<'a> {
711 #[doc = r" Writes `variant` to the field"]
712 #[inline]
713 pub fn variant(self, variant: UIEW) -> &'a mut W {
714 {
715 self.bit(variant._bits())
716 }
717 }
718 #[doc = "Update interrupt disabled"]
719 #[inline]
720 pub fn disabled(self) -> &'a mut W {
721 self.variant(UIEW::DISABLED)
722 }
723 #[doc = "Update interrupt enabled"]
724 #[inline]
725 pub fn enabled(self) -> &'a mut W {
726 self.variant(UIEW::ENABLED)
727 }
728 #[doc = r" Sets the field bit"]
729 pub fn set_bit(self) -> &'a mut W {
730 self.bit(true)
731 }
732 #[doc = r" Clears the field bit"]
733 pub fn clear_bit(self) -> &'a mut W {
734 self.bit(false)
735 }
736 #[doc = r" Writes raw bits to the field"]
737 #[inline]
738 pub fn bit(self, value: bool) -> &'a mut W {
739 const MASK: bool = true;
740 const OFFSET: u8 = 0;
741 self.w.bits &= !((MASK as u32) << OFFSET);
742 self.w.bits |= ((value & MASK) as u32) << OFFSET;
743 self.w
744 }
745}
746impl R {
747 #[doc = r" Value of the register as raw bits"]
748 #[inline]
749 pub fn bits(&self) -> u32 {
750 self.bits
751 }
752 #[doc = "Bit 14 - Trigger DMA request enable"]
753 #[inline]
754 pub fn tde(&self) -> TDER {
755 let bits = {
756 const MASK: bool = true;
757 const OFFSET: u8 = 14;
758 ((self.bits >> OFFSET) & MASK as u32) != 0
759 };
760 TDER { bits }
761 }
762 #[doc = "Bit 13 - COM DMA request enable"]
763 #[inline]
764 pub fn comde(&self) -> COMDER {
765 let bits = {
766 const MASK: bool = true;
767 const OFFSET: u8 = 13;
768 ((self.bits >> OFFSET) & MASK as u32) != 0
769 };
770 COMDER { bits }
771 }
772 #[doc = "Bit 9 - Capture/Compare 1 DMA request enable"]
773 #[inline]
774 pub fn cc1de(&self) -> CC1DER {
775 CC1DER::_from({
776 const MASK: bool = true;
777 const OFFSET: u8 = 9;
778 ((self.bits >> OFFSET) & MASK as u32) != 0
779 })
780 }
781 #[doc = "Bit 8 - Update DMA request enable"]
782 #[inline]
783 pub fn ude(&self) -> UDER {
784 let bits = {
785 const MASK: bool = true;
786 const OFFSET: u8 = 8;
787 ((self.bits >> OFFSET) & MASK as u32) != 0
788 };
789 UDER { bits }
790 }
791 #[doc = "Bit 7 - Break interrupt enable"]
792 #[inline]
793 pub fn bie(&self) -> BIER {
794 BIER::_from({
795 const MASK: bool = true;
796 const OFFSET: u8 = 7;
797 ((self.bits >> OFFSET) & MASK as u32) != 0
798 })
799 }
800 #[doc = "Bit 6 - Trigger interrupt enable"]
801 #[inline]
802 pub fn tie(&self) -> TIER {
803 let bits = {
804 const MASK: bool = true;
805 const OFFSET: u8 = 6;
806 ((self.bits >> OFFSET) & MASK as u32) != 0
807 };
808 TIER { bits }
809 }
810 #[doc = "Bit 5 - COM interrupt enable"]
811 #[inline]
812 pub fn comie(&self) -> COMIER {
813 COMIER::_from({
814 const MASK: bool = true;
815 const OFFSET: u8 = 5;
816 ((self.bits >> OFFSET) & MASK as u32) != 0
817 })
818 }
819 #[doc = "Bit 1 - Capture/Compare 1 interrupt enable"]
820 #[inline]
821 pub fn cc1ie(&self) -> CC1IER {
822 CC1IER::_from({
823 const MASK: bool = true;
824 const OFFSET: u8 = 1;
825 ((self.bits >> OFFSET) & MASK as u32) != 0
826 })
827 }
828 #[doc = "Bit 0 - Update interrupt enable"]
829 #[inline]
830 pub fn uie(&self) -> UIER {
831 UIER::_from({
832 const MASK: bool = true;
833 const OFFSET: u8 = 0;
834 ((self.bits >> OFFSET) & MASK as u32) != 0
835 })
836 }
837}
838impl W {
839 #[doc = r" Reset value of the register"]
840 #[inline]
841 pub fn reset_value() -> W {
842 W { bits: 0 }
843 }
844 #[doc = r" Writes raw bits to the register"]
845 #[inline]
846 pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
847 self.bits = bits;
848 self
849 }
850 #[doc = "Bit 14 - Trigger DMA request enable"]
851 #[inline]
852 pub fn tde(&mut self) -> _TDEW {
853 _TDEW { w: self }
854 }
855 #[doc = "Bit 13 - COM DMA request enable"]
856 #[inline]
857 pub fn comde(&mut self) -> _COMDEW {
858 _COMDEW { w: self }
859 }
860 #[doc = "Bit 9 - Capture/Compare 1 DMA request enable"]
861 #[inline]
862 pub fn cc1de(&mut self) -> _CC1DEW {
863 _CC1DEW { w: self }
864 }
865 #[doc = "Bit 8 - Update DMA request enable"]
866 #[inline]
867 pub fn ude(&mut self) -> _UDEW {
868 _UDEW { w: self }
869 }
870 #[doc = "Bit 7 - Break interrupt enable"]
871 #[inline]
872 pub fn bie(&mut self) -> _BIEW {
873 _BIEW { w: self }
874 }
875 #[doc = "Bit 6 - Trigger interrupt enable"]
876 #[inline]
877 pub fn tie(&mut self) -> _TIEW {
878 _TIEW { w: self }
879 }
880 #[doc = "Bit 5 - COM interrupt enable"]
881 #[inline]
882 pub fn comie(&mut self) -> _COMIEW {
883 _COMIEW { w: self }
884 }
885 #[doc = "Bit 1 - Capture/Compare 1 interrupt enable"]
886 #[inline]
887 pub fn cc1ie(&mut self) -> _CC1IEW {
888 _CC1IEW { w: self }
889 }
890 #[doc = "Bit 0 - Update interrupt enable"]
891 #[inline]
892 pub fn uie(&mut self) -> _UIEW {
893 _UIEW { w: self }
894 }
895}