Skip to main content

ra2a1_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.1, with svd2pac 0.6.1 on Sun, 15 Mar 2026 07:00:31 +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(hidden)]
74#[derive(Copy, Clone, Eq, PartialEq)]
75pub struct Mstpcrb_SPEC;
76impl crate::sealed::RegSpec for Mstpcrb_SPEC {
77    type DataType = u32;
78}
79
80#[doc = "Module Stop Control Register B"]
81pub type Mstpcrb = crate::RegValueT<Mstpcrb_SPEC>;
82
83impl Mstpcrb {
84    #[doc = "Serial Communication Interface 0 Module Stop"]
85    #[inline(always)]
86    pub fn mstpb31(
87        self,
88    ) -> crate::common::RegisterField<
89        31,
90        0x1,
91        1,
92        0,
93        mstpcrb::Mstpb31,
94        mstpcrb::Mstpb31,
95        Mstpcrb_SPEC,
96        crate::common::RW,
97    > {
98        crate::common::RegisterField::<
99            31,
100            0x1,
101            1,
102            0,
103            mstpcrb::Mstpb31,
104            mstpcrb::Mstpb31,
105            Mstpcrb_SPEC,
106            crate::common::RW,
107        >::from_register(self, 0)
108    }
109
110    #[doc = "Serial Communication Interface 1 Module Stop"]
111    #[inline(always)]
112    pub fn mstpb30(
113        self,
114    ) -> crate::common::RegisterField<
115        30,
116        0x1,
117        1,
118        0,
119        mstpcrb::Mstpb30,
120        mstpcrb::Mstpb30,
121        Mstpcrb_SPEC,
122        crate::common::RW,
123    > {
124        crate::common::RegisterField::<
125            30,
126            0x1,
127            1,
128            0,
129            mstpcrb::Mstpb30,
130            mstpcrb::Mstpb30,
131            Mstpcrb_SPEC,
132            crate::common::RW,
133        >::from_register(self, 0)
134    }
135
136    #[doc = "Serial Communication Interface 9 Module Stop"]
137    #[inline(always)]
138    pub fn mstpb22(
139        self,
140    ) -> crate::common::RegisterField<
141        22,
142        0x1,
143        1,
144        0,
145        mstpcrb::Mstpb22,
146        mstpcrb::Mstpb22,
147        Mstpcrb_SPEC,
148        crate::common::RW,
149    > {
150        crate::common::RegisterField::<
151            22,
152            0x1,
153            1,
154            0,
155            mstpcrb::Mstpb22,
156            mstpcrb::Mstpb22,
157            Mstpcrb_SPEC,
158            crate::common::RW,
159        >::from_register(self, 0)
160    }
161
162    #[doc = "Serial Peripheral Interface 0 Module Stop"]
163    #[inline(always)]
164    pub fn mstpb19(
165        self,
166    ) -> crate::common::RegisterField<
167        19,
168        0x1,
169        1,
170        0,
171        mstpcrb::Mstpb19,
172        mstpcrb::Mstpb19,
173        Mstpcrb_SPEC,
174        crate::common::RW,
175    > {
176        crate::common::RegisterField::<
177            19,
178            0x1,
179            1,
180            0,
181            mstpcrb::Mstpb19,
182            mstpcrb::Mstpb19,
183            Mstpcrb_SPEC,
184            crate::common::RW,
185        >::from_register(self, 0)
186    }
187
188    #[doc = "Serial Peripheral Interface 1 Module Stop"]
189    #[inline(always)]
190    pub fn mstpb18(
191        self,
192    ) -> crate::common::RegisterField<
193        18,
194        0x1,
195        1,
196        0,
197        mstpcrb::Mstpb18,
198        mstpcrb::Mstpb18,
199        Mstpcrb_SPEC,
200        crate::common::RW,
201    > {
202        crate::common::RegisterField::<
203            18,
204            0x1,
205            1,
206            0,
207            mstpcrb::Mstpb18,
208            mstpcrb::Mstpb18,
209            Mstpcrb_SPEC,
210            crate::common::RW,
211        >::from_register(self, 0)
212    }
213
214    #[doc = "Universal Serial Bus 2.0 FS Interface Module Stop"]
215    #[inline(always)]
216    pub fn mstpb11(
217        self,
218    ) -> crate::common::RegisterField<
219        11,
220        0x1,
221        1,
222        0,
223        mstpcrb::Mstpb11,
224        mstpcrb::Mstpb11,
225        Mstpcrb_SPEC,
226        crate::common::RW,
227    > {
228        crate::common::RegisterField::<
229            11,
230            0x1,
231            1,
232            0,
233            mstpcrb::Mstpb11,
234            mstpcrb::Mstpb11,
235            Mstpcrb_SPEC,
236            crate::common::RW,
237        >::from_register(self, 0)
238    }
239
240    #[doc = "I2C Bus Interface 0 Module Stop"]
241    #[inline(always)]
242    pub fn mstpb9(
243        self,
244    ) -> crate::common::RegisterField<
245        9,
246        0x1,
247        1,
248        0,
249        mstpcrb::Mstpb9,
250        mstpcrb::Mstpb9,
251        Mstpcrb_SPEC,
252        crate::common::RW,
253    > {
254        crate::common::RegisterField::<
255            9,
256            0x1,
257            1,
258            0,
259            mstpcrb::Mstpb9,
260            mstpcrb::Mstpb9,
261            Mstpcrb_SPEC,
262            crate::common::RW,
263        >::from_register(self, 0)
264    }
265
266    #[doc = "I2C Bus Interface 1 Module Stop"]
267    #[inline(always)]
268    pub fn mstpb8(
269        self,
270    ) -> crate::common::RegisterField<
271        8,
272        0x1,
273        1,
274        0,
275        mstpcrb::Mstpb8,
276        mstpcrb::Mstpb8,
277        Mstpcrb_SPEC,
278        crate::common::RW,
279    > {
280        crate::common::RegisterField::<
281            8,
282            0x1,
283            1,
284            0,
285            mstpcrb::Mstpb8,
286            mstpcrb::Mstpb8,
287            Mstpcrb_SPEC,
288            crate::common::RW,
289        >::from_register(self, 0)
290    }
291
292    #[doc = "CAN0 Module Stop"]
293    #[inline(always)]
294    pub fn mstpb2(
295        self,
296    ) -> crate::common::RegisterField<
297        2,
298        0x1,
299        1,
300        0,
301        mstpcrb::Mstpb2,
302        mstpcrb::Mstpb2,
303        Mstpcrb_SPEC,
304        crate::common::RW,
305    > {
306        crate::common::RegisterField::<
307            2,
308            0x1,
309            1,
310            0,
311            mstpcrb::Mstpb2,
312            mstpcrb::Mstpb2,
313            Mstpcrb_SPEC,
314            crate::common::RW,
315        >::from_register(self, 0)
316    }
317
318    #[doc = "These bits are read as 11. The write value should be 11."]
319    #[inline(always)]
320    pub fn reserved(
321        self,
322    ) -> crate::common::RegisterField<0, 0x3, 1, 0, u8, u8, Mstpcrb_SPEC, crate::common::RW> {
323        crate::common::RegisterField::<0,0x3,1,0,u8,u8,Mstpcrb_SPEC,crate::common::RW>::from_register(self,0)
324    }
325}
326impl ::core::default::Default for Mstpcrb {
327    #[inline(always)]
328    fn default() -> Mstpcrb {
329        <crate::RegValueT<Mstpcrb_SPEC> as RegisterValue<_>>::new(4294967295)
330    }
331}
332pub mod mstpcrb {
333
334    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
335    pub struct Mstpb31_SPEC;
336    pub type Mstpb31 = crate::EnumBitfieldStruct<u8, Mstpb31_SPEC>;
337    impl Mstpb31 {
338        #[doc = "Cancel the module-stop state"]
339        pub const _0: Self = Self::new(0);
340
341        #[doc = "Enter the module-stop state"]
342        pub const _1: Self = Self::new(1);
343    }
344    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
345    pub struct Mstpb30_SPEC;
346    pub type Mstpb30 = crate::EnumBitfieldStruct<u8, Mstpb30_SPEC>;
347    impl Mstpb30 {
348        #[doc = "Cancel the module-stop state"]
349        pub const _0: Self = Self::new(0);
350
351        #[doc = "Enter the module-stop state"]
352        pub const _1: Self = Self::new(1);
353    }
354    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
355    pub struct Mstpb22_SPEC;
356    pub type Mstpb22 = crate::EnumBitfieldStruct<u8, Mstpb22_SPEC>;
357    impl Mstpb22 {
358        #[doc = "Cancel the module-stop state"]
359        pub const _0: Self = Self::new(0);
360
361        #[doc = "Enter the module-stop state"]
362        pub const _1: Self = Self::new(1);
363    }
364    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
365    pub struct Mstpb19_SPEC;
366    pub type Mstpb19 = crate::EnumBitfieldStruct<u8, Mstpb19_SPEC>;
367    impl Mstpb19 {
368        #[doc = "Cancel the module-stop state"]
369        pub const _0: Self = Self::new(0);
370
371        #[doc = "Enter the module-stop state"]
372        pub const _1: Self = Self::new(1);
373    }
374    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
375    pub struct Mstpb18_SPEC;
376    pub type Mstpb18 = crate::EnumBitfieldStruct<u8, Mstpb18_SPEC>;
377    impl Mstpb18 {
378        #[doc = "Cancel the module-stop state"]
379        pub const _0: Self = Self::new(0);
380
381        #[doc = "Enter the module-stop state"]
382        pub const _1: Self = Self::new(1);
383    }
384    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
385    pub struct Mstpb11_SPEC;
386    pub type Mstpb11 = crate::EnumBitfieldStruct<u8, Mstpb11_SPEC>;
387    impl Mstpb11 {
388        #[doc = "Cancel the module-stop state"]
389        pub const _0: Self = Self::new(0);
390
391        #[doc = "Enter the module-stop state"]
392        pub const _1: Self = Self::new(1);
393    }
394    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
395    pub struct Mstpb9_SPEC;
396    pub type Mstpb9 = crate::EnumBitfieldStruct<u8, Mstpb9_SPEC>;
397    impl Mstpb9 {
398        #[doc = "Cancel the module-stop state"]
399        pub const _0: Self = Self::new(0);
400
401        #[doc = "Enter the module-stop state"]
402        pub const _1: Self = Self::new(1);
403    }
404    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
405    pub struct Mstpb8_SPEC;
406    pub type Mstpb8 = crate::EnumBitfieldStruct<u8, Mstpb8_SPEC>;
407    impl Mstpb8 {
408        #[doc = "Cancel the module-stop state"]
409        pub const _0: Self = Self::new(0);
410
411        #[doc = "Enter the module-stop state"]
412        pub const _1: Self = Self::new(1);
413    }
414    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
415    pub struct Mstpb2_SPEC;
416    pub type Mstpb2 = crate::EnumBitfieldStruct<u8, Mstpb2_SPEC>;
417    impl Mstpb2 {
418        #[doc = "Cancel the module-stop state"]
419        pub const _0: Self = Self::new(0);
420
421        #[doc = "Enter the module-stop state"]
422        pub const _1: Self = Self::new(1);
423    }
424}
425#[doc(hidden)]
426#[derive(Copy, Clone, Eq, PartialEq)]
427pub struct Mstpcrc_SPEC;
428impl crate::sealed::RegSpec for Mstpcrc_SPEC {
429    type DataType = u32;
430}
431
432#[doc = "Module Stop Control Register C"]
433pub type Mstpcrc = crate::RegValueT<Mstpcrc_SPEC>;
434
435impl Mstpcrc {
436    #[doc = "AES Module Stop"]
437    #[inline(always)]
438    pub fn mstpc31(
439        self,
440    ) -> crate::common::RegisterField<
441        31,
442        0x1,
443        1,
444        0,
445        mstpcrc::Mstpc31,
446        mstpcrc::Mstpc31,
447        Mstpcrc_SPEC,
448        crate::common::RW,
449    > {
450        crate::common::RegisterField::<
451            31,
452            0x1,
453            1,
454            0,
455            mstpcrc::Mstpc31,
456            mstpcrc::Mstpc31,
457            Mstpcrc_SPEC,
458            crate::common::RW,
459        >::from_register(self, 0)
460    }
461
462    #[doc = "Random Number Generator Module Stop"]
463    #[inline(always)]
464    pub fn mstpc28(
465        self,
466    ) -> crate::common::RegisterField<
467        28,
468        0x1,
469        1,
470        0,
471        mstpcrc::Mstpc28,
472        mstpcrc::Mstpc28,
473        Mstpcrc_SPEC,
474        crate::common::RW,
475    > {
476        crate::common::RegisterField::<
477            28,
478            0x1,
479            1,
480            0,
481            mstpcrc::Mstpc28,
482            mstpcrc::Mstpc28,
483            Mstpcrc_SPEC,
484            crate::common::RW,
485        >::from_register(self, 0)
486    }
487
488    #[doc = "Event Link Controller Module Stop"]
489    #[inline(always)]
490    pub fn mstpc14(
491        self,
492    ) -> crate::common::RegisterField<
493        14,
494        0x1,
495        1,
496        0,
497        mstpcrc::Mstpc14,
498        mstpcrc::Mstpc14,
499        Mstpcrc_SPEC,
500        crate::common::RW,
501    > {
502        crate::common::RegisterField::<
503            14,
504            0x1,
505            1,
506            0,
507            mstpcrc::Mstpc14,
508            mstpcrc::Mstpc14,
509            Mstpcrc_SPEC,
510            crate::common::RW,
511        >::from_register(self, 0)
512    }
513
514    #[doc = "Data Operation Circuit Module Stop"]
515    #[inline(always)]
516    pub fn mstpc13(
517        self,
518    ) -> crate::common::RegisterField<
519        13,
520        0x1,
521        1,
522        0,
523        mstpcrc::Mstpc13,
524        mstpcrc::Mstpc13,
525        Mstpcrc_SPEC,
526        crate::common::RW,
527    > {
528        crate::common::RegisterField::<
529            13,
530            0x1,
531            1,
532            0,
533            mstpcrc::Mstpc13,
534            mstpcrc::Mstpc13,
535            Mstpcrc_SPEC,
536            crate::common::RW,
537        >::from_register(self, 0)
538    }
539
540    #[doc = "Capacitive Touch Sensing Unit Module Stop"]
541    #[inline(always)]
542    pub fn mstpc3(
543        self,
544    ) -> crate::common::RegisterField<
545        3,
546        0x1,
547        1,
548        0,
549        mstpcrc::Mstpc3,
550        mstpcrc::Mstpc3,
551        Mstpcrc_SPEC,
552        crate::common::RW,
553    > {
554        crate::common::RegisterField::<
555            3,
556            0x1,
557            1,
558            0,
559            mstpcrc::Mstpc3,
560            mstpcrc::Mstpc3,
561            Mstpcrc_SPEC,
562            crate::common::RW,
563        >::from_register(self, 0)
564    }
565
566    #[doc = "This bit is read as 1. The write value should be 1."]
567    #[inline(always)]
568    pub fn reserved(
569        self,
570    ) -> crate::common::RegisterFieldBool<2, 1, 0, Mstpcrc_SPEC, crate::common::RW> {
571        crate::common::RegisterFieldBool::<2, 1, 0, Mstpcrc_SPEC, crate::common::RW>::from_register(
572            self, 0,
573        )
574    }
575
576    #[doc = "CRC Calculator Module Stop"]
577    #[inline(always)]
578    pub fn mstpc1(
579        self,
580    ) -> crate::common::RegisterField<
581        1,
582        0x1,
583        1,
584        0,
585        mstpcrc::Mstpc1,
586        mstpcrc::Mstpc1,
587        Mstpcrc_SPEC,
588        crate::common::RW,
589    > {
590        crate::common::RegisterField::<
591            1,
592            0x1,
593            1,
594            0,
595            mstpcrc::Mstpc1,
596            mstpcrc::Mstpc1,
597            Mstpcrc_SPEC,
598            crate::common::RW,
599        >::from_register(self, 0)
600    }
601
602    #[doc = "CAC Module Stop"]
603    #[inline(always)]
604    pub fn mstpc0(
605        self,
606    ) -> crate::common::RegisterField<
607        0,
608        0x1,
609        1,
610        0,
611        mstpcrc::Mstpc0,
612        mstpcrc::Mstpc0,
613        Mstpcrc_SPEC,
614        crate::common::RW,
615    > {
616        crate::common::RegisterField::<
617            0,
618            0x1,
619            1,
620            0,
621            mstpcrc::Mstpc0,
622            mstpcrc::Mstpc0,
623            Mstpcrc_SPEC,
624            crate::common::RW,
625        >::from_register(self, 0)
626    }
627}
628impl ::core::default::Default for Mstpcrc {
629    #[inline(always)]
630    fn default() -> Mstpcrc {
631        <crate::RegValueT<Mstpcrc_SPEC> as RegisterValue<_>>::new(4294967295)
632    }
633}
634pub mod mstpcrc {
635
636    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
637    pub struct Mstpc31_SPEC;
638    pub type Mstpc31 = crate::EnumBitfieldStruct<u8, Mstpc31_SPEC>;
639    impl Mstpc31 {
640        #[doc = "Cancel the module-stop state"]
641        pub const _0: Self = Self::new(0);
642
643        #[doc = "Enter the module-stop state"]
644        pub const _1: Self = Self::new(1);
645    }
646    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
647    pub struct Mstpc28_SPEC;
648    pub type Mstpc28 = crate::EnumBitfieldStruct<u8, Mstpc28_SPEC>;
649    impl Mstpc28 {
650        #[doc = "Cancel the module-stop state"]
651        pub const _0: Self = Self::new(0);
652
653        #[doc = "Enter the module-stop state."]
654        pub const _1: Self = Self::new(1);
655    }
656    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
657    pub struct Mstpc14_SPEC;
658    pub type Mstpc14 = crate::EnumBitfieldStruct<u8, Mstpc14_SPEC>;
659    impl Mstpc14 {
660        #[doc = "Cancel the module-stop state"]
661        pub const _0: Self = Self::new(0);
662
663        #[doc = "Enter the module-stop state"]
664        pub const _1: Self = Self::new(1);
665    }
666    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
667    pub struct Mstpc13_SPEC;
668    pub type Mstpc13 = crate::EnumBitfieldStruct<u8, Mstpc13_SPEC>;
669    impl Mstpc13 {
670        #[doc = "Cancel the module-stop state"]
671        pub const _0: Self = Self::new(0);
672
673        #[doc = "Enter the module-stop state"]
674        pub const _1: Self = Self::new(1);
675    }
676    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
677    pub struct Mstpc3_SPEC;
678    pub type Mstpc3 = crate::EnumBitfieldStruct<u8, Mstpc3_SPEC>;
679    impl Mstpc3 {
680        #[doc = "Cancel the module-stop state"]
681        pub const _0: Self = Self::new(0);
682
683        #[doc = "Enter the module-stop state"]
684        pub const _1: Self = Self::new(1);
685    }
686    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
687    pub struct Mstpc1_SPEC;
688    pub type Mstpc1 = crate::EnumBitfieldStruct<u8, Mstpc1_SPEC>;
689    impl Mstpc1 {
690        #[doc = "Cancel the module-stop state"]
691        pub const _0: Self = Self::new(0);
692
693        #[doc = "Enter the module-stop state"]
694        pub const _1: Self = Self::new(1);
695    }
696    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
697    pub struct Mstpc0_SPEC;
698    pub type Mstpc0 = crate::EnumBitfieldStruct<u8, Mstpc0_SPEC>;
699    impl Mstpc0 {
700        #[doc = "Cancel the module-stop state"]
701        pub const _0: Self = Self::new(0);
702
703        #[doc = "Enter the module-stop state"]
704        pub const _1: Self = Self::new(1);
705    }
706}
707#[doc(hidden)]
708#[derive(Copy, Clone, Eq, PartialEq)]
709pub struct Mstpcrd_SPEC;
710impl crate::sealed::RegSpec for Mstpcrd_SPEC {
711    type DataType = u32;
712}
713
714#[doc = "Module Stop Control Register D"]
715pub type Mstpcrd = crate::RegValueT<Mstpcrd_SPEC>;
716
717impl Mstpcrd {
718    #[doc = "Operational Amplifier Module Stop"]
719    #[inline(always)]
720    pub fn mstpd31(
721        self,
722    ) -> crate::common::RegisterField<
723        31,
724        0x1,
725        1,
726        0,
727        mstpcrd::Mstpd31,
728        mstpcrd::Mstpd31,
729        Mstpcrd_SPEC,
730        crate::common::RW,
731    > {
732        crate::common::RegisterField::<
733            31,
734            0x1,
735            1,
736            0,
737            mstpcrd::Mstpd31,
738            mstpcrd::Mstpd31,
739            Mstpcrd_SPEC,
740            crate::common::RW,
741        >::from_register(self, 0)
742    }
743
744    #[doc = "Comparator-LP Module Stop"]
745    #[inline(always)]
746    pub fn mstpd29(
747        self,
748    ) -> crate::common::RegisterField<
749        29,
750        0x1,
751        1,
752        0,
753        mstpcrd::Mstpd29,
754        mstpcrd::Mstpd29,
755        Mstpcrd_SPEC,
756        crate::common::RW,
757    > {
758        crate::common::RegisterField::<
759            29,
760            0x1,
761            1,
762            0,
763            mstpcrd::Mstpd29,
764            mstpcrd::Mstpd29,
765            Mstpcrd_SPEC,
766            crate::common::RW,
767        >::from_register(self, 0)
768    }
769
770    #[doc = "ACMPHS0 Module Stop"]
771    #[inline(always)]
772    pub fn mstpd28(
773        self,
774    ) -> crate::common::RegisterField<
775        28,
776        0x1,
777        1,
778        0,
779        mstpcrd::Mstpd28,
780        mstpcrd::Mstpd28,
781        Mstpcrd_SPEC,
782        crate::common::RW,
783    > {
784        crate::common::RegisterField::<
785            28,
786            0x1,
787            1,
788            0,
789            mstpcrd::Mstpd28,
790            mstpcrd::Mstpd28,
791            Mstpcrd_SPEC,
792            crate::common::RW,
793        >::from_register(self, 0)
794    }
795
796    #[doc = "12-bit D/A Converter Module Stop"]
797    #[inline(always)]
798    pub fn mstpd20(
799        self,
800    ) -> crate::common::RegisterField<
801        20,
802        0x1,
803        1,
804        0,
805        mstpcrd::Mstpd20,
806        mstpcrd::Mstpd20,
807        Mstpcrd_SPEC,
808        crate::common::RW,
809    > {
810        crate::common::RegisterField::<
811            20,
812            0x1,
813            1,
814            0,
815            mstpcrd::Mstpd20,
816            mstpcrd::Mstpd20,
817            Mstpcrd_SPEC,
818            crate::common::RW,
819        >::from_register(self, 0)
820    }
821
822    #[doc = "8-Bit D/A Converter Module Stop"]
823    #[inline(always)]
824    pub fn mstpd19(
825        self,
826    ) -> crate::common::RegisterField<
827        19,
828        0x1,
829        1,
830        0,
831        mstpcrd::Mstpd19,
832        mstpcrd::Mstpd19,
833        Mstpcrd_SPEC,
834        crate::common::RW,
835    > {
836        crate::common::RegisterField::<
837            19,
838            0x1,
839            1,
840            0,
841            mstpcrd::Mstpd19,
842            mstpcrd::Mstpd19,
843            Mstpcrd_SPEC,
844            crate::common::RW,
845        >::from_register(self, 0)
846    }
847
848    #[doc = "24-bit Sigma-Delta A/DConverter Module Stop"]
849    #[inline(always)]
850    pub fn mstpd17(
851        self,
852    ) -> crate::common::RegisterField<
853        17,
854        0x1,
855        1,
856        0,
857        mstpcrd::Mstpd17,
858        mstpcrd::Mstpd17,
859        Mstpcrd_SPEC,
860        crate::common::RW,
861    > {
862        crate::common::RegisterField::<
863            17,
864            0x1,
865            1,
866            0,
867            mstpcrd::Mstpd17,
868            mstpcrd::Mstpd17,
869            Mstpcrd_SPEC,
870            crate::common::RW,
871        >::from_register(self, 0)
872    }
873
874    #[doc = "16-Bit A/D Converter Module Stop"]
875    #[inline(always)]
876    pub fn mstpd16(
877        self,
878    ) -> crate::common::RegisterField<
879        16,
880        0x1,
881        1,
882        0,
883        mstpcrd::Mstpd16,
884        mstpcrd::Mstpd16,
885        Mstpcrd_SPEC,
886        crate::common::RW,
887    > {
888        crate::common::RegisterField::<
889            16,
890            0x1,
891            1,
892            0,
893            mstpcrd::Mstpd16,
894            mstpcrd::Mstpd16,
895            Mstpcrd_SPEC,
896            crate::common::RW,
897        >::from_register(self, 0)
898    }
899
900    #[doc = "POEG Module Stop"]
901    #[inline(always)]
902    pub fn mstpd14(
903        self,
904    ) -> crate::common::RegisterField<
905        14,
906        0x1,
907        1,
908        0,
909        mstpcrd::Mstpd14,
910        mstpcrd::Mstpd14,
911        Mstpcrd_SPEC,
912        crate::common::RW,
913    > {
914        crate::common::RegisterField::<
915            14,
916            0x1,
917            1,
918            0,
919            mstpcrd::Mstpd14,
920            mstpcrd::Mstpd14,
921            Mstpcrd_SPEC,
922            crate::common::RW,
923        >::from_register(self, 0)
924    }
925
926    #[doc = "GPT ch6 - ch1 Module Stop"]
927    #[inline(always)]
928    pub fn mstpd6(
929        self,
930    ) -> crate::common::RegisterField<
931        6,
932        0x1,
933        1,
934        0,
935        mstpcrd::Mstpd6,
936        mstpcrd::Mstpd6,
937        Mstpcrd_SPEC,
938        crate::common::RW,
939    > {
940        crate::common::RegisterField::<
941            6,
942            0x1,
943            1,
944            0,
945            mstpcrd::Mstpd6,
946            mstpcrd::Mstpd6,
947            Mstpcrd_SPEC,
948            crate::common::RW,
949        >::from_register(self, 0)
950    }
951
952    #[doc = "GPT ch0 Module Stop"]
953    #[inline(always)]
954    pub fn mstpd5(
955        self,
956    ) -> crate::common::RegisterField<
957        5,
958        0x1,
959        1,
960        0,
961        mstpcrd::Mstpd5,
962        mstpcrd::Mstpd5,
963        Mstpcrd_SPEC,
964        crate::common::RW,
965    > {
966        crate::common::RegisterField::<
967            5,
968            0x1,
969            1,
970            0,
971            mstpcrd::Mstpd5,
972            mstpcrd::Mstpd5,
973            Mstpcrd_SPEC,
974            crate::common::RW,
975        >::from_register(self, 0)
976    }
977
978    #[doc = "AGT0 Module StopNote: AGT0 is in the module stop state when the count source is either of PCLKB, PCLKB/2 or PCLKB/8. In case the count source is sub-clock or LOCO, this bit should be set to 1 except when accessing the registers of AGT0."]
979    #[inline(always)]
980    pub fn mstpd3(
981        self,
982    ) -> crate::common::RegisterField<
983        3,
984        0x1,
985        1,
986        0,
987        mstpcrd::Mstpd3,
988        mstpcrd::Mstpd3,
989        Mstpcrd_SPEC,
990        crate::common::RW,
991    > {
992        crate::common::RegisterField::<
993            3,
994            0x1,
995            1,
996            0,
997            mstpcrd::Mstpd3,
998            mstpcrd::Mstpd3,
999            Mstpcrd_SPEC,
1000            crate::common::RW,
1001        >::from_register(self, 0)
1002    }
1003
1004    #[doc = "AGT1 Module StopNote: AGT1 is in the module stop state when the count source is either of PCLKB, PCLKB/2 or PCLKB/8. In case the count source is sub-clock or LOCO, this bit should be set to 1 except when accessing the registers of AGT1."]
1005    #[inline(always)]
1006    pub fn mstpd2(
1007        self,
1008    ) -> crate::common::RegisterField<
1009        2,
1010        0x1,
1011        1,
1012        0,
1013        mstpcrd::Mstpd2,
1014        mstpcrd::Mstpd2,
1015        Mstpcrd_SPEC,
1016        crate::common::RW,
1017    > {
1018        crate::common::RegisterField::<
1019            2,
1020            0x1,
1021            1,
1022            0,
1023            mstpcrd::Mstpd2,
1024            mstpcrd::Mstpd2,
1025            Mstpcrd_SPEC,
1026            crate::common::RW,
1027        >::from_register(self, 0)
1028    }
1029
1030    #[doc = "These bits are read as 11. The write value should be 11."]
1031    #[inline(always)]
1032    pub fn reserved(
1033        self,
1034    ) -> crate::common::RegisterField<0, 0x3, 1, 0, u8, u8, Mstpcrd_SPEC, crate::common::RW> {
1035        crate::common::RegisterField::<0,0x3,1,0,u8,u8,Mstpcrd_SPEC,crate::common::RW>::from_register(self,0)
1036    }
1037}
1038impl ::core::default::Default for Mstpcrd {
1039    #[inline(always)]
1040    fn default() -> Mstpcrd {
1041        <crate::RegValueT<Mstpcrd_SPEC> as RegisterValue<_>>::new(4294967295)
1042    }
1043}
1044pub mod mstpcrd {
1045
1046    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1047    pub struct Mstpd31_SPEC;
1048    pub type Mstpd31 = crate::EnumBitfieldStruct<u8, Mstpd31_SPEC>;
1049    impl Mstpd31 {
1050        #[doc = "Cancel the module-stop state"]
1051        pub const _0: Self = Self::new(0);
1052
1053        #[doc = "Enter the module-stop state"]
1054        pub const _1: Self = Self::new(1);
1055    }
1056    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1057    pub struct Mstpd29_SPEC;
1058    pub type Mstpd29 = crate::EnumBitfieldStruct<u8, Mstpd29_SPEC>;
1059    impl Mstpd29 {
1060        #[doc = "Cancel the module-stop state"]
1061        pub const _0: Self = Self::new(0);
1062
1063        #[doc = "Enter the module-stop state"]
1064        pub const _1: Self = Self::new(1);
1065    }
1066    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1067    pub struct Mstpd28_SPEC;
1068    pub type Mstpd28 = crate::EnumBitfieldStruct<u8, Mstpd28_SPEC>;
1069    impl Mstpd28 {
1070        #[doc = "Cancel the module-stop state"]
1071        pub const _0: Self = Self::new(0);
1072
1073        #[doc = "Enter the module-stop state"]
1074        pub const _1: Self = Self::new(1);
1075    }
1076    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1077    pub struct Mstpd20_SPEC;
1078    pub type Mstpd20 = crate::EnumBitfieldStruct<u8, Mstpd20_SPEC>;
1079    impl Mstpd20 {
1080        #[doc = "Cancel the module-stop state"]
1081        pub const _0: Self = Self::new(0);
1082
1083        #[doc = "Enter the module-stop state"]
1084        pub const _1: Self = Self::new(1);
1085    }
1086    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1087    pub struct Mstpd19_SPEC;
1088    pub type Mstpd19 = crate::EnumBitfieldStruct<u8, Mstpd19_SPEC>;
1089    impl Mstpd19 {
1090        #[doc = "Cancel the module-stop state"]
1091        pub const _0: Self = Self::new(0);
1092
1093        #[doc = "Enter the module-stop state"]
1094        pub const _1: Self = Self::new(1);
1095    }
1096    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1097    pub struct Mstpd17_SPEC;
1098    pub type Mstpd17 = crate::EnumBitfieldStruct<u8, Mstpd17_SPEC>;
1099    impl Mstpd17 {
1100        #[doc = "Cancel the module-stop state"]
1101        pub const _0: Self = Self::new(0);
1102
1103        #[doc = "Enter the module-stop state"]
1104        pub const _1: Self = Self::new(1);
1105    }
1106    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1107    pub struct Mstpd16_SPEC;
1108    pub type Mstpd16 = crate::EnumBitfieldStruct<u8, Mstpd16_SPEC>;
1109    impl Mstpd16 {
1110        #[doc = "Cancel the module-stop state"]
1111        pub const _0: Self = Self::new(0);
1112
1113        #[doc = "Enter the module-stop state"]
1114        pub const _1: Self = Self::new(1);
1115    }
1116    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1117    pub struct Mstpd14_SPEC;
1118    pub type Mstpd14 = crate::EnumBitfieldStruct<u8, Mstpd14_SPEC>;
1119    impl Mstpd14 {
1120        #[doc = "Cancel the module-stop state"]
1121        pub const _0: Self = Self::new(0);
1122
1123        #[doc = "Enter the module-stop state"]
1124        pub const _1: Self = Self::new(1);
1125    }
1126    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1127    pub struct Mstpd6_SPEC;
1128    pub type Mstpd6 = crate::EnumBitfieldStruct<u8, Mstpd6_SPEC>;
1129    impl Mstpd6 {
1130        #[doc = "Cancel the module-stop state"]
1131        pub const _0: Self = Self::new(0);
1132
1133        #[doc = "Enter the module-stop state"]
1134        pub const _1: Self = Self::new(1);
1135    }
1136    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1137    pub struct Mstpd5_SPEC;
1138    pub type Mstpd5 = crate::EnumBitfieldStruct<u8, Mstpd5_SPEC>;
1139    impl Mstpd5 {
1140        #[doc = "Cancel the module-stop state"]
1141        pub const _0: Self = Self::new(0);
1142
1143        #[doc = "Enter the module-stop state"]
1144        pub const _1: Self = Self::new(1);
1145    }
1146    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1147    pub struct Mstpd3_SPEC;
1148    pub type Mstpd3 = crate::EnumBitfieldStruct<u8, Mstpd3_SPEC>;
1149    impl Mstpd3 {
1150        #[doc = "Cancel the module-stop state"]
1151        pub const _0: Self = Self::new(0);
1152
1153        #[doc = "Enter the module-stop state"]
1154        pub const _1: Self = Self::new(1);
1155    }
1156    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1157    pub struct Mstpd2_SPEC;
1158    pub type Mstpd2 = crate::EnumBitfieldStruct<u8, Mstpd2_SPEC>;
1159    impl Mstpd2 {
1160        #[doc = "Cancel the module-stop state"]
1161        pub const _0: Self = Self::new(0);
1162
1163        #[doc = "Enter the module-stop state"]
1164        pub const _1: Self = Self::new(1);
1165    }
1166}