Skip to main content

ra2e3_pac/
mstp.rs

1/*
2DISCLAIMER
3This software is supplied by Renesas Electronics Corporation and is only intended for use with Renesas products.
4No other uses are authorized. This software is owned by Renesas Electronics Corporation and is protected under all
5applicable laws, including copyright laws.
6THIS SOFTWARE IS PROVIDED "AS IS" AND RENESAS MAKES NO WARRANTIES REGARDING THIS SOFTWARE, WHETHER EXPRESS, IMPLIED
7OR STATUTORY, INCLUDING BUT NOT LIMITED TO WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
8NON-INFRINGEMENT.  ALL SUCH WARRANTIES ARE EXPRESSLY DISCLAIMED.TO THE MAXIMUM EXTENT PERMITTED NOT PROHIBITED BY
9LAW, NEITHER RENESAS ELECTRONICS CORPORATION NOR ANY OF ITS AFFILIATED COMPANIES SHALL BE LIABLE FOR ANY DIRECT,
10INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR ANY REASON RELATED TO THIS SOFTWARE, EVEN IF RENESAS OR
11ITS AFFILIATES HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
12Renesas reserves the right, without notice, to make changes to this software and to discontinue the availability
13of this software. By using this software, you agree to the additional terms and conditions found by accessing the
14following link:
15http://www.renesas.com/disclaimer
16
17*/
18// Generated from SVD 1.20.00, with svd2pac 0.6.1 on Sun, 15 Mar 2026 07:02:40 +0000
19
20#![allow(clippy::identity_op)]
21#![allow(clippy::module_inception)]
22#![allow(clippy::derivable_impls)]
23#[allow(unused_imports)]
24use crate::common::sealed;
25#[allow(unused_imports)]
26use crate::common::*;
27#[doc = r"Module Stop Control B, C, D"]
28unsafe impl ::core::marker::Send for super::Mstp {}
29unsafe impl ::core::marker::Sync for super::Mstp {}
30impl super::Mstp {
31    #[allow(unused)]
32    #[inline(always)]
33    pub(crate) const fn _svd2pac_as_ptr(&self) -> *mut u8 {
34        self.ptr
35    }
36
37    #[doc = "Module Stop Control Register B"]
38    #[inline(always)]
39    pub const fn mstpcrb(
40        &self,
41    ) -> &'static crate::common::Reg<self::Mstpcrb_SPEC, crate::common::RW> {
42        unsafe {
43            crate::common::Reg::<self::Mstpcrb_SPEC, crate::common::RW>::from_ptr(
44                self._svd2pac_as_ptr().add(0usize),
45            )
46        }
47    }
48
49    #[doc = "Module Stop Control Register C"]
50    #[inline(always)]
51    pub const fn mstpcrc(
52        &self,
53    ) -> &'static crate::common::Reg<self::Mstpcrc_SPEC, crate::common::RW> {
54        unsafe {
55            crate::common::Reg::<self::Mstpcrc_SPEC, crate::common::RW>::from_ptr(
56                self._svd2pac_as_ptr().add(4usize),
57            )
58        }
59    }
60
61    #[doc = "Module Stop Control Register D"]
62    #[inline(always)]
63    pub const fn mstpcrd(
64        &self,
65    ) -> &'static crate::common::Reg<self::Mstpcrd_SPEC, crate::common::RW> {
66        unsafe {
67            crate::common::Reg::<self::Mstpcrd_SPEC, crate::common::RW>::from_ptr(
68                self._svd2pac_as_ptr().add(8usize),
69            )
70        }
71    }
72
73    #[doc = "Low Speed Module R/W Disable Control Register"]
74    #[inline(always)]
75    pub const fn lsmrwdis(
76        &self,
77    ) -> &'static crate::common::Reg<self::Lsmrwdis_SPEC, crate::common::RW> {
78        unsafe {
79            crate::common::Reg::<self::Lsmrwdis_SPEC, crate::common::RW>::from_ptr(
80                self._svd2pac_as_ptr().add(12usize),
81            )
82        }
83    }
84}
85#[doc(hidden)]
86#[derive(Copy, Clone, Eq, PartialEq)]
87pub struct Mstpcrb_SPEC;
88impl crate::sealed::RegSpec for Mstpcrb_SPEC {
89    type DataType = u32;
90}
91
92#[doc = "Module Stop Control Register B"]
93pub type Mstpcrb = crate::RegValueT<Mstpcrb_SPEC>;
94
95impl Mstpcrb {
96    #[doc = "I2C Bus Interface 0 Module Stop"]
97    #[inline(always)]
98    pub fn mstpb9(
99        self,
100    ) -> crate::common::RegisterField<
101        9,
102        0x1,
103        1,
104        0,
105        mstpcrb::Mstpb9,
106        mstpcrb::Mstpb9,
107        Mstpcrb_SPEC,
108        crate::common::RW,
109    > {
110        crate::common::RegisterField::<
111            9,
112            0x1,
113            1,
114            0,
115            mstpcrb::Mstpb9,
116            mstpcrb::Mstpb9,
117            Mstpcrb_SPEC,
118            crate::common::RW,
119        >::from_register(self, 0)
120    }
121
122    #[doc = "Serial Peripheral Interface 0 Module Stop"]
123    #[inline(always)]
124    pub fn mstpb19(
125        self,
126    ) -> crate::common::RegisterField<
127        19,
128        0x1,
129        1,
130        0,
131        mstpcrb::Mstpb19,
132        mstpcrb::Mstpb19,
133        Mstpcrb_SPEC,
134        crate::common::RW,
135    > {
136        crate::common::RegisterField::<
137            19,
138            0x1,
139            1,
140            0,
141            mstpcrb::Mstpb19,
142            mstpcrb::Mstpb19,
143            Mstpcrb_SPEC,
144            crate::common::RW,
145        >::from_register(self, 0)
146    }
147
148    #[doc = "Serial Communication Interface 9 Module Stop"]
149    #[inline(always)]
150    pub fn mstpb22(
151        self,
152    ) -> crate::common::RegisterField<
153        22,
154        0x1,
155        1,
156        0,
157        mstpcrb::Mstpb22,
158        mstpcrb::Mstpb22,
159        Mstpcrb_SPEC,
160        crate::common::RW,
161    > {
162        crate::common::RegisterField::<
163            22,
164            0x1,
165            1,
166            0,
167            mstpcrb::Mstpb22,
168            mstpcrb::Mstpb22,
169            Mstpcrb_SPEC,
170            crate::common::RW,
171        >::from_register(self, 0)
172    }
173
174    #[doc = "Serial Communication Interface 2 Module Stop"]
175    #[inline(always)]
176    pub fn mstpb29(
177        self,
178    ) -> crate::common::RegisterField<
179        29,
180        0x1,
181        1,
182        0,
183        mstpcrb::Mstpb29,
184        mstpcrb::Mstpb29,
185        Mstpcrb_SPEC,
186        crate::common::RW,
187    > {
188        crate::common::RegisterField::<
189            29,
190            0x1,
191            1,
192            0,
193            mstpcrb::Mstpb29,
194            mstpcrb::Mstpb29,
195            Mstpcrb_SPEC,
196            crate::common::RW,
197        >::from_register(self, 0)
198    }
199
200    #[doc = "Serial Communication Interface 1 Module Stop"]
201    #[inline(always)]
202    pub fn mstpb30(
203        self,
204    ) -> crate::common::RegisterField<
205        30,
206        0x1,
207        1,
208        0,
209        mstpcrb::Mstpb30,
210        mstpcrb::Mstpb30,
211        Mstpcrb_SPEC,
212        crate::common::RW,
213    > {
214        crate::common::RegisterField::<
215            30,
216            0x1,
217            1,
218            0,
219            mstpcrb::Mstpb30,
220            mstpcrb::Mstpb30,
221            Mstpcrb_SPEC,
222            crate::common::RW,
223        >::from_register(self, 0)
224    }
225
226    #[doc = "Serial Communication Interface 0 Module Stop"]
227    #[inline(always)]
228    pub fn mstpb31(
229        self,
230    ) -> crate::common::RegisterField<
231        31,
232        0x1,
233        1,
234        0,
235        mstpcrb::Mstpb31,
236        mstpcrb::Mstpb31,
237        Mstpcrb_SPEC,
238        crate::common::RW,
239    > {
240        crate::common::RegisterField::<
241            31,
242            0x1,
243            1,
244            0,
245            mstpcrb::Mstpb31,
246            mstpcrb::Mstpb31,
247            Mstpcrb_SPEC,
248            crate::common::RW,
249        >::from_register(self, 0)
250    }
251}
252impl ::core::default::Default for Mstpcrb {
253    #[inline(always)]
254    fn default() -> Mstpcrb {
255        <crate::RegValueT<Mstpcrb_SPEC> as RegisterValue<_>>::new(4294967295)
256    }
257}
258pub mod mstpcrb {
259
260    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
261    pub struct Mstpb9_SPEC;
262    pub type Mstpb9 = crate::EnumBitfieldStruct<u8, Mstpb9_SPEC>;
263    impl Mstpb9 {
264        #[doc = "Cancel the module-stop state"]
265        pub const _0: Self = Self::new(0);
266
267        #[doc = "Enter the module-stop state"]
268        pub const _1: Self = Self::new(1);
269    }
270    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
271    pub struct Mstpb19_SPEC;
272    pub type Mstpb19 = crate::EnumBitfieldStruct<u8, Mstpb19_SPEC>;
273    impl Mstpb19 {
274        #[doc = "Cancel the module-stop state"]
275        pub const _0: Self = Self::new(0);
276
277        #[doc = "Enter the module-stop state"]
278        pub const _1: Self = Self::new(1);
279    }
280    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
281    pub struct Mstpb22_SPEC;
282    pub type Mstpb22 = crate::EnumBitfieldStruct<u8, Mstpb22_SPEC>;
283    impl Mstpb22 {
284        #[doc = "Cancel the module-stop state"]
285        pub const _0: Self = Self::new(0);
286
287        #[doc = "Enter the module-stop state"]
288        pub const _1: Self = Self::new(1);
289    }
290    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
291    pub struct Mstpb29_SPEC;
292    pub type Mstpb29 = crate::EnumBitfieldStruct<u8, Mstpb29_SPEC>;
293    impl Mstpb29 {
294        #[doc = "Cancel the module-stop state"]
295        pub const _0: Self = Self::new(0);
296
297        #[doc = "Enter the module-stop state"]
298        pub const _1: Self = Self::new(1);
299    }
300    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
301    pub struct Mstpb30_SPEC;
302    pub type Mstpb30 = crate::EnumBitfieldStruct<u8, Mstpb30_SPEC>;
303    impl Mstpb30 {
304        #[doc = "Cancel the module-stop state"]
305        pub const _0: Self = Self::new(0);
306
307        #[doc = "Enter the module-stop state"]
308        pub const _1: Self = Self::new(1);
309    }
310    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
311    pub struct Mstpb31_SPEC;
312    pub type Mstpb31 = crate::EnumBitfieldStruct<u8, Mstpb31_SPEC>;
313    impl Mstpb31 {
314        #[doc = "Cancel the module-stop state"]
315        pub const _0: Self = Self::new(0);
316
317        #[doc = "Enter the module-stop state"]
318        pub const _1: Self = Self::new(1);
319    }
320}
321#[doc(hidden)]
322#[derive(Copy, Clone, Eq, PartialEq)]
323pub struct Mstpcrc_SPEC;
324impl crate::sealed::RegSpec for Mstpcrc_SPEC {
325    type DataType = u32;
326}
327
328#[doc = "Module Stop Control Register C"]
329pub type Mstpcrc = crate::RegValueT<Mstpcrc_SPEC>;
330
331impl Mstpcrc {
332    #[doc = "Clock Frequency Accuracy Measurement Circuit Module Stop"]
333    #[inline(always)]
334    pub fn mstpc0(
335        self,
336    ) -> crate::common::RegisterField<
337        0,
338        0x1,
339        1,
340        0,
341        mstpcrc::Mstpc0,
342        mstpcrc::Mstpc0,
343        Mstpcrc_SPEC,
344        crate::common::RW,
345    > {
346        crate::common::RegisterField::<
347            0,
348            0x1,
349            1,
350            0,
351            mstpcrc::Mstpc0,
352            mstpcrc::Mstpc0,
353            Mstpcrc_SPEC,
354            crate::common::RW,
355        >::from_register(self, 0)
356    }
357
358    #[doc = "Cyclic Redundancy Check Calculator Module Stop"]
359    #[inline(always)]
360    pub fn mstpc1(
361        self,
362    ) -> crate::common::RegisterField<
363        1,
364        0x1,
365        1,
366        0,
367        mstpcrc::Mstpc1,
368        mstpcrc::Mstpc1,
369        Mstpcrc_SPEC,
370        crate::common::RW,
371    > {
372        crate::common::RegisterField::<
373            1,
374            0x1,
375            1,
376            0,
377            mstpcrc::Mstpc1,
378            mstpcrc::Mstpc1,
379            Mstpcrc_SPEC,
380            crate::common::RW,
381        >::from_register(self, 0)
382    }
383
384    #[doc = "Data Operation Circuit Module Stop"]
385    #[inline(always)]
386    pub fn mstpc13(
387        self,
388    ) -> crate::common::RegisterField<
389        13,
390        0x1,
391        1,
392        0,
393        mstpcrc::Mstpc13,
394        mstpcrc::Mstpc13,
395        Mstpcrc_SPEC,
396        crate::common::RW,
397    > {
398        crate::common::RegisterField::<
399            13,
400            0x1,
401            1,
402            0,
403            mstpcrc::Mstpc13,
404            mstpcrc::Mstpc13,
405            Mstpcrc_SPEC,
406            crate::common::RW,
407        >::from_register(self, 0)
408    }
409
410    #[doc = "Event Link Controller Module Stop"]
411    #[inline(always)]
412    pub fn mstpc14(
413        self,
414    ) -> crate::common::RegisterField<
415        14,
416        0x1,
417        1,
418        0,
419        mstpcrc::Mstpc14,
420        mstpcrc::Mstpc14,
421        Mstpcrc_SPEC,
422        crate::common::RW,
423    > {
424        crate::common::RegisterField::<
425            14,
426            0x1,
427            1,
428            0,
429            mstpcrc::Mstpc14,
430            mstpcrc::Mstpc14,
431            Mstpcrc_SPEC,
432            crate::common::RW,
433        >::from_register(self, 0)
434    }
435}
436impl ::core::default::Default for Mstpcrc {
437    #[inline(always)]
438    fn default() -> Mstpcrc {
439        <crate::RegValueT<Mstpcrc_SPEC> as RegisterValue<_>>::new(4294967295)
440    }
441}
442pub mod mstpcrc {
443
444    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
445    pub struct Mstpc0_SPEC;
446    pub type Mstpc0 = crate::EnumBitfieldStruct<u8, Mstpc0_SPEC>;
447    impl Mstpc0 {
448        #[doc = "Cancel the module-stop state"]
449        pub const _0: Self = Self::new(0);
450
451        #[doc = "Enter the module-stop state"]
452        pub const _1: Self = Self::new(1);
453    }
454    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
455    pub struct Mstpc1_SPEC;
456    pub type Mstpc1 = crate::EnumBitfieldStruct<u8, Mstpc1_SPEC>;
457    impl Mstpc1 {
458        #[doc = "Cancel the module-stop state"]
459        pub const _0: Self = Self::new(0);
460
461        #[doc = "Enter the module-stop state"]
462        pub const _1: Self = Self::new(1);
463    }
464    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
465    pub struct Mstpc13_SPEC;
466    pub type Mstpc13 = crate::EnumBitfieldStruct<u8, Mstpc13_SPEC>;
467    impl Mstpc13 {
468        #[doc = "Cancel the module-stop state"]
469        pub const _0: Self = Self::new(0);
470
471        #[doc = "Enter the module-stop state"]
472        pub const _1: Self = Self::new(1);
473    }
474    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
475    pub struct Mstpc14_SPEC;
476    pub type Mstpc14 = crate::EnumBitfieldStruct<u8, Mstpc14_SPEC>;
477    impl Mstpc14 {
478        #[doc = "Cancel the module-stop state"]
479        pub const _0: Self = Self::new(0);
480
481        #[doc = "Enter the module-stop state"]
482        pub const _1: Self = Self::new(1);
483    }
484}
485#[doc(hidden)]
486#[derive(Copy, Clone, Eq, PartialEq)]
487pub struct Mstpcrd_SPEC;
488impl crate::sealed::RegSpec for Mstpcrd_SPEC {
489    type DataType = u32;
490}
491
492#[doc = "Module Stop Control Register D"]
493pub type Mstpcrd = crate::RegValueT<Mstpcrd_SPEC>;
494
495impl Mstpcrd {
496    #[doc = "Low Power Asynchronous General Purpose Timer 1 Module Stop"]
497    #[inline(always)]
498    pub fn mstpd2(
499        self,
500    ) -> crate::common::RegisterField<
501        2,
502        0x1,
503        1,
504        0,
505        mstpcrd::Mstpd2,
506        mstpcrd::Mstpd2,
507        Mstpcrd_SPEC,
508        crate::common::RW,
509    > {
510        crate::common::RegisterField::<
511            2,
512            0x1,
513            1,
514            0,
515            mstpcrd::Mstpd2,
516            mstpcrd::Mstpd2,
517            Mstpcrd_SPEC,
518            crate::common::RW,
519        >::from_register(self, 0)
520    }
521
522    #[doc = "Low Power Asynchronous General Purpose Timer 0 Module Stop"]
523    #[inline(always)]
524    pub fn mstpd3(
525        self,
526    ) -> crate::common::RegisterField<
527        3,
528        0x1,
529        1,
530        0,
531        mstpcrd::Mstpd3,
532        mstpcrd::Mstpd3,
533        Mstpcrd_SPEC,
534        crate::common::RW,
535    > {
536        crate::common::RegisterField::<
537            3,
538            0x1,
539            1,
540            0,
541            mstpcrd::Mstpd3,
542            mstpcrd::Mstpd3,
543            Mstpcrd_SPEC,
544            crate::common::RW,
545        >::from_register(self, 0)
546    }
547
548    #[doc = "General PWM Timer 32n Module Stop"]
549    #[inline(always)]
550    pub fn mstpd5(
551        self,
552    ) -> crate::common::RegisterField<
553        5,
554        0x1,
555        1,
556        0,
557        mstpcrd::Mstpd5,
558        mstpcrd::Mstpd5,
559        Mstpcrd_SPEC,
560        crate::common::RW,
561    > {
562        crate::common::RegisterField::<
563            5,
564            0x1,
565            1,
566            0,
567            mstpcrd::Mstpd5,
568            mstpcrd::Mstpd5,
569            Mstpcrd_SPEC,
570            crate::common::RW,
571        >::from_register(self, 0)
572    }
573
574    #[doc = "General PWM Timer 164 to 169 and PWM Delay Generation Circuit Module Stop"]
575    #[inline(always)]
576    pub fn mstpd6(
577        self,
578    ) -> crate::common::RegisterField<
579        6,
580        0x1,
581        1,
582        0,
583        mstpcrd::Mstpd6,
584        mstpcrd::Mstpd6,
585        Mstpcrd_SPEC,
586        crate::common::RW,
587    > {
588        crate::common::RegisterField::<
589            6,
590            0x1,
591            1,
592            0,
593            mstpcrd::Mstpd6,
594            mstpcrd::Mstpd6,
595            Mstpcrd_SPEC,
596            crate::common::RW,
597        >::from_register(self, 0)
598    }
599
600    #[doc = "Port Output Enable for GPT Module Stop"]
601    #[inline(always)]
602    pub fn mstpd14(
603        self,
604    ) -> crate::common::RegisterField<
605        14,
606        0x1,
607        1,
608        0,
609        mstpcrd::Mstpd14,
610        mstpcrd::Mstpd14,
611        Mstpcrd_SPEC,
612        crate::common::RW,
613    > {
614        crate::common::RegisterField::<
615            14,
616            0x1,
617            1,
618            0,
619            mstpcrd::Mstpd14,
620            mstpcrd::Mstpd14,
621            Mstpcrd_SPEC,
622            crate::common::RW,
623        >::from_register(self, 0)
624    }
625
626    #[doc = "12-bit A/D Converter Module Stop"]
627    #[inline(always)]
628    pub fn mstpd16(
629        self,
630    ) -> crate::common::RegisterField<
631        16,
632        0x1,
633        1,
634        0,
635        mstpcrd::Mstpd16,
636        mstpcrd::Mstpd16,
637        Mstpcrd_SPEC,
638        crate::common::RW,
639    > {
640        crate::common::RegisterField::<
641            16,
642            0x1,
643            1,
644            0,
645            mstpcrd::Mstpd16,
646            mstpcrd::Mstpd16,
647            Mstpcrd_SPEC,
648            crate::common::RW,
649        >::from_register(self, 0)
650    }
651}
652impl ::core::default::Default for Mstpcrd {
653    #[inline(always)]
654    fn default() -> Mstpcrd {
655        <crate::RegValueT<Mstpcrd_SPEC> as RegisterValue<_>>::new(4294967295)
656    }
657}
658pub mod mstpcrd {
659
660    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
661    pub struct Mstpd2_SPEC;
662    pub type Mstpd2 = crate::EnumBitfieldStruct<u8, Mstpd2_SPEC>;
663    impl Mstpd2 {
664        #[doc = "Cancel the module-stop state"]
665        pub const _0: Self = Self::new(0);
666
667        #[doc = "Enter the module-stop state"]
668        pub const _1: Self = Self::new(1);
669    }
670    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
671    pub struct Mstpd3_SPEC;
672    pub type Mstpd3 = crate::EnumBitfieldStruct<u8, Mstpd3_SPEC>;
673    impl Mstpd3 {
674        #[doc = "Cancel the module-stop state"]
675        pub const _0: Self = Self::new(0);
676
677        #[doc = "Enter the module-stop state"]
678        pub const _1: Self = Self::new(1);
679    }
680    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
681    pub struct Mstpd5_SPEC;
682    pub type Mstpd5 = crate::EnumBitfieldStruct<u8, Mstpd5_SPEC>;
683    impl Mstpd5 {
684        #[doc = "Cancel the module-stop state"]
685        pub const _0: Self = Self::new(0);
686
687        #[doc = "Enter the module-stop state"]
688        pub const _1: Self = Self::new(1);
689    }
690    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
691    pub struct Mstpd6_SPEC;
692    pub type Mstpd6 = crate::EnumBitfieldStruct<u8, Mstpd6_SPEC>;
693    impl Mstpd6 {
694        #[doc = "Cancel the module-stop state"]
695        pub const _0: Self = Self::new(0);
696
697        #[doc = "Enter the module-stop state"]
698        pub const _1: Self = Self::new(1);
699    }
700    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
701    pub struct Mstpd14_SPEC;
702    pub type Mstpd14 = crate::EnumBitfieldStruct<u8, Mstpd14_SPEC>;
703    impl Mstpd14 {
704        #[doc = "Cancel the module-stop state"]
705        pub const _0: Self = Self::new(0);
706
707        #[doc = "Enter the module-stop state"]
708        pub const _1: Self = Self::new(1);
709    }
710    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
711    pub struct Mstpd16_SPEC;
712    pub type Mstpd16 = crate::EnumBitfieldStruct<u8, Mstpd16_SPEC>;
713    impl Mstpd16 {
714        #[doc = "Cancel the module-stop state"]
715        pub const _0: Self = Self::new(0);
716
717        #[doc = "Enter the module-stop state"]
718        pub const _1: Self = Self::new(1);
719    }
720}
721#[doc(hidden)]
722#[derive(Copy, Clone, Eq, PartialEq)]
723pub struct Lsmrwdis_SPEC;
724impl crate::sealed::RegSpec for Lsmrwdis_SPEC {
725    type DataType = u16;
726}
727
728#[doc = "Low Speed Module R/W Disable Control Register"]
729pub type Lsmrwdis = crate::RegValueT<Lsmrwdis_SPEC>;
730
731impl Lsmrwdis {
732    #[doc = "RTC Register R/W Enable Control"]
733    #[inline(always)]
734    pub fn rtcrwdis(
735        self,
736    ) -> crate::common::RegisterField<
737        0,
738        0x1,
739        1,
740        0,
741        lsmrwdis::Rtcrwdis,
742        lsmrwdis::Rtcrwdis,
743        Lsmrwdis_SPEC,
744        crate::common::RW,
745    > {
746        crate::common::RegisterField::<
747            0,
748            0x1,
749            1,
750            0,
751            lsmrwdis::Rtcrwdis,
752            lsmrwdis::Rtcrwdis,
753            Lsmrwdis_SPEC,
754            crate::common::RW,
755        >::from_register(self, 0)
756    }
757
758    #[doc = "WDT Operate Clock Control"]
759    #[inline(always)]
760    pub fn wdtdis(
761        self,
762    ) -> crate::common::RegisterField<
763        1,
764        0x1,
765        1,
766        0,
767        lsmrwdis::Wdtdis,
768        lsmrwdis::Wdtdis,
769        Lsmrwdis_SPEC,
770        crate::common::RW,
771    > {
772        crate::common::RegisterField::<
773            1,
774            0x1,
775            1,
776            0,
777            lsmrwdis::Wdtdis,
778            lsmrwdis::Wdtdis,
779            Lsmrwdis_SPEC,
780            crate::common::RW,
781        >::from_register(self, 0)
782    }
783
784    #[doc = "IWDT Register Clock Control"]
785    #[inline(always)]
786    pub fn iwdtids(
787        self,
788    ) -> crate::common::RegisterField<
789        2,
790        0x1,
791        1,
792        0,
793        lsmrwdis::Iwdtids,
794        lsmrwdis::Iwdtids,
795        Lsmrwdis_SPEC,
796        crate::common::RW,
797    > {
798        crate::common::RegisterField::<
799            2,
800            0x1,
801            1,
802            0,
803            lsmrwdis::Iwdtids,
804            lsmrwdis::Iwdtids,
805            Lsmrwdis_SPEC,
806            crate::common::RW,
807        >::from_register(self, 0)
808    }
809
810    #[doc = "Write Enable for bits \\[2:0\\]"]
811    #[inline(always)]
812    pub fn wren(
813        self,
814    ) -> crate::common::RegisterField<
815        7,
816        0x1,
817        1,
818        0,
819        lsmrwdis::Wren,
820        lsmrwdis::Wren,
821        Lsmrwdis_SPEC,
822        crate::common::RW,
823    > {
824        crate::common::RegisterField::<
825            7,
826            0x1,
827            1,
828            0,
829            lsmrwdis::Wren,
830            lsmrwdis::Wren,
831            Lsmrwdis_SPEC,
832            crate::common::RW,
833        >::from_register(self, 0)
834    }
835
836    #[doc = "LSMRWDIS Key Code"]
837    #[inline(always)]
838    pub fn prkey(
839        self,
840    ) -> crate::common::RegisterField<8, 0xff, 1, 0, u8, u8, Lsmrwdis_SPEC, crate::common::W> {
841        crate::common::RegisterField::<8,0xff,1,0,u8,u8,Lsmrwdis_SPEC,crate::common::W>::from_register(self,0)
842    }
843}
844impl ::core::default::Default for Lsmrwdis {
845    #[inline(always)]
846    fn default() -> Lsmrwdis {
847        <crate::RegValueT<Lsmrwdis_SPEC> as RegisterValue<_>>::new(0)
848    }
849}
850pub mod lsmrwdis {
851
852    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
853    pub struct Rtcrwdis_SPEC;
854    pub type Rtcrwdis = crate::EnumBitfieldStruct<u8, Rtcrwdis_SPEC>;
855    impl Rtcrwdis {
856        #[doc = "RTC register R/W clock always on"]
857        pub const _0: Self = Self::new(0);
858
859        #[doc = "RTC register R/W clock stops"]
860        pub const _1: Self = Self::new(1);
861    }
862    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
863    pub struct Wdtdis_SPEC;
864    pub type Wdtdis = crate::EnumBitfieldStruct<u8, Wdtdis_SPEC>;
865    impl Wdtdis {
866        #[doc = "WDT operates as normal"]
867        pub const _0: Self = Self::new(0);
868
869        #[doc = "Stop the WDT clock and register R/W clock"]
870        pub const _1: Self = Self::new(1);
871    }
872    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
873    pub struct Iwdtids_SPEC;
874    pub type Iwdtids = crate::EnumBitfieldStruct<u8, Iwdtids_SPEC>;
875    impl Iwdtids {
876        #[doc = "IWDT operates as normal"]
877        pub const _0: Self = Self::new(0);
878
879        #[doc = "Stop the IWDT register R/W clock"]
880        pub const _1: Self = Self::new(1);
881    }
882    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
883    pub struct Wren_SPEC;
884    pub type Wren = crate::EnumBitfieldStruct<u8, Wren_SPEC>;
885    impl Wren {
886        #[doc = "Write protect for bits \\[2:0\\]"]
887        pub const _0: Self = Self::new(0);
888
889        #[doc = "Write enable for bits \\[2:0\\]"]
890        pub const _1: Self = Self::new(1);
891    }
892}