ra4w1/
lib.rs

1#![doc = "Peripheral access API for R7FA4W1AD microcontrollers (generated using svd2rust v0.28.0 ( ))\n\nYou can find an overview of the generated API [here].\n\nAPI features to be included in the [next]
2svd2rust release can be generated by cloning the svd2rust [repository], checking out the above commit, and running `cargo doc --open`.\n\n[here]: https://docs.rs/svd2rust/0.28.0/svd2rust/#peripheral-api\n[next]: https://github.com/rust-embedded/svd2rust/blob/master/CHANGELOG.md#unreleased\n[repository]: https://github.com/rust-embedded/svd2rust"]
3#![deny(dead_code)]
4#![deny(improper_ctypes)]
5#![deny(missing_docs)]
6#![deny(no_mangle_generic_items)]
7#![deny(non_shorthand_field_patterns)]
8#![deny(overflowing_literals)]
9#![deny(path_statements)]
10#![deny(patterns_in_fns_without_body)]
11#![deny(private_in_public)]
12#![deny(unconditional_recursion)]
13#![deny(unused_allocation)]
14#![deny(unused_comparisons)]
15#![deny(unused_parens)]
16#![deny(while_true)]
17#![allow(non_camel_case_types)]
18#![allow(non_snake_case)]
19#![no_std]
20use core::marker::PhantomData;
21use core::ops::Deref;
22#[doc = r"Number available in the NVIC for configuring priority"]
23pub const NVIC_PRIO_BITS: u8 = 4;
24#[cfg(feature = "rt")]
25pub use self::Interrupt as interrupt;
26pub use cortex_m::peripheral::Peripherals as CorePeripherals;
27pub use cortex_m::peripheral::{CBP, CPUID, DCB, DWT, FPB, FPU, ITM, MPU, NVIC, SCB, SYST, TPIU};
28#[cfg(feature = "rt")]
29pub use cortex_m_rt::interrupt;
30#[allow(unused_imports)]
31use generic::*;
32#[doc = r"Common register and bit access and modify traits"]
33pub mod generic;
34#[cfg(feature = "rt")]
35extern "C" {
36    fn IEL0();
37    fn IEL1();
38    fn IEL2();
39    fn IEL3();
40    fn IEL4();
41    fn IEL5();
42    fn IEL6();
43    fn IEL7();
44    fn IEL8();
45    fn IEL9();
46    fn IEL10();
47    fn IEL11();
48    fn IEL12();
49    fn IEL13();
50    fn IEL14();
51    fn IEL15();
52    fn IEL16();
53    fn IEL17();
54    fn IEL18();
55    fn IEL19();
56    fn IEL20();
57    fn IEL21();
58    fn IEL22();
59    fn IEL23();
60    fn IEL24();
61    fn IEL25();
62    fn IEL26();
63    fn IEL27();
64    fn IEL28();
65    fn IEL29();
66    fn IEL30();
67    fn IEL31();
68}
69#[doc(hidden)]
70pub union Vector {
71    _handler: unsafe extern "C" fn(),
72    _reserved: u32,
73}
74#[cfg(feature = "rt")]
75#[doc(hidden)]
76#[link_section = ".vector_table.interrupts"]
77#[no_mangle]
78pub static __INTERRUPTS: [Vector; 32] = [
79    Vector { _handler: IEL0 },
80    Vector { _handler: IEL1 },
81    Vector { _handler: IEL2 },
82    Vector { _handler: IEL3 },
83    Vector { _handler: IEL4 },
84    Vector { _handler: IEL5 },
85    Vector { _handler: IEL6 },
86    Vector { _handler: IEL7 },
87    Vector { _handler: IEL8 },
88    Vector { _handler: IEL9 },
89    Vector { _handler: IEL10 },
90    Vector { _handler: IEL11 },
91    Vector { _handler: IEL12 },
92    Vector { _handler: IEL13 },
93    Vector { _handler: IEL14 },
94    Vector { _handler: IEL15 },
95    Vector { _handler: IEL16 },
96    Vector { _handler: IEL17 },
97    Vector { _handler: IEL18 },
98    Vector { _handler: IEL19 },
99    Vector { _handler: IEL20 },
100    Vector { _handler: IEL21 },
101    Vector { _handler: IEL22 },
102    Vector { _handler: IEL23 },
103    Vector { _handler: IEL24 },
104    Vector { _handler: IEL25 },
105    Vector { _handler: IEL26 },
106    Vector { _handler: IEL27 },
107    Vector { _handler: IEL28 },
108    Vector { _handler: IEL29 },
109    Vector { _handler: IEL30 },
110    Vector { _handler: IEL31 },
111];
112#[doc = r"Enumeration of all the interrupts."]
113#[derive(Copy, Clone, Debug, PartialEq, Eq)]
114#[repr(u16)]
115pub enum Interrupt {
116    #[doc = "0 - ICU Interrupt 0"]
117    IEL0 = 0,
118    #[doc = "1 - ICU Interrupt 1"]
119    IEL1 = 1,
120    #[doc = "2 - ICU Interrupt 2"]
121    IEL2 = 2,
122    #[doc = "3 - ICU Interrupt 3"]
123    IEL3 = 3,
124    #[doc = "4 - ICU Interrupt 4"]
125    IEL4 = 4,
126    #[doc = "5 - ICU Interrupt 5"]
127    IEL5 = 5,
128    #[doc = "6 - ICU Interrupt 6"]
129    IEL6 = 6,
130    #[doc = "7 - ICU Interrupt 7"]
131    IEL7 = 7,
132    #[doc = "8 - ICU Interrupt 8"]
133    IEL8 = 8,
134    #[doc = "9 - ICU Interrupt 9"]
135    IEL9 = 9,
136    #[doc = "10 - ICU Interrupt 10"]
137    IEL10 = 10,
138    #[doc = "11 - ICU Interrupt 11"]
139    IEL11 = 11,
140    #[doc = "12 - ICU Interrupt 12"]
141    IEL12 = 12,
142    #[doc = "13 - ICU Interrupt 13"]
143    IEL13 = 13,
144    #[doc = "14 - ICU Interrupt 14"]
145    IEL14 = 14,
146    #[doc = "15 - ICU Interrupt 15"]
147    IEL15 = 15,
148    #[doc = "16 - ICU Interrupt 16"]
149    IEL16 = 16,
150    #[doc = "17 - ICU Interrupt 17"]
151    IEL17 = 17,
152    #[doc = "18 - ICU Interrupt 18"]
153    IEL18 = 18,
154    #[doc = "19 - ICU Interrupt 19"]
155    IEL19 = 19,
156    #[doc = "20 - ICU Interrupt 20"]
157    IEL20 = 20,
158    #[doc = "21 - ICU Interrupt 21"]
159    IEL21 = 21,
160    #[doc = "22 - ICU Interrupt 22"]
161    IEL22 = 22,
162    #[doc = "23 - ICU Interrupt 23"]
163    IEL23 = 23,
164    #[doc = "24 - ICU Interrupt 24"]
165    IEL24 = 24,
166    #[doc = "25 - ICU Interrupt 25"]
167    IEL25 = 25,
168    #[doc = "26 - ICU Interrupt 26"]
169    IEL26 = 26,
170    #[doc = "27 - ICU Interrupt 27"]
171    IEL27 = 27,
172    #[doc = "28 - ICU Interrupt 28"]
173    IEL28 = 28,
174    #[doc = "29 - ICU Interrupt 29"]
175    IEL29 = 29,
176    #[doc = "30 - ICU Interrupt 30"]
177    IEL30 = 30,
178    #[doc = "31 - ICU Interrupt 31"]
179    IEL31 = 31,
180}
181unsafe impl cortex_m::interrupt::InterruptNumber for Interrupt {
182    #[inline(always)]
183    fn number(self) -> u16 {
184        self as u16
185    }
186}
187#[doc = "Port Output Enable Module for GPT"]
188pub struct POEG {
189    _marker: PhantomData<*const ()>,
190}
191unsafe impl Send for POEG {}
192impl POEG {
193    #[doc = r"Pointer to the register block"]
194    pub const PTR: *const poeg::RegisterBlock = 0x4004_2000 as *const _;
195    #[doc = r"Return the pointer to the register block"]
196    #[inline(always)]
197    pub const fn ptr() -> *const poeg::RegisterBlock {
198        Self::PTR
199    }
200}
201impl Deref for POEG {
202    type Target = poeg::RegisterBlock;
203    #[inline(always)]
204    fn deref(&self) -> &Self::Target {
205        unsafe { &*Self::PTR }
206    }
207}
208impl core::fmt::Debug for POEG {
209    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
210        f.debug_struct("POEG").finish()
211    }
212}
213#[doc = "Port Output Enable Module for GPT"]
214pub mod poeg;
215#[doc = "General PWM Timer 0 (32-bit)"]
216pub struct GPT320 {
217    _marker: PhantomData<*const ()>,
218}
219unsafe impl Send for GPT320 {}
220impl GPT320 {
221    #[doc = r"Pointer to the register block"]
222    pub const PTR: *const gpt320::RegisterBlock = 0x4007_8000 as *const _;
223    #[doc = r"Return the pointer to the register block"]
224    #[inline(always)]
225    pub const fn ptr() -> *const gpt320::RegisterBlock {
226        Self::PTR
227    }
228}
229impl Deref for GPT320 {
230    type Target = gpt320::RegisterBlock;
231    #[inline(always)]
232    fn deref(&self) -> &Self::Target {
233        unsafe { &*Self::PTR }
234    }
235}
236impl core::fmt::Debug for GPT320 {
237    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
238        f.debug_struct("GPT320").finish()
239    }
240}
241#[doc = "General PWM Timer 0 (32-bit)"]
242pub mod gpt320;
243#[doc = "General PWM Timer 1 (32-bit)"]
244pub struct GPT321 {
245    _marker: PhantomData<*const ()>,
246}
247unsafe impl Send for GPT321 {}
248impl GPT321 {
249    #[doc = r"Pointer to the register block"]
250    pub const PTR: *const gpt320::RegisterBlock = 0x4007_8100 as *const _;
251    #[doc = r"Return the pointer to the register block"]
252    #[inline(always)]
253    pub const fn ptr() -> *const gpt320::RegisterBlock {
254        Self::PTR
255    }
256}
257impl Deref for GPT321 {
258    type Target = gpt320::RegisterBlock;
259    #[inline(always)]
260    fn deref(&self) -> &Self::Target {
261        unsafe { &*Self::PTR }
262    }
263}
264impl core::fmt::Debug for GPT321 {
265    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
266        f.debug_struct("GPT321").finish()
267    }
268}
269#[doc = "General PWM Timer 1 (32-bit)"]
270pub use self::gpt320 as gpt321;
271#[doc = "General PWM Timer 2 (32-bit)"]
272pub struct GPT322 {
273    _marker: PhantomData<*const ()>,
274}
275unsafe impl Send for GPT322 {}
276impl GPT322 {
277    #[doc = r"Pointer to the register block"]
278    pub const PTR: *const gpt320::RegisterBlock = 0x4007_8200 as *const _;
279    #[doc = r"Return the pointer to the register block"]
280    #[inline(always)]
281    pub const fn ptr() -> *const gpt320::RegisterBlock {
282        Self::PTR
283    }
284}
285impl Deref for GPT322 {
286    type Target = gpt320::RegisterBlock;
287    #[inline(always)]
288    fn deref(&self) -> &Self::Target {
289        unsafe { &*Self::PTR }
290    }
291}
292impl core::fmt::Debug for GPT322 {
293    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
294        f.debug_struct("GPT322").finish()
295    }
296}
297#[doc = "General PWM Timer 2 (32-bit)"]
298pub use self::gpt320 as gpt322;
299#[doc = "General PWM Timer 3 (32-bit)"]
300pub struct GPT323 {
301    _marker: PhantomData<*const ()>,
302}
303unsafe impl Send for GPT323 {}
304impl GPT323 {
305    #[doc = r"Pointer to the register block"]
306    pub const PTR: *const gpt320::RegisterBlock = 0x4007_8300 as *const _;
307    #[doc = r"Return the pointer to the register block"]
308    #[inline(always)]
309    pub const fn ptr() -> *const gpt320::RegisterBlock {
310        Self::PTR
311    }
312}
313impl Deref for GPT323 {
314    type Target = gpt320::RegisterBlock;
315    #[inline(always)]
316    fn deref(&self) -> &Self::Target {
317        unsafe { &*Self::PTR }
318    }
319}
320impl core::fmt::Debug for GPT323 {
321    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
322        f.debug_struct("GPT323").finish()
323    }
324}
325#[doc = "General PWM Timer 3 (32-bit)"]
326pub use self::gpt320 as gpt323;
327#[doc = "General PWM Timer 4 (16-bit)"]
328pub struct GPT164 {
329    _marker: PhantomData<*const ()>,
330}
331unsafe impl Send for GPT164 {}
332impl GPT164 {
333    #[doc = r"Pointer to the register block"]
334    pub const PTR: *const gpt164::RegisterBlock = 0x4007_8400 as *const _;
335    #[doc = r"Return the pointer to the register block"]
336    #[inline(always)]
337    pub const fn ptr() -> *const gpt164::RegisterBlock {
338        Self::PTR
339    }
340}
341impl Deref for GPT164 {
342    type Target = gpt164::RegisterBlock;
343    #[inline(always)]
344    fn deref(&self) -> &Self::Target {
345        unsafe { &*Self::PTR }
346    }
347}
348impl core::fmt::Debug for GPT164 {
349    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
350        f.debug_struct("GPT164").finish()
351    }
352}
353#[doc = "General PWM Timer 4 (16-bit)"]
354pub mod gpt164;
355#[doc = "General PWM Timer 5 (16-bit)"]
356pub struct GPT165 {
357    _marker: PhantomData<*const ()>,
358}
359unsafe impl Send for GPT165 {}
360impl GPT165 {
361    #[doc = r"Pointer to the register block"]
362    pub const PTR: *const gpt164::RegisterBlock = 0x4007_8500 as *const _;
363    #[doc = r"Return the pointer to the register block"]
364    #[inline(always)]
365    pub const fn ptr() -> *const gpt164::RegisterBlock {
366        Self::PTR
367    }
368}
369impl Deref for GPT165 {
370    type Target = gpt164::RegisterBlock;
371    #[inline(always)]
372    fn deref(&self) -> &Self::Target {
373        unsafe { &*Self::PTR }
374    }
375}
376impl core::fmt::Debug for GPT165 {
377    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
378        f.debug_struct("GPT165").finish()
379    }
380}
381#[doc = "General PWM Timer 5 (16-bit)"]
382pub use self::gpt164 as gpt165;
383#[doc = "General PWM Timer 6 (16-bit)"]
384pub struct GPT166 {
385    _marker: PhantomData<*const ()>,
386}
387unsafe impl Send for GPT166 {}
388impl GPT166 {
389    #[doc = r"Pointer to the register block"]
390    pub const PTR: *const gpt164::RegisterBlock = 0x4007_8600 as *const _;
391    #[doc = r"Return the pointer to the register block"]
392    #[inline(always)]
393    pub const fn ptr() -> *const gpt164::RegisterBlock {
394        Self::PTR
395    }
396}
397impl Deref for GPT166 {
398    type Target = gpt164::RegisterBlock;
399    #[inline(always)]
400    fn deref(&self) -> &Self::Target {
401        unsafe { &*Self::PTR }
402    }
403}
404impl core::fmt::Debug for GPT166 {
405    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
406        f.debug_struct("GPT166").finish()
407    }
408}
409#[doc = "General PWM Timer 6 (16-bit)"]
410pub use self::gpt164 as gpt166;
411#[doc = "General PWM Timer 7 (16-bit)"]
412pub struct GPT167 {
413    _marker: PhantomData<*const ()>,
414}
415unsafe impl Send for GPT167 {}
416impl GPT167 {
417    #[doc = r"Pointer to the register block"]
418    pub const PTR: *const gpt164::RegisterBlock = 0x4007_8700 as *const _;
419    #[doc = r"Return the pointer to the register block"]
420    #[inline(always)]
421    pub const fn ptr() -> *const gpt164::RegisterBlock {
422        Self::PTR
423    }
424}
425impl Deref for GPT167 {
426    type Target = gpt164::RegisterBlock;
427    #[inline(always)]
428    fn deref(&self) -> &Self::Target {
429        unsafe { &*Self::PTR }
430    }
431}
432impl core::fmt::Debug for GPT167 {
433    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
434        f.debug_struct("GPT167").finish()
435    }
436}
437#[doc = "General PWM Timer 7 (16-bit)"]
438pub use self::gpt164 as gpt167;
439#[doc = "General PWM Timer 8 (16-bit)"]
440pub struct GPT168 {
441    _marker: PhantomData<*const ()>,
442}
443unsafe impl Send for GPT168 {}
444impl GPT168 {
445    #[doc = r"Pointer to the register block"]
446    pub const PTR: *const gpt164::RegisterBlock = 0x4007_8800 as *const _;
447    #[doc = r"Return the pointer to the register block"]
448    #[inline(always)]
449    pub const fn ptr() -> *const gpt164::RegisterBlock {
450        Self::PTR
451    }
452}
453impl Deref for GPT168 {
454    type Target = gpt164::RegisterBlock;
455    #[inline(always)]
456    fn deref(&self) -> &Self::Target {
457        unsafe { &*Self::PTR }
458    }
459}
460impl core::fmt::Debug for GPT168 {
461    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
462        f.debug_struct("GPT168").finish()
463    }
464}
465#[doc = "General PWM Timer 8 (16-bit)"]
466pub use self::gpt164 as gpt168;
467#[doc = "General PWM Timer 9 (16-bit)"]
468pub struct GPT169 {
469    _marker: PhantomData<*const ()>,
470}
471unsafe impl Send for GPT169 {}
472impl GPT169 {
473    #[doc = r"Pointer to the register block"]
474    pub const PTR: *const gpt164::RegisterBlock = 0x4007_8900 as *const _;
475    #[doc = r"Return the pointer to the register block"]
476    #[inline(always)]
477    pub const fn ptr() -> *const gpt164::RegisterBlock {
478        Self::PTR
479    }
480}
481impl Deref for GPT169 {
482    type Target = gpt164::RegisterBlock;
483    #[inline(always)]
484    fn deref(&self) -> &Self::Target {
485        unsafe { &*Self::PTR }
486    }
487}
488impl core::fmt::Debug for GPT169 {
489    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
490        f.debug_struct("GPT169").finish()
491    }
492}
493#[doc = "General PWM Timer 9 (16-bit)"]
494pub use self::gpt164 as gpt169;
495#[doc = "Output Phase Switching Controller"]
496pub struct GPT_OPS {
497    _marker: PhantomData<*const ()>,
498}
499unsafe impl Send for GPT_OPS {}
500impl GPT_OPS {
501    #[doc = r"Pointer to the register block"]
502    pub const PTR: *const gpt_ops::RegisterBlock = 0x4007_8ff0 as *const _;
503    #[doc = r"Return the pointer to the register block"]
504    #[inline(always)]
505    pub const fn ptr() -> *const gpt_ops::RegisterBlock {
506        Self::PTR
507    }
508}
509impl Deref for GPT_OPS {
510    type Target = gpt_ops::RegisterBlock;
511    #[inline(always)]
512    fn deref(&self) -> &Self::Target {
513        unsafe { &*Self::PTR }
514    }
515}
516impl core::fmt::Debug for GPT_OPS {
517    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
518        f.debug_struct("GPT_OPS").finish()
519    }
520}
521#[doc = "Output Phase Switching Controller"]
522pub mod gpt_ops;
523#[doc = "Asynchronous General purpose Timer 0"]
524pub struct AGT0 {
525    _marker: PhantomData<*const ()>,
526}
527unsafe impl Send for AGT0 {}
528impl AGT0 {
529    #[doc = r"Pointer to the register block"]
530    pub const PTR: *const agt0::RegisterBlock = 0x4008_4000 as *const _;
531    #[doc = r"Return the pointer to the register block"]
532    #[inline(always)]
533    pub const fn ptr() -> *const agt0::RegisterBlock {
534        Self::PTR
535    }
536}
537impl Deref for AGT0 {
538    type Target = agt0::RegisterBlock;
539    #[inline(always)]
540    fn deref(&self) -> &Self::Target {
541        unsafe { &*Self::PTR }
542    }
543}
544impl core::fmt::Debug for AGT0 {
545    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
546        f.debug_struct("AGT0").finish()
547    }
548}
549#[doc = "Asynchronous General purpose Timer 0"]
550pub mod agt0;
551#[doc = "Asynchronous General purpose Timer 1"]
552pub struct AGT1 {
553    _marker: PhantomData<*const ()>,
554}
555unsafe impl Send for AGT1 {}
556impl AGT1 {
557    #[doc = r"Pointer to the register block"]
558    pub const PTR: *const agt0::RegisterBlock = 0x4008_4100 as *const _;
559    #[doc = r"Return the pointer to the register block"]
560    #[inline(always)]
561    pub const fn ptr() -> *const agt0::RegisterBlock {
562        Self::PTR
563    }
564}
565impl Deref for AGT1 {
566    type Target = agt0::RegisterBlock;
567    #[inline(always)]
568    fn deref(&self) -> &Self::Target {
569        unsafe { &*Self::PTR }
570    }
571}
572impl core::fmt::Debug for AGT1 {
573    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
574        f.debug_struct("AGT1").finish()
575    }
576}
577#[doc = "Asynchronous General purpose Timer 1"]
578pub use self::agt0 as agt1;
579#[doc = "Realtime Clock"]
580pub struct RTC {
581    _marker: PhantomData<*const ()>,
582}
583unsafe impl Send for RTC {}
584impl RTC {
585    #[doc = r"Pointer to the register block"]
586    pub const PTR: *const rtc::RegisterBlock = 0x4004_4000 as *const _;
587    #[doc = r"Return the pointer to the register block"]
588    #[inline(always)]
589    pub const fn ptr() -> *const rtc::RegisterBlock {
590        Self::PTR
591    }
592}
593impl Deref for RTC {
594    type Target = rtc::RegisterBlock;
595    #[inline(always)]
596    fn deref(&self) -> &Self::Target {
597        unsafe { &*Self::PTR }
598    }
599}
600impl core::fmt::Debug for RTC {
601    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
602        f.debug_struct("RTC").finish()
603    }
604}
605#[doc = "Realtime Clock"]
606pub mod rtc;
607#[doc = "System Control"]
608pub struct SYSTEM {
609    _marker: PhantomData<*const ()>,
610}
611unsafe impl Send for SYSTEM {}
612impl SYSTEM {
613    #[doc = r"Pointer to the register block"]
614    pub const PTR: *const system::RegisterBlock = 0x4001_e000 as *const _;
615    #[doc = r"Return the pointer to the register block"]
616    #[inline(always)]
617    pub const fn ptr() -> *const system::RegisterBlock {
618        Self::PTR
619    }
620}
621impl Deref for SYSTEM {
622    type Target = system::RegisterBlock;
623    #[inline(always)]
624    fn deref(&self) -> &Self::Target {
625        unsafe { &*Self::PTR }
626    }
627}
628impl core::fmt::Debug for SYSTEM {
629    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
630        f.debug_struct("SYSTEM").finish()
631    }
632}
633#[doc = "System Control"]
634pub mod system;
635#[doc = "Module Stop Control B,C,D"]
636pub struct MSTP {
637    _marker: PhantomData<*const ()>,
638}
639unsafe impl Send for MSTP {}
640impl MSTP {
641    #[doc = r"Pointer to the register block"]
642    pub const PTR: *const mstp::RegisterBlock = 0x4004_7000 as *const _;
643    #[doc = r"Return the pointer to the register block"]
644    #[inline(always)]
645    pub const fn ptr() -> *const mstp::RegisterBlock {
646        Self::PTR
647    }
648}
649impl Deref for MSTP {
650    type Target = mstp::RegisterBlock;
651    #[inline(always)]
652    fn deref(&self) -> &Self::Target {
653        unsafe { &*Self::PTR }
654    }
655}
656impl core::fmt::Debug for MSTP {
657    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
658        f.debug_struct("MSTP").finish()
659    }
660}
661#[doc = "Module Stop Control B,C,D"]
662pub mod mstp;
663#[doc = "Flash Cache"]
664pub struct FCACHE {
665    _marker: PhantomData<*const ()>,
666}
667unsafe impl Send for FCACHE {}
668impl FCACHE {
669    #[doc = r"Pointer to the register block"]
670    pub const PTR: *const fcache::RegisterBlock = 0x4001_c000 as *const _;
671    #[doc = r"Return the pointer to the register block"]
672    #[inline(always)]
673    pub const fn ptr() -> *const fcache::RegisterBlock {
674        Self::PTR
675    }
676}
677impl Deref for FCACHE {
678    type Target = fcache::RegisterBlock;
679    #[inline(always)]
680    fn deref(&self) -> &Self::Target {
681        unsafe { &*Self::PTR }
682    }
683}
684impl core::fmt::Debug for FCACHE {
685    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
686        f.debug_struct("FCACHE").finish()
687    }
688}
689#[doc = "Flash Cache"]
690pub mod fcache;
691#[doc = "Interrupt Controller"]
692pub struct ICU {
693    _marker: PhantomData<*const ()>,
694}
695unsafe impl Send for ICU {}
696impl ICU {
697    #[doc = r"Pointer to the register block"]
698    pub const PTR: *const icu::RegisterBlock = 0x4000_6000 as *const _;
699    #[doc = r"Return the pointer to the register block"]
700    #[inline(always)]
701    pub const fn ptr() -> *const icu::RegisterBlock {
702        Self::PTR
703    }
704}
705impl Deref for ICU {
706    type Target = icu::RegisterBlock;
707    #[inline(always)]
708    fn deref(&self) -> &Self::Target {
709        unsafe { &*Self::PTR }
710    }
711}
712impl core::fmt::Debug for ICU {
713    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
714        f.debug_struct("ICU").finish()
715    }
716}
717#[doc = "Interrupt Controller"]
718pub mod icu;
719#[doc = "Direct memory access controller 0"]
720pub struct DMAC0 {
721    _marker: PhantomData<*const ()>,
722}
723unsafe impl Send for DMAC0 {}
724impl DMAC0 {
725    #[doc = r"Pointer to the register block"]
726    pub const PTR: *const dmac0::RegisterBlock = 0x4000_5000 as *const _;
727    #[doc = r"Return the pointer to the register block"]
728    #[inline(always)]
729    pub const fn ptr() -> *const dmac0::RegisterBlock {
730        Self::PTR
731    }
732}
733impl Deref for DMAC0 {
734    type Target = dmac0::RegisterBlock;
735    #[inline(always)]
736    fn deref(&self) -> &Self::Target {
737        unsafe { &*Self::PTR }
738    }
739}
740impl core::fmt::Debug for DMAC0 {
741    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
742        f.debug_struct("DMAC0").finish()
743    }
744}
745#[doc = "Direct memory access controller 0"]
746pub mod dmac0;
747#[doc = "Direct memory access controller 1"]
748pub struct DMAC1 {
749    _marker: PhantomData<*const ()>,
750}
751unsafe impl Send for DMAC1 {}
752impl DMAC1 {
753    #[doc = r"Pointer to the register block"]
754    pub const PTR: *const dmac0::RegisterBlock = 0x4000_5040 as *const _;
755    #[doc = r"Return the pointer to the register block"]
756    #[inline(always)]
757    pub const fn ptr() -> *const dmac0::RegisterBlock {
758        Self::PTR
759    }
760}
761impl Deref for DMAC1 {
762    type Target = dmac0::RegisterBlock;
763    #[inline(always)]
764    fn deref(&self) -> &Self::Target {
765        unsafe { &*Self::PTR }
766    }
767}
768impl core::fmt::Debug for DMAC1 {
769    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
770        f.debug_struct("DMAC1").finish()
771    }
772}
773#[doc = "Direct memory access controller 1"]
774pub use self::dmac0 as dmac1;
775#[doc = "Direct memory access controller 2"]
776pub struct DMAC2 {
777    _marker: PhantomData<*const ()>,
778}
779unsafe impl Send for DMAC2 {}
780impl DMAC2 {
781    #[doc = r"Pointer to the register block"]
782    pub const PTR: *const dmac0::RegisterBlock = 0x4000_5080 as *const _;
783    #[doc = r"Return the pointer to the register block"]
784    #[inline(always)]
785    pub const fn ptr() -> *const dmac0::RegisterBlock {
786        Self::PTR
787    }
788}
789impl Deref for DMAC2 {
790    type Target = dmac0::RegisterBlock;
791    #[inline(always)]
792    fn deref(&self) -> &Self::Target {
793        unsafe { &*Self::PTR }
794    }
795}
796impl core::fmt::Debug for DMAC2 {
797    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
798        f.debug_struct("DMAC2").finish()
799    }
800}
801#[doc = "Direct memory access controller 2"]
802pub use self::dmac0 as dmac2;
803#[doc = "Direct memory access controller 3"]
804pub struct DMAC3 {
805    _marker: PhantomData<*const ()>,
806}
807unsafe impl Send for DMAC3 {}
808impl DMAC3 {
809    #[doc = r"Pointer to the register block"]
810    pub const PTR: *const dmac0::RegisterBlock = 0x4000_50c0 as *const _;
811    #[doc = r"Return the pointer to the register block"]
812    #[inline(always)]
813    pub const fn ptr() -> *const dmac0::RegisterBlock {
814        Self::PTR
815    }
816}
817impl Deref for DMAC3 {
818    type Target = dmac0::RegisterBlock;
819    #[inline(always)]
820    fn deref(&self) -> &Self::Target {
821        unsafe { &*Self::PTR }
822    }
823}
824impl core::fmt::Debug for DMAC3 {
825    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
826        f.debug_struct("DMAC3").finish()
827    }
828}
829#[doc = "Direct memory access controller 3"]
830pub use self::dmac0 as dmac3;
831#[doc = "DMAC Module Activation"]
832pub struct DMA {
833    _marker: PhantomData<*const ()>,
834}
835unsafe impl Send for DMA {}
836impl DMA {
837    #[doc = r"Pointer to the register block"]
838    pub const PTR: *const dma::RegisterBlock = 0x4000_5200 as *const _;
839    #[doc = r"Return the pointer to the register block"]
840    #[inline(always)]
841    pub const fn ptr() -> *const dma::RegisterBlock {
842        Self::PTR
843    }
844}
845impl Deref for DMA {
846    type Target = dma::RegisterBlock;
847    #[inline(always)]
848    fn deref(&self) -> &Self::Target {
849        unsafe { &*Self::PTR }
850    }
851}
852impl core::fmt::Debug for DMA {
853    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
854        f.debug_struct("DMA").finish()
855    }
856}
857#[doc = "DMAC Module Activation"]
858pub mod dma;
859#[doc = "Debug Function"]
860pub struct DBG {
861    _marker: PhantomData<*const ()>,
862}
863unsafe impl Send for DBG {}
864impl DBG {
865    #[doc = r"Pointer to the register block"]
866    pub const PTR: *const dbg::RegisterBlock = 0x4001_b000 as *const _;
867    #[doc = r"Return the pointer to the register block"]
868    #[inline(always)]
869    pub const fn ptr() -> *const dbg::RegisterBlock {
870        Self::PTR
871    }
872}
873impl Deref for DBG {
874    type Target = dbg::RegisterBlock;
875    #[inline(always)]
876    fn deref(&self) -> &Self::Target {
877        unsafe { &*Self::PTR }
878    }
879}
880impl core::fmt::Debug for DBG {
881    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
882        f.debug_struct("DBG").finish()
883    }
884}
885#[doc = "Debug Function"]
886pub mod dbg;
887#[doc = "BUS Control"]
888pub struct BUS {
889    _marker: PhantomData<*const ()>,
890}
891unsafe impl Send for BUS {}
892impl BUS {
893    #[doc = r"Pointer to the register block"]
894    pub const PTR: *const bus::RegisterBlock = 0x4000_3000 as *const _;
895    #[doc = r"Return the pointer to the register block"]
896    #[inline(always)]
897    pub const fn ptr() -> *const bus::RegisterBlock {
898        Self::PTR
899    }
900}
901impl Deref for BUS {
902    type Target = bus::RegisterBlock;
903    #[inline(always)]
904    fn deref(&self) -> &Self::Target {
905        unsafe { &*Self::PTR }
906    }
907}
908impl core::fmt::Debug for BUS {
909    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
910        f.debug_struct("BUS").finish()
911    }
912}
913#[doc = "BUS Control"]
914pub mod bus;
915#[doc = "SRAM Control"]
916pub struct SRAM {
917    _marker: PhantomData<*const ()>,
918}
919unsafe impl Send for SRAM {}
920impl SRAM {
921    #[doc = r"Pointer to the register block"]
922    pub const PTR: *const sram::RegisterBlock = 0x4000_2000 as *const _;
923    #[doc = r"Return the pointer to the register block"]
924    #[inline(always)]
925    pub const fn ptr() -> *const sram::RegisterBlock {
926        Self::PTR
927    }
928}
929impl Deref for SRAM {
930    type Target = sram::RegisterBlock;
931    #[inline(always)]
932    fn deref(&self) -> &Self::Target {
933        unsafe { &*Self::PTR }
934    }
935}
936impl core::fmt::Debug for SRAM {
937    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
938        f.debug_struct("SRAM").finish()
939    }
940}
941#[doc = "SRAM Control"]
942pub mod sram;
943#[doc = "Bus Master MPU"]
944pub struct MMPU {
945    _marker: PhantomData<*const ()>,
946}
947unsafe impl Send for MMPU {}
948impl MMPU {
949    #[doc = r"Pointer to the register block"]
950    pub const PTR: *const mmpu::RegisterBlock = 0x4000_0000 as *const _;
951    #[doc = r"Return the pointer to the register block"]
952    #[inline(always)]
953    pub const fn ptr() -> *const mmpu::RegisterBlock {
954        Self::PTR
955    }
956}
957impl Deref for MMPU {
958    type Target = mmpu::RegisterBlock;
959    #[inline(always)]
960    fn deref(&self) -> &Self::Target {
961        unsafe { &*Self::PTR }
962    }
963}
964impl core::fmt::Debug for MMPU {
965    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
966        f.debug_struct("MMPU").finish()
967    }
968}
969#[doc = "Bus Master MPU"]
970pub mod mmpu;
971#[doc = "Bus Slave MPU"]
972pub struct SMPU {
973    _marker: PhantomData<*const ()>,
974}
975unsafe impl Send for SMPU {}
976impl SMPU {
977    #[doc = r"Pointer to the register block"]
978    pub const PTR: *const smpu::RegisterBlock = 0x4000_0c00 as *const _;
979    #[doc = r"Return the pointer to the register block"]
980    #[inline(always)]
981    pub const fn ptr() -> *const smpu::RegisterBlock {
982        Self::PTR
983    }
984}
985impl Deref for SMPU {
986    type Target = smpu::RegisterBlock;
987    #[inline(always)]
988    fn deref(&self) -> &Self::Target {
989        unsafe { &*Self::PTR }
990    }
991}
992impl core::fmt::Debug for SMPU {
993    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
994        f.debug_struct("SMPU").finish()
995    }
996}
997#[doc = "Bus Slave MPU"]
998pub mod smpu;
999#[doc = "CPU Stack Pointer Monitor"]
1000pub struct SPMON {
1001    _marker: PhantomData<*const ()>,
1002}
1003unsafe impl Send for SPMON {}
1004impl SPMON {
1005    #[doc = r"Pointer to the register block"]
1006    pub const PTR: *const spmon::RegisterBlock = 0x4000_0d00 as *const _;
1007    #[doc = r"Return the pointer to the register block"]
1008    #[inline(always)]
1009    pub const fn ptr() -> *const spmon::RegisterBlock {
1010        Self::PTR
1011    }
1012}
1013impl Deref for SPMON {
1014    type Target = spmon::RegisterBlock;
1015    #[inline(always)]
1016    fn deref(&self) -> &Self::Target {
1017        unsafe { &*Self::PTR }
1018    }
1019}
1020impl core::fmt::Debug for SPMON {
1021    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1022        f.debug_struct("SPMON").finish()
1023    }
1024}
1025#[doc = "CPU Stack Pointer Monitor"]
1026pub mod spmon;
1027#[doc = "Memory Mirror Function"]
1028pub struct MMF {
1029    _marker: PhantomData<*const ()>,
1030}
1031unsafe impl Send for MMF {}
1032impl MMF {
1033    #[doc = r"Pointer to the register block"]
1034    pub const PTR: *const mmf::RegisterBlock = 0x4000_1000 as *const _;
1035    #[doc = r"Return the pointer to the register block"]
1036    #[inline(always)]
1037    pub const fn ptr() -> *const mmf::RegisterBlock {
1038        Self::PTR
1039    }
1040}
1041impl Deref for MMF {
1042    type Target = mmf::RegisterBlock;
1043    #[inline(always)]
1044    fn deref(&self) -> &Self::Target {
1045        unsafe { &*Self::PTR }
1046    }
1047}
1048impl core::fmt::Debug for MMF {
1049    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1050        f.debug_struct("MMF").finish()
1051    }
1052}
1053#[doc = "Memory Mirror Function"]
1054pub mod mmf;
1055#[doc = "Serial Peripheral Interface 0"]
1056pub struct SPI0 {
1057    _marker: PhantomData<*const ()>,
1058}
1059unsafe impl Send for SPI0 {}
1060impl SPI0 {
1061    #[doc = r"Pointer to the register block"]
1062    pub const PTR: *const spi0::RegisterBlock = 0x4007_2000 as *const _;
1063    #[doc = r"Return the pointer to the register block"]
1064    #[inline(always)]
1065    pub const fn ptr() -> *const spi0::RegisterBlock {
1066        Self::PTR
1067    }
1068}
1069impl Deref for SPI0 {
1070    type Target = spi0::RegisterBlock;
1071    #[inline(always)]
1072    fn deref(&self) -> &Self::Target {
1073        unsafe { &*Self::PTR }
1074    }
1075}
1076impl core::fmt::Debug for SPI0 {
1077    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1078        f.debug_struct("SPI0").finish()
1079    }
1080}
1081#[doc = "Serial Peripheral Interface 0"]
1082pub mod spi0;
1083#[doc = "Serial Peripheral Interface 1"]
1084pub struct SPI1 {
1085    _marker: PhantomData<*const ()>,
1086}
1087unsafe impl Send for SPI1 {}
1088impl SPI1 {
1089    #[doc = r"Pointer to the register block"]
1090    pub const PTR: *const spi1::RegisterBlock = 0x4007_2100 as *const _;
1091    #[doc = r"Return the pointer to the register block"]
1092    #[inline(always)]
1093    pub const fn ptr() -> *const spi1::RegisterBlock {
1094        Self::PTR
1095    }
1096}
1097impl Deref for SPI1 {
1098    type Target = spi1::RegisterBlock;
1099    #[inline(always)]
1100    fn deref(&self) -> &Self::Target {
1101        unsafe { &*Self::PTR }
1102    }
1103}
1104impl core::fmt::Debug for SPI1 {
1105    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1106        f.debug_struct("SPI1").finish()
1107    }
1108}
1109#[doc = "Serial Peripheral Interface 1"]
1110pub mod spi1;
1111#[doc = "Serial Communication Interface 0"]
1112pub struct SCI0 {
1113    _marker: PhantomData<*const ()>,
1114}
1115unsafe impl Send for SCI0 {}
1116impl SCI0 {
1117    #[doc = r"Pointer to the register block"]
1118    pub const PTR: *const sci0::RegisterBlock = 0x4007_0000 as *const _;
1119    #[doc = r"Return the pointer to the register block"]
1120    #[inline(always)]
1121    pub const fn ptr() -> *const sci0::RegisterBlock {
1122        Self::PTR
1123    }
1124}
1125impl Deref for SCI0 {
1126    type Target = sci0::RegisterBlock;
1127    #[inline(always)]
1128    fn deref(&self) -> &Self::Target {
1129        unsafe { &*Self::PTR }
1130    }
1131}
1132impl core::fmt::Debug for SCI0 {
1133    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1134        f.debug_struct("SCI0").finish()
1135    }
1136}
1137#[doc = "Serial Communication Interface 0"]
1138pub mod sci0;
1139#[doc = "Serial Communication Interface 1"]
1140pub struct SCI1 {
1141    _marker: PhantomData<*const ()>,
1142}
1143unsafe impl Send for SCI1 {}
1144impl SCI1 {
1145    #[doc = r"Pointer to the register block"]
1146    pub const PTR: *const sci0::RegisterBlock = 0x4007_0020 as *const _;
1147    #[doc = r"Return the pointer to the register block"]
1148    #[inline(always)]
1149    pub const fn ptr() -> *const sci0::RegisterBlock {
1150        Self::PTR
1151    }
1152}
1153impl Deref for SCI1 {
1154    type Target = sci0::RegisterBlock;
1155    #[inline(always)]
1156    fn deref(&self) -> &Self::Target {
1157        unsafe { &*Self::PTR }
1158    }
1159}
1160impl core::fmt::Debug for SCI1 {
1161    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1162        f.debug_struct("SCI1").finish()
1163    }
1164}
1165#[doc = "Serial Communication Interface 1"]
1166pub use self::sci0 as sci1;
1167#[doc = "Serial Communication Interface 2"]
1168pub struct SCI2 {
1169    _marker: PhantomData<*const ()>,
1170}
1171unsafe impl Send for SCI2 {}
1172impl SCI2 {
1173    #[doc = r"Pointer to the register block"]
1174    pub const PTR: *const sci2::RegisterBlock = 0x4007_0040 as *const _;
1175    #[doc = r"Return the pointer to the register block"]
1176    #[inline(always)]
1177    pub const fn ptr() -> *const sci2::RegisterBlock {
1178        Self::PTR
1179    }
1180}
1181impl Deref for SCI2 {
1182    type Target = sci2::RegisterBlock;
1183    #[inline(always)]
1184    fn deref(&self) -> &Self::Target {
1185        unsafe { &*Self::PTR }
1186    }
1187}
1188impl core::fmt::Debug for SCI2 {
1189    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1190        f.debug_struct("SCI2").finish()
1191    }
1192}
1193#[doc = "Serial Communication Interface 2"]
1194pub mod sci2;
1195#[doc = "Serial Communication Interface 3"]
1196pub struct SCI3 {
1197    _marker: PhantomData<*const ()>,
1198}
1199unsafe impl Send for SCI3 {}
1200impl SCI3 {
1201    #[doc = r"Pointer to the register block"]
1202    pub const PTR: *const sci2::RegisterBlock = 0x4007_0060 as *const _;
1203    #[doc = r"Return the pointer to the register block"]
1204    #[inline(always)]
1205    pub const fn ptr() -> *const sci2::RegisterBlock {
1206        Self::PTR
1207    }
1208}
1209impl Deref for SCI3 {
1210    type Target = sci2::RegisterBlock;
1211    #[inline(always)]
1212    fn deref(&self) -> &Self::Target {
1213        unsafe { &*Self::PTR }
1214    }
1215}
1216impl core::fmt::Debug for SCI3 {
1217    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1218        f.debug_struct("SCI3").finish()
1219    }
1220}
1221#[doc = "Serial Communication Interface 3"]
1222pub use self::sci2 as sci3;
1223#[doc = "Serial Communication Interface 4"]
1224pub struct SCI4 {
1225    _marker: PhantomData<*const ()>,
1226}
1227unsafe impl Send for SCI4 {}
1228impl SCI4 {
1229    #[doc = r"Pointer to the register block"]
1230    pub const PTR: *const sci2::RegisterBlock = 0x4007_0080 as *const _;
1231    #[doc = r"Return the pointer to the register block"]
1232    #[inline(always)]
1233    pub const fn ptr() -> *const sci2::RegisterBlock {
1234        Self::PTR
1235    }
1236}
1237impl Deref for SCI4 {
1238    type Target = sci2::RegisterBlock;
1239    #[inline(always)]
1240    fn deref(&self) -> &Self::Target {
1241        unsafe { &*Self::PTR }
1242    }
1243}
1244impl core::fmt::Debug for SCI4 {
1245    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1246        f.debug_struct("SCI4").finish()
1247    }
1248}
1249#[doc = "Serial Communication Interface 4"]
1250pub use self::sci2 as sci4;
1251#[doc = "Serial Communication Interface 9"]
1252pub struct SCI9 {
1253    _marker: PhantomData<*const ()>,
1254}
1255unsafe impl Send for SCI9 {}
1256impl SCI9 {
1257    #[doc = r"Pointer to the register block"]
1258    pub const PTR: *const sci2::RegisterBlock = 0x4007_0120 as *const _;
1259    #[doc = r"Return the pointer to the register block"]
1260    #[inline(always)]
1261    pub const fn ptr() -> *const sci2::RegisterBlock {
1262        Self::PTR
1263    }
1264}
1265impl Deref for SCI9 {
1266    type Target = sci2::RegisterBlock;
1267    #[inline(always)]
1268    fn deref(&self) -> &Self::Target {
1269        unsafe { &*Self::PTR }
1270    }
1271}
1272impl core::fmt::Debug for SCI9 {
1273    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1274        f.debug_struct("SCI9").finish()
1275    }
1276}
1277#[doc = "Serial Communication Interface 9"]
1278pub use self::sci2 as sci9;
1279#[doc = "Inter-Integrated Circuit 0"]
1280pub struct IIC0 {
1281    _marker: PhantomData<*const ()>,
1282}
1283unsafe impl Send for IIC0 {}
1284impl IIC0 {
1285    #[doc = r"Pointer to the register block"]
1286    pub const PTR: *const iic0::RegisterBlock = 0x4005_3000 as *const _;
1287    #[doc = r"Return the pointer to the register block"]
1288    #[inline(always)]
1289    pub const fn ptr() -> *const iic0::RegisterBlock {
1290        Self::PTR
1291    }
1292}
1293impl Deref for IIC0 {
1294    type Target = iic0::RegisterBlock;
1295    #[inline(always)]
1296    fn deref(&self) -> &Self::Target {
1297        unsafe { &*Self::PTR }
1298    }
1299}
1300impl core::fmt::Debug for IIC0 {
1301    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1302        f.debug_struct("IIC0").finish()
1303    }
1304}
1305#[doc = "Inter-Integrated Circuit 0"]
1306pub mod iic0;
1307#[doc = "Inter-Integrated Circuit 1"]
1308pub struct IIC1 {
1309    _marker: PhantomData<*const ()>,
1310}
1311unsafe impl Send for IIC1 {}
1312impl IIC1 {
1313    #[doc = r"Pointer to the register block"]
1314    pub const PTR: *const iic1::RegisterBlock = 0x4005_3100 as *const _;
1315    #[doc = r"Return the pointer to the register block"]
1316    #[inline(always)]
1317    pub const fn ptr() -> *const iic1::RegisterBlock {
1318        Self::PTR
1319    }
1320}
1321impl Deref for IIC1 {
1322    type Target = iic1::RegisterBlock;
1323    #[inline(always)]
1324    fn deref(&self) -> &Self::Target {
1325        unsafe { &*Self::PTR }
1326    }
1327}
1328impl core::fmt::Debug for IIC1 {
1329    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1330        f.debug_struct("IIC1").finish()
1331    }
1332}
1333#[doc = "Inter-Integrated Circuit 1"]
1334pub mod iic1;
1335#[doc = "Inter-Integrated Circuit 2"]
1336pub struct IIC2 {
1337    _marker: PhantomData<*const ()>,
1338}
1339unsafe impl Send for IIC2 {}
1340impl IIC2 {
1341    #[doc = r"Pointer to the register block"]
1342    pub const PTR: *const iic1::RegisterBlock = 0x4005_3200 as *const _;
1343    #[doc = r"Return the pointer to the register block"]
1344    #[inline(always)]
1345    pub const fn ptr() -> *const iic1::RegisterBlock {
1346        Self::PTR
1347    }
1348}
1349impl Deref for IIC2 {
1350    type Target = iic1::RegisterBlock;
1351    #[inline(always)]
1352    fn deref(&self) -> &Self::Target {
1353        unsafe { &*Self::PTR }
1354    }
1355}
1356impl core::fmt::Debug for IIC2 {
1357    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1358        f.debug_struct("IIC2").finish()
1359    }
1360}
1361#[doc = "Inter-Integrated Circuit 2"]
1362pub use self::iic1 as iic2;
1363#[doc = "CAN0 Module"]
1364pub struct CAN0 {
1365    _marker: PhantomData<*const ()>,
1366}
1367unsafe impl Send for CAN0 {}
1368impl CAN0 {
1369    #[doc = r"Pointer to the register block"]
1370    pub const PTR: *const can0::RegisterBlock = 0x4005_0000 as *const _;
1371    #[doc = r"Return the pointer to the register block"]
1372    #[inline(always)]
1373    pub const fn ptr() -> *const can0::RegisterBlock {
1374        Self::PTR
1375    }
1376}
1377impl Deref for CAN0 {
1378    type Target = can0::RegisterBlock;
1379    #[inline(always)]
1380    fn deref(&self) -> &Self::Target {
1381        unsafe { &*Self::PTR }
1382    }
1383}
1384impl core::fmt::Debug for CAN0 {
1385    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1386        f.debug_struct("CAN0").finish()
1387    }
1388}
1389#[doc = "CAN0 Module"]
1390pub mod can0;
1391#[doc = "Watchdog Timer"]
1392pub struct WDT {
1393    _marker: PhantomData<*const ()>,
1394}
1395unsafe impl Send for WDT {}
1396impl WDT {
1397    #[doc = r"Pointer to the register block"]
1398    pub const PTR: *const wdt::RegisterBlock = 0x4004_4200 as *const _;
1399    #[doc = r"Return the pointer to the register block"]
1400    #[inline(always)]
1401    pub const fn ptr() -> *const wdt::RegisterBlock {
1402        Self::PTR
1403    }
1404}
1405impl Deref for WDT {
1406    type Target = wdt::RegisterBlock;
1407    #[inline(always)]
1408    fn deref(&self) -> &Self::Target {
1409        unsafe { &*Self::PTR }
1410    }
1411}
1412impl core::fmt::Debug for WDT {
1413    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1414        f.debug_struct("WDT").finish()
1415    }
1416}
1417#[doc = "Watchdog Timer"]
1418pub mod wdt;
1419#[doc = "USB 2.0 FS Module"]
1420pub struct USBFS {
1421    _marker: PhantomData<*const ()>,
1422}
1423unsafe impl Send for USBFS {}
1424impl USBFS {
1425    #[doc = r"Pointer to the register block"]
1426    pub const PTR: *const usbfs::RegisterBlock = 0x4009_0000 as *const _;
1427    #[doc = r"Return the pointer to the register block"]
1428    #[inline(always)]
1429    pub const fn ptr() -> *const usbfs::RegisterBlock {
1430        Self::PTR
1431    }
1432}
1433impl Deref for USBFS {
1434    type Target = usbfs::RegisterBlock;
1435    #[inline(always)]
1436    fn deref(&self) -> &Self::Target {
1437        unsafe { &*Self::PTR }
1438    }
1439}
1440impl core::fmt::Debug for USBFS {
1441    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1442        f.debug_struct("USBFS").finish()
1443    }
1444}
1445#[doc = "USB 2.0 FS Module"]
1446pub mod usbfs;
1447#[doc = "Independent Watchdog Timer"]
1448pub struct IWDT {
1449    _marker: PhantomData<*const ()>,
1450}
1451unsafe impl Send for IWDT {}
1452impl IWDT {
1453    #[doc = r"Pointer to the register block"]
1454    pub const PTR: *const iwdt::RegisterBlock = 0x4004_4400 as *const _;
1455    #[doc = r"Return the pointer to the register block"]
1456    #[inline(always)]
1457    pub const fn ptr() -> *const iwdt::RegisterBlock {
1458        Self::PTR
1459    }
1460}
1461impl Deref for IWDT {
1462    type Target = iwdt::RegisterBlock;
1463    #[inline(always)]
1464    fn deref(&self) -> &Self::Target {
1465        unsafe { &*Self::PTR }
1466    }
1467}
1468impl core::fmt::Debug for IWDT {
1469    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1470        f.debug_struct("IWDT").finish()
1471    }
1472}
1473#[doc = "Independent Watchdog Timer"]
1474pub mod iwdt;
1475#[doc = "Port 0 Control Registers"]
1476pub struct PORT0 {
1477    _marker: PhantomData<*const ()>,
1478}
1479unsafe impl Send for PORT0 {}
1480impl PORT0 {
1481    #[doc = r"Pointer to the register block"]
1482    pub const PTR: *const port0::RegisterBlock = 0x4004_0000 as *const _;
1483    #[doc = r"Return the pointer to the register block"]
1484    #[inline(always)]
1485    pub const fn ptr() -> *const port0::RegisterBlock {
1486        Self::PTR
1487    }
1488}
1489impl Deref for PORT0 {
1490    type Target = port0::RegisterBlock;
1491    #[inline(always)]
1492    fn deref(&self) -> &Self::Target {
1493        unsafe { &*Self::PTR }
1494    }
1495}
1496impl core::fmt::Debug for PORT0 {
1497    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1498        f.debug_struct("PORT0").finish()
1499    }
1500}
1501#[doc = "Port 0 Control Registers"]
1502pub mod port0;
1503#[doc = "Port 1 Control Registers"]
1504pub struct PORT1 {
1505    _marker: PhantomData<*const ()>,
1506}
1507unsafe impl Send for PORT1 {}
1508impl PORT1 {
1509    #[doc = r"Pointer to the register block"]
1510    pub const PTR: *const port1::RegisterBlock = 0x4004_0020 as *const _;
1511    #[doc = r"Return the pointer to the register block"]
1512    #[inline(always)]
1513    pub const fn ptr() -> *const port1::RegisterBlock {
1514        Self::PTR
1515    }
1516}
1517impl Deref for PORT1 {
1518    type Target = port1::RegisterBlock;
1519    #[inline(always)]
1520    fn deref(&self) -> &Self::Target {
1521        unsafe { &*Self::PTR }
1522    }
1523}
1524impl core::fmt::Debug for PORT1 {
1525    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1526        f.debug_struct("PORT1").finish()
1527    }
1528}
1529#[doc = "Port 1 Control Registers"]
1530pub mod port1;
1531#[doc = "Port 2 Control Registers"]
1532pub struct PORT2 {
1533    _marker: PhantomData<*const ()>,
1534}
1535unsafe impl Send for PORT2 {}
1536impl PORT2 {
1537    #[doc = r"Pointer to the register block"]
1538    pub const PTR: *const port1::RegisterBlock = 0x4004_0040 as *const _;
1539    #[doc = r"Return the pointer to the register block"]
1540    #[inline(always)]
1541    pub const fn ptr() -> *const port1::RegisterBlock {
1542        Self::PTR
1543    }
1544}
1545impl Deref for PORT2 {
1546    type Target = port1::RegisterBlock;
1547    #[inline(always)]
1548    fn deref(&self) -> &Self::Target {
1549        unsafe { &*Self::PTR }
1550    }
1551}
1552impl core::fmt::Debug for PORT2 {
1553    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1554        f.debug_struct("PORT2").finish()
1555    }
1556}
1557#[doc = "Port 2 Control Registers"]
1558pub use self::port1 as port2;
1559#[doc = "Port 3 Control Registers"]
1560pub struct PORT3 {
1561    _marker: PhantomData<*const ()>,
1562}
1563unsafe impl Send for PORT3 {}
1564impl PORT3 {
1565    #[doc = r"Pointer to the register block"]
1566    pub const PTR: *const port1::RegisterBlock = 0x4004_0060 as *const _;
1567    #[doc = r"Return the pointer to the register block"]
1568    #[inline(always)]
1569    pub const fn ptr() -> *const port1::RegisterBlock {
1570        Self::PTR
1571    }
1572}
1573impl Deref for PORT3 {
1574    type Target = port1::RegisterBlock;
1575    #[inline(always)]
1576    fn deref(&self) -> &Self::Target {
1577        unsafe { &*Self::PTR }
1578    }
1579}
1580impl core::fmt::Debug for PORT3 {
1581    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1582        f.debug_struct("PORT3").finish()
1583    }
1584}
1585#[doc = "Port 3 Control Registers"]
1586pub use self::port1 as port3;
1587#[doc = "Port 4 Control Registers"]
1588pub struct PORT4 {
1589    _marker: PhantomData<*const ()>,
1590}
1591unsafe impl Send for PORT4 {}
1592impl PORT4 {
1593    #[doc = r"Pointer to the register block"]
1594    pub const PTR: *const port1::RegisterBlock = 0x4004_0080 as *const _;
1595    #[doc = r"Return the pointer to the register block"]
1596    #[inline(always)]
1597    pub const fn ptr() -> *const port1::RegisterBlock {
1598        Self::PTR
1599    }
1600}
1601impl Deref for PORT4 {
1602    type Target = port1::RegisterBlock;
1603    #[inline(always)]
1604    fn deref(&self) -> &Self::Target {
1605        unsafe { &*Self::PTR }
1606    }
1607}
1608impl core::fmt::Debug for PORT4 {
1609    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1610        f.debug_struct("PORT4").finish()
1611    }
1612}
1613#[doc = "Port 4 Control Registers"]
1614pub use self::port1 as port4;
1615#[doc = "Port 5 Control Registers"]
1616pub struct PORT5 {
1617    _marker: PhantomData<*const ()>,
1618}
1619unsafe impl Send for PORT5 {}
1620impl PORT5 {
1621    #[doc = r"Pointer to the register block"]
1622    pub const PTR: *const port0::RegisterBlock = 0x4004_00a0 as *const _;
1623    #[doc = r"Return the pointer to the register block"]
1624    #[inline(always)]
1625    pub const fn ptr() -> *const port0::RegisterBlock {
1626        Self::PTR
1627    }
1628}
1629impl Deref for PORT5 {
1630    type Target = port0::RegisterBlock;
1631    #[inline(always)]
1632    fn deref(&self) -> &Self::Target {
1633        unsafe { &*Self::PTR }
1634    }
1635}
1636impl core::fmt::Debug for PORT5 {
1637    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1638        f.debug_struct("PORT5").finish()
1639    }
1640}
1641#[doc = "Port 5 Control Registers"]
1642pub use self::port0 as port5;
1643#[doc = "Port 6 Control Registers"]
1644pub struct PORT6 {
1645    _marker: PhantomData<*const ()>,
1646}
1647unsafe impl Send for PORT6 {}
1648impl PORT6 {
1649    #[doc = r"Pointer to the register block"]
1650    pub const PTR: *const port0::RegisterBlock = 0x4004_00c0 as *const _;
1651    #[doc = r"Return the pointer to the register block"]
1652    #[inline(always)]
1653    pub const fn ptr() -> *const port0::RegisterBlock {
1654        Self::PTR
1655    }
1656}
1657impl Deref for PORT6 {
1658    type Target = port0::RegisterBlock;
1659    #[inline(always)]
1660    fn deref(&self) -> &Self::Target {
1661        unsafe { &*Self::PTR }
1662    }
1663}
1664impl core::fmt::Debug for PORT6 {
1665    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1666        f.debug_struct("PORT6").finish()
1667    }
1668}
1669#[doc = "Port 6 Control Registers"]
1670pub use self::port0 as port6;
1671#[doc = "Port 7 Control Registers"]
1672pub struct PORT7 {
1673    _marker: PhantomData<*const ()>,
1674}
1675unsafe impl Send for PORT7 {}
1676impl PORT7 {
1677    #[doc = r"Pointer to the register block"]
1678    pub const PTR: *const port0::RegisterBlock = 0x4004_00e0 as *const _;
1679    #[doc = r"Return the pointer to the register block"]
1680    #[inline(always)]
1681    pub const fn ptr() -> *const port0::RegisterBlock {
1682        Self::PTR
1683    }
1684}
1685impl Deref for PORT7 {
1686    type Target = port0::RegisterBlock;
1687    #[inline(always)]
1688    fn deref(&self) -> &Self::Target {
1689        unsafe { &*Self::PTR }
1690    }
1691}
1692impl core::fmt::Debug for PORT7 {
1693    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1694        f.debug_struct("PORT7").finish()
1695    }
1696}
1697#[doc = "Port 7 Control Registers"]
1698pub use self::port0 as port7;
1699#[doc = "Port 8 Control Registers"]
1700pub struct PORT8 {
1701    _marker: PhantomData<*const ()>,
1702}
1703unsafe impl Send for PORT8 {}
1704impl PORT8 {
1705    #[doc = r"Pointer to the register block"]
1706    pub const PTR: *const port0::RegisterBlock = 0x4004_0100 as *const _;
1707    #[doc = r"Return the pointer to the register block"]
1708    #[inline(always)]
1709    pub const fn ptr() -> *const port0::RegisterBlock {
1710        Self::PTR
1711    }
1712}
1713impl Deref for PORT8 {
1714    type Target = port0::RegisterBlock;
1715    #[inline(always)]
1716    fn deref(&self) -> &Self::Target {
1717        unsafe { &*Self::PTR }
1718    }
1719}
1720impl core::fmt::Debug for PORT8 {
1721    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1722        f.debug_struct("PORT8").finish()
1723    }
1724}
1725#[doc = "Port 8 Control Registers"]
1726pub use self::port0 as port8;
1727#[doc = "Port 9 Control Registers"]
1728pub struct PORT9 {
1729    _marker: PhantomData<*const ()>,
1730}
1731unsafe impl Send for PORT9 {}
1732impl PORT9 {
1733    #[doc = r"Pointer to the register block"]
1734    pub const PTR: *const port0::RegisterBlock = 0x4004_0120 as *const _;
1735    #[doc = r"Return the pointer to the register block"]
1736    #[inline(always)]
1737    pub const fn ptr() -> *const port0::RegisterBlock {
1738        Self::PTR
1739    }
1740}
1741impl Deref for PORT9 {
1742    type Target = port0::RegisterBlock;
1743    #[inline(always)]
1744    fn deref(&self) -> &Self::Target {
1745        unsafe { &*Self::PTR }
1746    }
1747}
1748impl core::fmt::Debug for PORT9 {
1749    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1750        f.debug_struct("PORT9").finish()
1751    }
1752}
1753#[doc = "Port 9 Control Registers"]
1754pub use self::port0 as port9;
1755#[doc = "Pmn Pin Function Control Register"]
1756pub struct PFS {
1757    _marker: PhantomData<*const ()>,
1758}
1759unsafe impl Send for PFS {}
1760impl PFS {
1761    #[doc = r"Pointer to the register block"]
1762    pub const PTR: *const pfs::RegisterBlock = 0x4004_0800 as *const _;
1763    #[doc = r"Return the pointer to the register block"]
1764    #[inline(always)]
1765    pub const fn ptr() -> *const pfs::RegisterBlock {
1766        Self::PTR
1767    }
1768}
1769impl Deref for PFS {
1770    type Target = pfs::RegisterBlock;
1771    #[inline(always)]
1772    fn deref(&self) -> &Self::Target {
1773        unsafe { &*Self::PTR }
1774    }
1775}
1776impl core::fmt::Debug for PFS {
1777    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1778        f.debug_struct("PFS").finish()
1779    }
1780}
1781#[doc = "Pmn Pin Function Control Register"]
1782pub mod pfs;
1783#[doc = "Miscellaneous Port Control Register"]
1784pub struct PMISC {
1785    _marker: PhantomData<*const ()>,
1786}
1787unsafe impl Send for PMISC {}
1788impl PMISC {
1789    #[doc = r"Pointer to the register block"]
1790    pub const PTR: *const pmisc::RegisterBlock = 0x4004_0d00 as *const _;
1791    #[doc = r"Return the pointer to the register block"]
1792    #[inline(always)]
1793    pub const fn ptr() -> *const pmisc::RegisterBlock {
1794        Self::PTR
1795    }
1796}
1797impl Deref for PMISC {
1798    type Target = pmisc::RegisterBlock;
1799    #[inline(always)]
1800    fn deref(&self) -> &Self::Target {
1801        unsafe { &*Self::PTR }
1802    }
1803}
1804impl core::fmt::Debug for PMISC {
1805    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1806        f.debug_struct("PMISC").finish()
1807    }
1808}
1809#[doc = "Miscellaneous Port Control Register"]
1810pub mod pmisc;
1811#[doc = "Event Link Controller"]
1812pub struct ELC {
1813    _marker: PhantomData<*const ()>,
1814}
1815unsafe impl Send for ELC {}
1816impl ELC {
1817    #[doc = r"Pointer to the register block"]
1818    pub const PTR: *const elc::RegisterBlock = 0x4004_1000 as *const _;
1819    #[doc = r"Return the pointer to the register block"]
1820    #[inline(always)]
1821    pub const fn ptr() -> *const elc::RegisterBlock {
1822        Self::PTR
1823    }
1824}
1825impl Deref for ELC {
1826    type Target = elc::RegisterBlock;
1827    #[inline(always)]
1828    fn deref(&self) -> &Self::Target {
1829        unsafe { &*Self::PTR }
1830    }
1831}
1832impl core::fmt::Debug for ELC {
1833    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1834        f.debug_struct("ELC").finish()
1835    }
1836}
1837#[doc = "Event Link Controller"]
1838pub mod elc;
1839#[doc = "Data Operation Circuit"]
1840pub struct DOC {
1841    _marker: PhantomData<*const ()>,
1842}
1843unsafe impl Send for DOC {}
1844impl DOC {
1845    #[doc = r"Pointer to the register block"]
1846    pub const PTR: *const doc::RegisterBlock = 0x4005_4100 as *const _;
1847    #[doc = r"Return the pointer to the register block"]
1848    #[inline(always)]
1849    pub const fn ptr() -> *const doc::RegisterBlock {
1850        Self::PTR
1851    }
1852}
1853impl Deref for DOC {
1854    type Target = doc::RegisterBlock;
1855    #[inline(always)]
1856    fn deref(&self) -> &Self::Target {
1857        unsafe { &*Self::PTR }
1858    }
1859}
1860impl core::fmt::Debug for DOC {
1861    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1862        f.debug_struct("DOC").finish()
1863    }
1864}
1865#[doc = "Data Operation Circuit"]
1866pub mod doc;
1867#[doc = "CRC Calculator"]
1868pub struct CRC {
1869    _marker: PhantomData<*const ()>,
1870}
1871unsafe impl Send for CRC {}
1872impl CRC {
1873    #[doc = r"Pointer to the register block"]
1874    pub const PTR: *const crc::RegisterBlock = 0x4007_4000 as *const _;
1875    #[doc = r"Return the pointer to the register block"]
1876    #[inline(always)]
1877    pub const fn ptr() -> *const crc::RegisterBlock {
1878        Self::PTR
1879    }
1880}
1881impl Deref for CRC {
1882    type Target = crc::RegisterBlock;
1883    #[inline(always)]
1884    fn deref(&self) -> &Self::Target {
1885        unsafe { &*Self::PTR }
1886    }
1887}
1888impl core::fmt::Debug for CRC {
1889    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1890        f.debug_struct("CRC").finish()
1891    }
1892}
1893#[doc = "CRC Calculator"]
1894pub mod crc;
1895#[doc = "Clock Frequency Accuracy Measurement Circuit"]
1896pub struct CAC {
1897    _marker: PhantomData<*const ()>,
1898}
1899unsafe impl Send for CAC {}
1900impl CAC {
1901    #[doc = r"Pointer to the register block"]
1902    pub const PTR: *const cac::RegisterBlock = 0x4004_4600 as *const _;
1903    #[doc = r"Return the pointer to the register block"]
1904    #[inline(always)]
1905    pub const fn ptr() -> *const cac::RegisterBlock {
1906        Self::PTR
1907    }
1908}
1909impl Deref for CAC {
1910    type Target = cac::RegisterBlock;
1911    #[inline(always)]
1912    fn deref(&self) -> &Self::Target {
1913        unsafe { &*Self::PTR }
1914    }
1915}
1916impl core::fmt::Debug for CAC {
1917    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1918        f.debug_struct("CAC").finish()
1919    }
1920}
1921#[doc = "Clock Frequency Accuracy Measurement Circuit"]
1922pub mod cac;
1923#[doc = "8-bit D/A converter"]
1924pub struct DAC8 {
1925    _marker: PhantomData<*const ()>,
1926}
1927unsafe impl Send for DAC8 {}
1928impl DAC8 {
1929    #[doc = r"Pointer to the register block"]
1930    pub const PTR: *const dac8::RegisterBlock = 0x4009_e000 as *const _;
1931    #[doc = r"Return the pointer to the register block"]
1932    #[inline(always)]
1933    pub const fn ptr() -> *const dac8::RegisterBlock {
1934        Self::PTR
1935    }
1936}
1937impl Deref for DAC8 {
1938    type Target = dac8::RegisterBlock;
1939    #[inline(always)]
1940    fn deref(&self) -> &Self::Target {
1941        unsafe { &*Self::PTR }
1942    }
1943}
1944impl core::fmt::Debug for DAC8 {
1945    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1946        f.debug_struct("DAC8").finish()
1947    }
1948}
1949#[doc = "8-bit D/A converter"]
1950pub mod dac8;
1951#[doc = "12-bit D/A converter"]
1952pub struct DAC12 {
1953    _marker: PhantomData<*const ()>,
1954}
1955unsafe impl Send for DAC12 {}
1956impl DAC12 {
1957    #[doc = r"Pointer to the register block"]
1958    pub const PTR: *const dac12::RegisterBlock = 0x4005_e000 as *const _;
1959    #[doc = r"Return the pointer to the register block"]
1960    #[inline(always)]
1961    pub const fn ptr() -> *const dac12::RegisterBlock {
1962        Self::PTR
1963    }
1964}
1965impl Deref for DAC12 {
1966    type Target = dac12::RegisterBlock;
1967    #[inline(always)]
1968    fn deref(&self) -> &Self::Target {
1969        unsafe { &*Self::PTR }
1970    }
1971}
1972impl core::fmt::Debug for DAC12 {
1973    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1974        f.debug_struct("DAC12").finish()
1975    }
1976}
1977#[doc = "12-bit D/A converter"]
1978pub mod dac12;
1979#[doc = "Capacitive Touch Sensing Unit"]
1980pub struct CTSU {
1981    _marker: PhantomData<*const ()>,
1982}
1983unsafe impl Send for CTSU {}
1984impl CTSU {
1985    #[doc = r"Pointer to the register block"]
1986    pub const PTR: *const ctsu::RegisterBlock = 0x4008_1000 as *const _;
1987    #[doc = r"Return the pointer to the register block"]
1988    #[inline(always)]
1989    pub const fn ptr() -> *const ctsu::RegisterBlock {
1990        Self::PTR
1991    }
1992}
1993impl Deref for CTSU {
1994    type Target = ctsu::RegisterBlock;
1995    #[inline(always)]
1996    fn deref(&self) -> &Self::Target {
1997        unsafe { &*Self::PTR }
1998    }
1999}
2000impl core::fmt::Debug for CTSU {
2001    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2002        f.debug_struct("CTSU").finish()
2003    }
2004}
2005#[doc = "Capacitive Touch Sensing Unit"]
2006pub mod ctsu;
2007#[doc = "14bit A/D Converter"]
2008pub struct ADC140 {
2009    _marker: PhantomData<*const ()>,
2010}
2011unsafe impl Send for ADC140 {}
2012impl ADC140 {
2013    #[doc = r"Pointer to the register block"]
2014    pub const PTR: *const adc140::RegisterBlock = 0x4005_c000 as *const _;
2015    #[doc = r"Return the pointer to the register block"]
2016    #[inline(always)]
2017    pub const fn ptr() -> *const adc140::RegisterBlock {
2018        Self::PTR
2019    }
2020}
2021impl Deref for ADC140 {
2022    type Target = adc140::RegisterBlock;
2023    #[inline(always)]
2024    fn deref(&self) -> &Self::Target {
2025        unsafe { &*Self::PTR }
2026    }
2027}
2028impl core::fmt::Debug for ADC140 {
2029    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2030        f.debug_struct("ADC140").finish()
2031    }
2032}
2033#[doc = "14bit A/D Converter"]
2034pub mod adc140;
2035#[doc = "Low-Power Analog Comparator"]
2036pub struct ACMPLP {
2037    _marker: PhantomData<*const ()>,
2038}
2039unsafe impl Send for ACMPLP {}
2040impl ACMPLP {
2041    #[doc = r"Pointer to the register block"]
2042    pub const PTR: *const acmplp::RegisterBlock = 0x4008_5e00 as *const _;
2043    #[doc = r"Return the pointer to the register block"]
2044    #[inline(always)]
2045    pub const fn ptr() -> *const acmplp::RegisterBlock {
2046        Self::PTR
2047    }
2048}
2049impl Deref for ACMPLP {
2050    type Target = acmplp::RegisterBlock;
2051    #[inline(always)]
2052    fn deref(&self) -> &Self::Target {
2053        unsafe { &*Self::PTR }
2054    }
2055}
2056impl core::fmt::Debug for ACMPLP {
2057    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2058        f.debug_struct("ACMPLP").finish()
2059    }
2060}
2061#[doc = "Low-Power Analog Comparator"]
2062pub mod acmplp;
2063#[doc = "Temperature Sensor"]
2064pub struct TSN {
2065    _marker: PhantomData<*const ()>,
2066}
2067unsafe impl Send for TSN {}
2068impl TSN {
2069    #[doc = r"Pointer to the register block"]
2070    pub const PTR: *const tsn::RegisterBlock = 0x407e_c000 as *const _;
2071    #[doc = r"Return the pointer to the register block"]
2072    #[inline(always)]
2073    pub const fn ptr() -> *const tsn::RegisterBlock {
2074        Self::PTR
2075    }
2076}
2077impl Deref for TSN {
2078    type Target = tsn::RegisterBlock;
2079    #[inline(always)]
2080    fn deref(&self) -> &Self::Target {
2081        unsafe { &*Self::PTR }
2082    }
2083}
2084impl core::fmt::Debug for TSN {
2085    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2086        f.debug_struct("TSN").finish()
2087    }
2088}
2089#[doc = "Temperature Sensor"]
2090pub mod tsn;
2091#[doc = "Segment LCD Controller/Driver"]
2092pub struct SLCDC {
2093    _marker: PhantomData<*const ()>,
2094}
2095unsafe impl Send for SLCDC {}
2096impl SLCDC {
2097    #[doc = r"Pointer to the register block"]
2098    pub const PTR: *const slcdc::RegisterBlock = 0x4008_2000 as *const _;
2099    #[doc = r"Return the pointer to the register block"]
2100    #[inline(always)]
2101    pub const fn ptr() -> *const slcdc::RegisterBlock {
2102        Self::PTR
2103    }
2104}
2105impl Deref for SLCDC {
2106    type Target = slcdc::RegisterBlock;
2107    #[inline(always)]
2108    fn deref(&self) -> &Self::Target {
2109        unsafe { &*Self::PTR }
2110    }
2111}
2112impl core::fmt::Debug for SLCDC {
2113    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2114        f.debug_struct("SLCDC").finish()
2115    }
2116}
2117#[doc = "Segment LCD Controller/Driver"]
2118pub mod slcdc;
2119#[doc = "OperationalAmplifier"]
2120pub struct OPAMP {
2121    _marker: PhantomData<*const ()>,
2122}
2123unsafe impl Send for OPAMP {}
2124impl OPAMP {
2125    #[doc = r"Pointer to the register block"]
2126    pub const PTR: *const opamp::RegisterBlock = 0x4008_6000 as *const _;
2127    #[doc = r"Return the pointer to the register block"]
2128    #[inline(always)]
2129    pub const fn ptr() -> *const opamp::RegisterBlock {
2130        Self::PTR
2131    }
2132}
2133impl Deref for OPAMP {
2134    type Target = opamp::RegisterBlock;
2135    #[inline(always)]
2136    fn deref(&self) -> &Self::Target {
2137        unsafe { &*Self::PTR }
2138    }
2139}
2140impl core::fmt::Debug for OPAMP {
2141    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2142        f.debug_struct("OPAMP").finish()
2143    }
2144}
2145#[doc = "OperationalAmplifier"]
2146pub mod opamp;
2147#[doc = "Data Transfer Controller"]
2148pub struct DTC {
2149    _marker: PhantomData<*const ()>,
2150}
2151unsafe impl Send for DTC {}
2152impl DTC {
2153    #[doc = r"Pointer to the register block"]
2154    pub const PTR: *const dtc::RegisterBlock = 0x4000_5400 as *const _;
2155    #[doc = r"Return the pointer to the register block"]
2156    #[inline(always)]
2157    pub const fn ptr() -> *const dtc::RegisterBlock {
2158        Self::PTR
2159    }
2160}
2161impl Deref for DTC {
2162    type Target = dtc::RegisterBlock;
2163    #[inline(always)]
2164    fn deref(&self) -> &Self::Target {
2165        unsafe { &*Self::PTR }
2166    }
2167}
2168impl core::fmt::Debug for DTC {
2169    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2170        f.debug_struct("DTC").finish()
2171    }
2172}
2173#[doc = "Data Transfer Controller"]
2174pub mod dtc;
2175#[doc = "Key Interrupt Function"]
2176pub struct KINT {
2177    _marker: PhantomData<*const ()>,
2178}
2179unsafe impl Send for KINT {}
2180impl KINT {
2181    #[doc = r"Pointer to the register block"]
2182    pub const PTR: *const kint::RegisterBlock = 0x4008_0000 as *const _;
2183    #[doc = r"Return the pointer to the register block"]
2184    #[inline(always)]
2185    pub const fn ptr() -> *const kint::RegisterBlock {
2186        Self::PTR
2187    }
2188}
2189impl Deref for KINT {
2190    type Target = kint::RegisterBlock;
2191    #[inline(always)]
2192    fn deref(&self) -> &Self::Target {
2193        unsafe { &*Self::PTR }
2194    }
2195}
2196impl core::fmt::Debug for KINT {
2197    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2198        f.debug_struct("KINT").finish()
2199    }
2200}
2201#[doc = "Key Interrupt Function"]
2202pub mod kint;
2203#[no_mangle]
2204static mut DEVICE_PERIPHERALS: bool = false;
2205#[doc = r" All the peripherals."]
2206#[allow(non_snake_case)]
2207pub struct Peripherals {
2208    #[doc = "POEG"]
2209    pub POEG: POEG,
2210    #[doc = "GPT320"]
2211    pub GPT320: GPT320,
2212    #[doc = "GPT321"]
2213    pub GPT321: GPT321,
2214    #[doc = "GPT322"]
2215    pub GPT322: GPT322,
2216    #[doc = "GPT323"]
2217    pub GPT323: GPT323,
2218    #[doc = "GPT164"]
2219    pub GPT164: GPT164,
2220    #[doc = "GPT165"]
2221    pub GPT165: GPT165,
2222    #[doc = "GPT166"]
2223    pub GPT166: GPT166,
2224    #[doc = "GPT167"]
2225    pub GPT167: GPT167,
2226    #[doc = "GPT168"]
2227    pub GPT168: GPT168,
2228    #[doc = "GPT169"]
2229    pub GPT169: GPT169,
2230    #[doc = "GPT_OPS"]
2231    pub GPT_OPS: GPT_OPS,
2232    #[doc = "AGT0"]
2233    pub AGT0: AGT0,
2234    #[doc = "AGT1"]
2235    pub AGT1: AGT1,
2236    #[doc = "RTC"]
2237    pub RTC: RTC,
2238    #[doc = "SYSTEM"]
2239    pub SYSTEM: SYSTEM,
2240    #[doc = "MSTP"]
2241    pub MSTP: MSTP,
2242    #[doc = "FCACHE"]
2243    pub FCACHE: FCACHE,
2244    #[doc = "ICU"]
2245    pub ICU: ICU,
2246    #[doc = "DMAC0"]
2247    pub DMAC0: DMAC0,
2248    #[doc = "DMAC1"]
2249    pub DMAC1: DMAC1,
2250    #[doc = "DMAC2"]
2251    pub DMAC2: DMAC2,
2252    #[doc = "DMAC3"]
2253    pub DMAC3: DMAC3,
2254    #[doc = "DMA"]
2255    pub DMA: DMA,
2256    #[doc = "DBG"]
2257    pub DBG: DBG,
2258    #[doc = "BUS"]
2259    pub BUS: BUS,
2260    #[doc = "SRAM"]
2261    pub SRAM: SRAM,
2262    #[doc = "MMPU"]
2263    pub MMPU: MMPU,
2264    #[doc = "SMPU"]
2265    pub SMPU: SMPU,
2266    #[doc = "SPMON"]
2267    pub SPMON: SPMON,
2268    #[doc = "MMF"]
2269    pub MMF: MMF,
2270    #[doc = "SPI0"]
2271    pub SPI0: SPI0,
2272    #[doc = "SPI1"]
2273    pub SPI1: SPI1,
2274    #[doc = "SCI0"]
2275    pub SCI0: SCI0,
2276    #[doc = "SCI1"]
2277    pub SCI1: SCI1,
2278    #[doc = "SCI2"]
2279    pub SCI2: SCI2,
2280    #[doc = "SCI3"]
2281    pub SCI3: SCI3,
2282    #[doc = "SCI4"]
2283    pub SCI4: SCI4,
2284    #[doc = "SCI9"]
2285    pub SCI9: SCI9,
2286    #[doc = "IIC0"]
2287    pub IIC0: IIC0,
2288    #[doc = "IIC1"]
2289    pub IIC1: IIC1,
2290    #[doc = "IIC2"]
2291    pub IIC2: IIC2,
2292    #[doc = "CAN0"]
2293    pub CAN0: CAN0,
2294    #[doc = "WDT"]
2295    pub WDT: WDT,
2296    #[doc = "USBFS"]
2297    pub USBFS: USBFS,
2298    #[doc = "IWDT"]
2299    pub IWDT: IWDT,
2300    #[doc = "PORT0"]
2301    pub PORT0: PORT0,
2302    #[doc = "PORT1"]
2303    pub PORT1: PORT1,
2304    #[doc = "PORT2"]
2305    pub PORT2: PORT2,
2306    #[doc = "PORT3"]
2307    pub PORT3: PORT3,
2308    #[doc = "PORT4"]
2309    pub PORT4: PORT4,
2310    #[doc = "PORT5"]
2311    pub PORT5: PORT5,
2312    #[doc = "PORT6"]
2313    pub PORT6: PORT6,
2314    #[doc = "PORT7"]
2315    pub PORT7: PORT7,
2316    #[doc = "PORT8"]
2317    pub PORT8: PORT8,
2318    #[doc = "PORT9"]
2319    pub PORT9: PORT9,
2320    #[doc = "PFS"]
2321    pub PFS: PFS,
2322    #[doc = "PMISC"]
2323    pub PMISC: PMISC,
2324    #[doc = "ELC"]
2325    pub ELC: ELC,
2326    #[doc = "DOC"]
2327    pub DOC: DOC,
2328    #[doc = "CRC"]
2329    pub CRC: CRC,
2330    #[doc = "CAC"]
2331    pub CAC: CAC,
2332    #[doc = "DAC8"]
2333    pub DAC8: DAC8,
2334    #[doc = "DAC12"]
2335    pub DAC12: DAC12,
2336    #[doc = "CTSU"]
2337    pub CTSU: CTSU,
2338    #[doc = "ADC140"]
2339    pub ADC140: ADC140,
2340    #[doc = "ACMPLP"]
2341    pub ACMPLP: ACMPLP,
2342    #[doc = "TSN"]
2343    pub TSN: TSN,
2344    #[doc = "SLCDC"]
2345    pub SLCDC: SLCDC,
2346    #[doc = "OPAMP"]
2347    pub OPAMP: OPAMP,
2348    #[doc = "DTC"]
2349    pub DTC: DTC,
2350    #[doc = "KINT"]
2351    pub KINT: KINT,
2352}
2353impl Peripherals {
2354    #[doc = r" Returns all the peripherals *once*."]
2355    #[cfg(feature = "critical-section")]
2356    #[inline]
2357    pub fn take() -> Option<Self> {
2358        critical_section::with(|_| {
2359            if unsafe { DEVICE_PERIPHERALS } {
2360                return None;
2361            }
2362            Some(unsafe { Peripherals::steal() })
2363        })
2364    }
2365    #[doc = r" Unchecked version of `Peripherals::take`."]
2366    #[doc = r""]
2367    #[doc = r" # Safety"]
2368    #[doc = r""]
2369    #[doc = r" Each of the returned peripherals must be used at most once."]
2370    #[inline]
2371    pub unsafe fn steal() -> Self {
2372        DEVICE_PERIPHERALS = true;
2373        Peripherals {
2374            POEG: POEG {
2375                _marker: PhantomData,
2376            },
2377            GPT320: GPT320 {
2378                _marker: PhantomData,
2379            },
2380            GPT321: GPT321 {
2381                _marker: PhantomData,
2382            },
2383            GPT322: GPT322 {
2384                _marker: PhantomData,
2385            },
2386            GPT323: GPT323 {
2387                _marker: PhantomData,
2388            },
2389            GPT164: GPT164 {
2390                _marker: PhantomData,
2391            },
2392            GPT165: GPT165 {
2393                _marker: PhantomData,
2394            },
2395            GPT166: GPT166 {
2396                _marker: PhantomData,
2397            },
2398            GPT167: GPT167 {
2399                _marker: PhantomData,
2400            },
2401            GPT168: GPT168 {
2402                _marker: PhantomData,
2403            },
2404            GPT169: GPT169 {
2405                _marker: PhantomData,
2406            },
2407            GPT_OPS: GPT_OPS {
2408                _marker: PhantomData,
2409            },
2410            AGT0: AGT0 {
2411                _marker: PhantomData,
2412            },
2413            AGT1: AGT1 {
2414                _marker: PhantomData,
2415            },
2416            RTC: RTC {
2417                _marker: PhantomData,
2418            },
2419            SYSTEM: SYSTEM {
2420                _marker: PhantomData,
2421            },
2422            MSTP: MSTP {
2423                _marker: PhantomData,
2424            },
2425            FCACHE: FCACHE {
2426                _marker: PhantomData,
2427            },
2428            ICU: ICU {
2429                _marker: PhantomData,
2430            },
2431            DMAC0: DMAC0 {
2432                _marker: PhantomData,
2433            },
2434            DMAC1: DMAC1 {
2435                _marker: PhantomData,
2436            },
2437            DMAC2: DMAC2 {
2438                _marker: PhantomData,
2439            },
2440            DMAC3: DMAC3 {
2441                _marker: PhantomData,
2442            },
2443            DMA: DMA {
2444                _marker: PhantomData,
2445            },
2446            DBG: DBG {
2447                _marker: PhantomData,
2448            },
2449            BUS: BUS {
2450                _marker: PhantomData,
2451            },
2452            SRAM: SRAM {
2453                _marker: PhantomData,
2454            },
2455            MMPU: MMPU {
2456                _marker: PhantomData,
2457            },
2458            SMPU: SMPU {
2459                _marker: PhantomData,
2460            },
2461            SPMON: SPMON {
2462                _marker: PhantomData,
2463            },
2464            MMF: MMF {
2465                _marker: PhantomData,
2466            },
2467            SPI0: SPI0 {
2468                _marker: PhantomData,
2469            },
2470            SPI1: SPI1 {
2471                _marker: PhantomData,
2472            },
2473            SCI0: SCI0 {
2474                _marker: PhantomData,
2475            },
2476            SCI1: SCI1 {
2477                _marker: PhantomData,
2478            },
2479            SCI2: SCI2 {
2480                _marker: PhantomData,
2481            },
2482            SCI3: SCI3 {
2483                _marker: PhantomData,
2484            },
2485            SCI4: SCI4 {
2486                _marker: PhantomData,
2487            },
2488            SCI9: SCI9 {
2489                _marker: PhantomData,
2490            },
2491            IIC0: IIC0 {
2492                _marker: PhantomData,
2493            },
2494            IIC1: IIC1 {
2495                _marker: PhantomData,
2496            },
2497            IIC2: IIC2 {
2498                _marker: PhantomData,
2499            },
2500            CAN0: CAN0 {
2501                _marker: PhantomData,
2502            },
2503            WDT: WDT {
2504                _marker: PhantomData,
2505            },
2506            USBFS: USBFS {
2507                _marker: PhantomData,
2508            },
2509            IWDT: IWDT {
2510                _marker: PhantomData,
2511            },
2512            PORT0: PORT0 {
2513                _marker: PhantomData,
2514            },
2515            PORT1: PORT1 {
2516                _marker: PhantomData,
2517            },
2518            PORT2: PORT2 {
2519                _marker: PhantomData,
2520            },
2521            PORT3: PORT3 {
2522                _marker: PhantomData,
2523            },
2524            PORT4: PORT4 {
2525                _marker: PhantomData,
2526            },
2527            PORT5: PORT5 {
2528                _marker: PhantomData,
2529            },
2530            PORT6: PORT6 {
2531                _marker: PhantomData,
2532            },
2533            PORT7: PORT7 {
2534                _marker: PhantomData,
2535            },
2536            PORT8: PORT8 {
2537                _marker: PhantomData,
2538            },
2539            PORT9: PORT9 {
2540                _marker: PhantomData,
2541            },
2542            PFS: PFS {
2543                _marker: PhantomData,
2544            },
2545            PMISC: PMISC {
2546                _marker: PhantomData,
2547            },
2548            ELC: ELC {
2549                _marker: PhantomData,
2550            },
2551            DOC: DOC {
2552                _marker: PhantomData,
2553            },
2554            CRC: CRC {
2555                _marker: PhantomData,
2556            },
2557            CAC: CAC {
2558                _marker: PhantomData,
2559            },
2560            DAC8: DAC8 {
2561                _marker: PhantomData,
2562            },
2563            DAC12: DAC12 {
2564                _marker: PhantomData,
2565            },
2566            CTSU: CTSU {
2567                _marker: PhantomData,
2568            },
2569            ADC140: ADC140 {
2570                _marker: PhantomData,
2571            },
2572            ACMPLP: ACMPLP {
2573                _marker: PhantomData,
2574            },
2575            TSN: TSN {
2576                _marker: PhantomData,
2577            },
2578            SLCDC: SLCDC {
2579                _marker: PhantomData,
2580            },
2581            OPAMP: OPAMP {
2582                _marker: PhantomData,
2583            },
2584            DTC: DTC {
2585                _marker: PhantomData,
2586            },
2587            KINT: KINT {
2588                _marker: PhantomData,
2589            },
2590        }
2591    }
2592}