1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
#[doc = r"Value read from the register"]
pub struct R {
    bits: u32,
}
impl super::SUPC_SR {
    #[doc = r"Reads the contents of the register"]
    #[inline(always)]
    pub fn read(&self) -> R {
        R {
            bits: self.register.get(),
        }
    }
}
#[doc = "Possible values of the field `WKUPS`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPSR {
    #[doc = "No wake-up due to the assertion of the WKUP pins has occurred since the last read of SUPC_SR."]
    NO,
    #[doc = "At least one wake-up due to the assertion of the WKUP pins has occurred since the last read of SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for WKUPSR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPSR::NO => false,
            WKUPSR::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPS_R = crate::FR<bool, WKUPSR>;
impl WKUPS_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == WKUPSR::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == WKUPSR::PRESENT
    }
}
#[doc = "Possible values of the field `SMWS`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum SMWSR {
    #[doc = "No wake-up due to a supply monitor detection has occurred since the last read of SUPC_SR."]
    NO,
    #[doc = "At least one wake-up due to a supply monitor detection has occurred since the last read of SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for SMWSR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            SMWSR::NO => false,
            SMWSR::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type SMWS_R = crate::FR<bool, SMWSR>;
impl SMWS_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == SMWSR::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == SMWSR::PRESENT
    }
}
#[doc = "Possible values of the field `BODRSTS`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum BODRSTSR {
    #[doc = "No core brownout rising edge event has been detected since the last read of the SUPC_SR."]
    NO,
    #[doc = "At least one brownout output rising edge event has been detected since the last read of the SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for BODRSTSR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            BODRSTSR::NO => false,
            BODRSTSR::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type BODRSTS_R = crate::FR<bool, BODRSTSR>;
impl BODRSTS_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == BODRSTSR::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == BODRSTSR::PRESENT
    }
}
#[doc = "Possible values of the field `SMRSTS`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum SMRSTSR {
    #[doc = "No supply monitor detection has generated a core reset since the last read of the SUPC_SR."]
    NO,
    #[doc = "At least one supply monitor detection has generated a core reset since the last read of the SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for SMRSTSR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            SMRSTSR::NO => false,
            SMRSTSR::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type SMRSTS_R = crate::FR<bool, SMRSTSR>;
impl SMRSTS_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == SMRSTSR::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == SMRSTSR::PRESENT
    }
}
#[doc = "Possible values of the field `SMS`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum SMSR {
    #[doc = "No supply monitor detection since the last read of SUPC_SR."]
    NO,
    #[doc = "At least one supply monitor detection since the last read of SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for SMSR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            SMSR::NO => false,
            SMSR::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type SMS_R = crate::FR<bool, SMSR>;
impl SMS_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == SMSR::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == SMSR::PRESENT
    }
}
#[doc = "Possible values of the field `SMOS`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum SMOSR {
    #[doc = "The supply monitor detected VDDIO higher than its threshold at its last measurement."]
    HIGH,
    #[doc = "The supply monitor detected VDDIO lower than its threshold at its last measurement."]
    LOW,
}
impl crate::ToBits<bool> for SMOSR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            SMOSR::HIGH => false,
            SMOSR::LOW => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type SMOS_R = crate::FR<bool, SMOSR>;
impl SMOS_R {
    #[doc = "Checks if the value of the field is `HIGH`"]
    #[inline(always)]
    pub fn is_high(&self) -> bool {
        *self == SMOSR::HIGH
    }
    #[doc = "Checks if the value of the field is `LOW`"]
    #[inline(always)]
    pub fn is_low(&self) -> bool {
        *self == SMOSR::LOW
    }
}
#[doc = "Possible values of the field `OSCSEL`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum OSCSELR {
    #[doc = "The slow clock, SLCK, is generated by the embedded 32 kHz RC oscillator."]
    RC,
    #[doc = "The slow clock, SLCK, is generated by the 32 kHz crystal oscillator."]
    CRYST,
}
impl crate::ToBits<bool> for OSCSELR {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            OSCSELR::RC => false,
            OSCSELR::CRYST => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type OSCSEL_R = crate::FR<bool, OSCSELR>;
impl OSCSEL_R {
    #[doc = "Checks if the value of the field is `RC`"]
    #[inline(always)]
    pub fn is_rc(&self) -> bool {
        *self == OSCSELR::RC
    }
    #[doc = "Checks if the value of the field is `CRYST`"]
    #[inline(always)]
    pub fn is_cryst(&self) -> bool {
        *self == OSCSELR::CRYST
    }
}
#[doc = "Possible values of the field `LPDBCS0`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum LPDBCS0R {
    #[doc = "No wake-up due to the assertion of the WKUP0 pin has occurred since the last read of SUPC_SR."]
    NO,
    #[doc = "At least one wake-up due to the assertion of the WKUP0 pin has occurred since the last read of SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for LPDBCS0R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            LPDBCS0R::NO => false,
            LPDBCS0R::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type LPDBCS0_R = crate::FR<bool, LPDBCS0R>;
impl LPDBCS0_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == LPDBCS0R::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == LPDBCS0R::PRESENT
    }
}
#[doc = "Possible values of the field `LPDBCS1`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum LPDBCS1R {
    #[doc = "No wake-up due to the assertion of the WKUP1 pin has occurred since the last read of SUPC_SR."]
    NO,
    #[doc = "At least one wake-up due to the assertion of the WKUP1 pin has occurred since the last read of SUPC_SR."]
    PRESENT,
}
impl crate::ToBits<bool> for LPDBCS1R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            LPDBCS1R::NO => false,
            LPDBCS1R::PRESENT => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type LPDBCS1_R = crate::FR<bool, LPDBCS1R>;
