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