impl LPDBCS1_R {
    #[doc = "Checks if the value of the field is `NO`"]
    #[inline(always)]
    pub fn is_no(&self) -> bool {
        *self == LPDBCS1R::NO
    }
    #[doc = "Checks if the value of the field is `PRESENT`"]
    #[inline(always)]
    pub fn is_present(&self) -> bool {
        *self == LPDBCS1R::PRESENT
    }
}
#[doc = "Possible values of the field `WKUPIS0`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS0R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS0R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS0R::DIS => false,
            WKUPIS0R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS0_R = crate::FR<bool, WKUPIS0R>;
impl WKUPIS0_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS0R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS0R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS1`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS1R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS1R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS1R::DIS => false,
            WKUPIS1R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS1_R = crate::FR<bool, WKUPIS1R>;
impl WKUPIS1_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS1R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS1R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS2`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS2R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS2R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS2R::DIS => false,
            WKUPIS2R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS2_R = crate::FR<bool, WKUPIS2R>;
impl WKUPIS2_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS2R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS2R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS3`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS3R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS3R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS3R::DIS => false,
            WKUPIS3R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS3_R = crate::FR<bool, WKUPIS3R>;
impl WKUPIS3_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS3R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS3R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS4`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS4R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS4R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS4R::DIS => false,
            WKUPIS4R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS4_R = crate::FR<bool, WKUPIS4R>;
impl WKUPIS4_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS4R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS4R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS5`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS5R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS5R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS5R::DIS => false,
            WKUPIS5R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS5_R = crate::FR<bool, WKUPIS5R>;
impl WKUPIS5_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS5R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS5R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS6`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS6R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS6R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS6R::DIS => false,
            WKUPIS6R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS6_R = crate::FR<bool, WKUPIS6R>;
impl WKUPIS6_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS6R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS6R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS7`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS7R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS7R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS7R::DIS => false,
            WKUPIS7R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS7_R = crate::FR<bool, WKUPIS7R>;
impl WKUPIS7_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS7R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS7R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS8`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS8R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS8R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS8R::DIS => false,
            WKUPIS8R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS8_R = crate::FR<bool, WKUPIS8R>;
impl WKUPIS8_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS8R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS8R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS9`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS9R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS9R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS9R::DIS => false,
            WKUPIS9R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS9_R = crate::FR<bool, WKUPIS9R>;
impl WKUPIS9_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS9R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS9R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS10`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS10R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS10R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS10R::DIS => false,
            WKUPIS10R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS10_R = crate::FR<bool, WKUPIS10R>;
impl WKUPIS10_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS10R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS10R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS11`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS11R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS11R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS11R::DIS => false,
            WKUPIS11R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS11_R = crate::FR<bool, WKUPIS11R>;
impl WKUPIS11_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS11R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS11R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS12`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS12R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS12R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS12R::DIS => false,
            WKUPIS12R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS12_R = crate::FR<bool, WKUPIS12R>;
impl WKUPIS12_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS12R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS12R::EN
    }
}
#[doc = "Possible values of the field `WKUPIS13`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum WKUPIS13R {
    #[doc = "The corresponding wake-up input is disabled, or was inactive at the time the debouncer triggered a wake-up event."]
    DIS,
    #[doc = "The corresponding wake-up input was active at the time the debouncer triggered a wake-up event since the last read of SUPC_SR."]
    EN,
}
impl crate::ToBits<bool> for WKUPIS13R {
    #[inline(always)]
    fn _bits(&self) -> bool {
        match *self {
            WKUPIS13R::DIS => false,
            WKUPIS13R::EN => true,
        }
    }
}
#[doc = r"Reader of the field"]
pub type WKUPIS13_R = crate::FR<bool, WKUPIS13R>;
impl WKUPIS13_R {
    #[doc = "Checks if the value of the field is `DIS`"]
    #[inline(always)]
    pub fn is_dis(&self) -> bool {
        *self == WKUPIS13R::DIS
    }
    #[doc = "Checks if the value of the field is `EN`"]
    #[inline(always)]
    pub fn is_en(&self) -> bool {
        *self == WKUPIS13R::EN
    }
}
impl R {
    #[doc = r"Value of the register as raw bits"]
    #[inline(always)]
    pub fn bits(&self) -> u32 {
        self.bits
    }
    #[doc = "Bit 1 - WKUP Wake-up Status (cleared on read)"]
    #[inline(always)]
    pub fn wkups(&self) -> WKUPS_R {
        WKUPS_R::new(((self.bits() >> 1) & 0x01) != 0)
    }
    #[doc = "Bit 2 - Supply Monitor Detection Wake-up Status (cleared on read)"]
    #[inline(always)]
    pub fn smws(&self) -> SMWS_R {
        SMWS_R::new(((self.bits() >> 2) & 0x01) != 0)
    }
    #[doc = "Bit 3 - Brownout Detector Reset Status (cleared on read)"]
    #[inline(always)]
    pub fn bodrsts(&self) -> BODRSTS_R {
        BODRSTS_R::new(((self.bits() >> 3) & 0x01) != 0)
    }
    #[doc = "Bit 4 - Supply Monitor Reset Status (cleared on read)"]
    #[inline(always)]
    pub fn smrsts(&self) -> SMRSTS_R {
        SMRSTS_R::new(((self.bits() >> 4) & 0x01) != 0)
    }
    #[doc = "Bit 5 - Supply Monitor Status (cleared on read)"]
    #[inline(always)]
    pub fn sms(&self) -> SMS_R {
        SMS_R::new(((self.bits() >> 5) & 0x01) != 0)
    }
    #[doc = "Bit 6 - Supply Monitor Output Status"]
    #[inline(always)]
    pub fn smos(&self) -> SMOS_R {
        SMOS_R::new(((self.bits() >> 6) & 0x01) != 0)
    }
    #[doc = "Bit 7 - 32-kHz Oscillator Selection Status"]
    #[inline(always)]
    pub fn oscsel(&self) -> OSCSEL_R {
        OSCSEL_R::new(((self.bits() >> 7) & 0x01) != 0)
    }
    #[doc = "Bit 13 - Low-power Debouncer Wake-up Status on WKUP0 (cleared on read)"]
    #[inline(always)]
    pub fn lpdbcs0(&self) -> LPDBCS0_R {
        LPDBCS0_R::new(((self.bits() >> 13) & 0x01) != 0)
    }
    #[doc = "Bit 14 - Low-power Debouncer Wake-up Status on WKUP1 (cleared on read)"]
    #[inline(always)]
    pub fn lpdbcs1(&self) -> LPDBCS1_R {
        LPDBCS1_R::new(((self.bits() >> 14) & 0x01) != 0)
    }
    #[doc = "Bit 16 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis0(&self) -> WKUPIS0_R {
        WKUPIS0_R::new(((self.bits() >> 16) & 0x01) != 0)
    }
    #[doc = "Bit 17 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis1(&self) -> WKUPIS1_R {
        WKUPIS1_R::new(((self.bits() >> 17) & 0x01) != 0)
    }
    #[doc = "Bit 18 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis2(&self) -> WKUPIS2_R {
        WKUPIS2_R::new(((self.bits() >> 18) & 0x01) != 0)
    }
    #[doc = "Bit 19 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis3(&self) -> WKUPIS3_R {
        WKUPIS3_R::new(((self.bits() >> 19) & 0x01) != 0)
    }
    #[doc = "Bit 20 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis4(&self) -> WKUPIS4_R {
        WKUPIS4_R::new(((self.bits() >> 20) & 0x01) != 0)
    }
    #[doc = "Bit 21 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis5(&self) -> WKUPIS5_R {
        WKUPIS5_R::new(((self.bits() >> 21) & 0x01) != 0)
    }
    #[doc = "Bit 22 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis6(&self) -> WKUPIS6_R {
        WKUPIS6_R::new(((self.bits() >> 22) & 0x01) != 0)
    }
    #[doc = "Bit 23 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis7(&self) -> WKUPIS7_R {
        WKUPIS7_R::new(((self.bits() >> 23) & 0x01) != 0)
    }
    #[doc = "Bit 24 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis8(&self) -> WKUPIS8_R {
        WKUPIS8_R::new(((self.bits() >> 24) & 0x01) != 0)
    }
    #[doc = "Bit 25 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis9(&self) -> WKUPIS9_R {
        WKUPIS9_R::new(((self.bits() >> 25) & 0x01) != 0)
    }
    #[doc = "Bit 26 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis10(&self) -> WKUPIS10_R {
        WKUPIS10_R::new(((self.bits() >> 26) & 0x01) != 0)
    }
    #[doc = "Bit 27 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis11(&self) -> WKUPIS11_R {
        WKUPIS11_R::new(((self.bits() >> 27) & 0x01) != 0)
    }
    #[doc = "Bit 28 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis12(&self) -> WKUPIS12_R {
        WKUPIS12_R::new(((self.bits() >> 28) & 0x01) != 0)
    }
    #[doc = "Bit 29 - WKUPx Input Status (cleared on read)"]
    #[inline(always)]
    pub fn wkupis13(&self) -> WKUPIS13_R {
        WKUPIS13_R::new(((self.bits() >> 29) & 0x01) != 0)
    }
}