s32k116_pac/
lib.rs

1#![doc = "Peripheral access API for S32K116 microcontrollers (generated using svd2rust v0.21.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.21.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(const_err)]
4#![deny(dead_code)]
5#![deny(improper_ctypes)]
6#![deny(missing_docs)]
7#![deny(no_mangle_generic_items)]
8#![deny(non_shorthand_field_patterns)]
9#![deny(overflowing_literals)]
10#![deny(path_statements)]
11#![deny(patterns_in_fns_without_body)]
12#![deny(private_in_public)]
13#![deny(unconditional_recursion)]
14#![deny(unused_allocation)]
15#![deny(unused_comparisons)]
16#![deny(unused_parens)]
17#![deny(while_true)]
18#![allow(non_camel_case_types)]
19#![allow(non_snake_case)]
20#![no_std]
21use core::marker::PhantomData;
22use core::ops::Deref;
23#[doc = r"Number available in the NVIC for configuring priority"]
24pub const NVIC_PRIO_BITS: u8 = 2;
25#[cfg(feature = "rt")]
26pub use self::Interrupt as interrupt;
27pub use cortex_m::peripheral::Peripherals as CorePeripherals;
28pub use cortex_m::peripheral::{CBP, CPUID, DCB, DWT, FPB, FPU, ITM, MPU, NVIC, SCB, SYST, TPIU};
29#[cfg(feature = "rt")]
30pub use cortex_m_rt::interrupt;
31#[allow(unused_imports)]
32use generic::*;
33#[doc = r"Common register and bit access and modify traits"]
34pub mod generic;
35#[cfg(feature = "rt")]
36extern "C" {
37    fn DMA0();
38    fn DMA1();
39    fn DMA2();
40    fn DMA3();
41    fn DMA_ERROR();
42    fn ERM_FAULT();
43    fn RTC();
44    fn RTC_SECONDS();
45    fn LPTMR0();
46    fn PORT();
47    fn CAN0_ORED_ERR_WAKEUP();
48    fn CAN0_ORED_0_31_MB();
49    fn FTM0_CH0_7();
50    fn FTM0_FAULT();
51    fn FTM0_OVF_RELOAD();
52    fn FTM1_CH0_7();
53    fn FTM1_FAULT();
54    fn FTM1_OVF_RELOAD();
55    fn FTFC();
56    fn PDB0();
57    fn LPIT0();
58    fn SCG_CMU_LVD_LVWSCG();
59    fn WDOG();
60    fn RCM();
61    fn LPI2C0_MASTER_SLAVE();
62    fn FLEXIO();
63    fn LPSPI0();
64    fn ADC0();
65    fn CMP0();
66    fn LPUART1_RXTX();
67    fn LPUART0_RXTX();
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: DMA0 },
80    Vector { _handler: DMA1 },
81    Vector { _handler: DMA2 },
82    Vector { _handler: DMA3 },
83    Vector {
84        _handler: DMA_ERROR,
85    },
86    Vector {
87        _handler: ERM_FAULT,
88    },
89    Vector { _handler: RTC },
90    Vector {
91        _handler: RTC_SECONDS,
92    },
93    Vector { _handler: LPTMR0 },
94    Vector { _handler: PORT },
95    Vector {
96        _handler: CAN0_ORED_ERR_WAKEUP,
97    },
98    Vector {
99        _handler: CAN0_ORED_0_31_MB,
100    },
101    Vector {
102        _handler: FTM0_CH0_7,
103    },
104    Vector {
105        _handler: FTM0_FAULT,
106    },
107    Vector {
108        _handler: FTM0_OVF_RELOAD,
109    },
110    Vector {
111        _handler: FTM1_CH0_7,
112    },
113    Vector {
114        _handler: FTM1_FAULT,
115    },
116    Vector {
117        _handler: FTM1_OVF_RELOAD,
118    },
119    Vector { _handler: FTFC },
120    Vector { _handler: PDB0 },
121    Vector { _handler: LPIT0 },
122    Vector {
123        _handler: SCG_CMU_LVD_LVWSCG,
124    },
125    Vector { _handler: WDOG },
126    Vector { _handler: RCM },
127    Vector {
128        _handler: LPI2C0_MASTER_SLAVE,
129    },
130    Vector { _handler: FLEXIO },
131    Vector { _handler: LPSPI0 },
132    Vector { _reserved: 0 },
133    Vector { _handler: ADC0 },
134    Vector { _handler: CMP0 },
135    Vector {
136        _handler: LPUART1_RXTX,
137    },
138    Vector {
139        _handler: LPUART0_RXTX,
140    },
141];
142#[doc = r"Enumeration of all the interrupts."]
143#[derive(Copy, Clone, Debug, PartialEq, Eq)]
144#[repr(u16)]
145pub enum Interrupt {
146    #[doc = "0 - DMA0"]
147    DMA0 = 0,
148    #[doc = "1 - DMA1"]
149    DMA1 = 1,
150    #[doc = "2 - DMA2"]
151    DMA2 = 2,
152    #[doc = "3 - DMA3"]
153    DMA3 = 3,
154    #[doc = "4 - DMA_Error"]
155    DMA_ERROR = 4,
156    #[doc = "5 - ERM_fault"]
157    ERM_FAULT = 5,
158    #[doc = "6 - RTC"]
159    RTC = 6,
160    #[doc = "7 - RTC_Seconds"]
161    RTC_SECONDS = 7,
162    #[doc = "8 - LPTMR0"]
163    LPTMR0 = 8,
164    #[doc = "9 - PORT"]
165    PORT = 9,
166    #[doc = "10 - CAN0_ORed_Err_Wakeup"]
167    CAN0_ORED_ERR_WAKEUP = 10,
168    #[doc = "11 - CAN0_ORed_0_31_MB"]
169    CAN0_ORED_0_31_MB = 11,
170    #[doc = "12 - FTM0_Ch0_7"]
171    FTM0_CH0_7 = 12,
172    #[doc = "13 - FTM0_Fault"]
173    FTM0_FAULT = 13,
174    #[doc = "14 - FTM0_Ovf_Reload"]
175    FTM0_OVF_RELOAD = 14,
176    #[doc = "15 - FTM1_Ch0_7"]
177    FTM1_CH0_7 = 15,
178    #[doc = "16 - FTM1_Fault"]
179    FTM1_FAULT = 16,
180    #[doc = "17 - FTM1_Ovf_Reload"]
181    FTM1_OVF_RELOAD = 17,
182    #[doc = "18 - FTFC"]
183    FTFC = 18,
184    #[doc = "19 - PDB0"]
185    PDB0 = 19,
186    #[doc = "20 - LPIT0"]
187    LPIT0 = 20,
188    #[doc = "21 - SCG_CMU_LVD_LVWSCG"]
189    SCG_CMU_LVD_LVWSCG = 21,
190    #[doc = "22 - WDOG"]
191    WDOG = 22,
192    #[doc = "23 - RCM"]
193    RCM = 23,
194    #[doc = "24 - LPI2C0_Master_Slave"]
195    LPI2C0_MASTER_SLAVE = 24,
196    #[doc = "25 - FLEXIO"]
197    FLEXIO = 25,
198    #[doc = "26 - LPSPI0"]
199    LPSPI0 = 26,
200    #[doc = "28 - ADC0"]
201    ADC0 = 28,
202    #[doc = "29 - CMP0"]
203    CMP0 = 29,
204    #[doc = "30 - LPUART1_RxTx"]
205    LPUART1_RXTX = 30,
206    #[doc = "31 - LPUART0_RxTx"]
207    LPUART0_RXTX = 31,
208}
209unsafe impl cortex_m::interrupt::InterruptNumber for Interrupt {
210    #[inline(always)]
211    fn number(self) -> u16 {
212        self as u16
213    }
214}
215#[doc = "CSE_PRAM"]
216pub struct CSE_PRAM {
217    _marker: PhantomData<*const ()>,
218}
219unsafe impl Send for CSE_PRAM {}
220impl CSE_PRAM {
221    #[doc = r"Pointer to the register block"]
222    pub const PTR: *const cse_pram::RegisterBlock = 0x1400_0800 as *const _;
223    #[doc = r"Return the pointer to the register block"]
224    #[inline(always)]
225    pub const fn ptr() -> *const cse_pram::RegisterBlock {
226        Self::PTR
227    }
228}
229impl Deref for CSE_PRAM {
230    type Target = cse_pram::RegisterBlock;
231    #[inline(always)]
232    fn deref(&self) -> &Self::Target {
233        unsafe { &*Self::PTR }
234    }
235}
236impl core::fmt::Debug for CSE_PRAM {
237    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
238        f.debug_struct("CSE_PRAM").finish()
239    }
240}
241#[doc = "CSE_PRAM"]
242pub mod cse_pram;
243#[doc = "AIPS-Lite Bridge"]
244pub struct AIPS {
245    _marker: PhantomData<*const ()>,
246}
247unsafe impl Send for AIPS {}
248impl AIPS {
249    #[doc = r"Pointer to the register block"]
250    pub const PTR: *const aips::RegisterBlock = 0x4000_0000 as *const _;
251    #[doc = r"Return the pointer to the register block"]
252    #[inline(always)]
253    pub const fn ptr() -> *const aips::RegisterBlock {
254        Self::PTR
255    }
256}
257impl Deref for AIPS {
258    type Target = aips::RegisterBlock;
259    #[inline(always)]
260    fn deref(&self) -> &Self::Target {
261        unsafe { &*Self::PTR }
262    }
263}
264impl core::fmt::Debug for AIPS {
265    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
266        f.debug_struct("AIPS").finish()
267    }
268}
269#[doc = "AIPS-Lite Bridge"]
270pub mod aips;
271#[doc = "MSCM"]
272pub struct MSCM {
273    _marker: PhantomData<*const ()>,
274}
275unsafe impl Send for MSCM {}
276impl MSCM {
277    #[doc = r"Pointer to the register block"]
278    pub const PTR: *const mscm::RegisterBlock = 0x4000_1000 as *const _;
279    #[doc = r"Return the pointer to the register block"]
280    #[inline(always)]
281    pub const fn ptr() -> *const mscm::RegisterBlock {
282        Self::PTR
283    }
284}
285impl Deref for MSCM {
286    type Target = mscm::RegisterBlock;
287    #[inline(always)]
288    fn deref(&self) -> &Self::Target {
289        unsafe { &*Self::PTR }
290    }
291}
292impl core::fmt::Debug for MSCM {
293    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
294        f.debug_struct("MSCM").finish()
295    }
296}
297#[doc = "MSCM"]
298pub mod mscm;
299#[doc = "Enhanced Direct Memory Access"]
300pub struct DMA {
301    _marker: PhantomData<*const ()>,
302}
303unsafe impl Send for DMA {}
304impl DMA {
305    #[doc = r"Pointer to the register block"]
306    pub const PTR: *const dma::RegisterBlock = 0x4000_8000 as *const _;
307    #[doc = r"Return the pointer to the register block"]
308    #[inline(always)]
309    pub const fn ptr() -> *const dma::RegisterBlock {
310        Self::PTR
311    }
312}
313impl Deref for DMA {
314    type Target = dma::RegisterBlock;
315    #[inline(always)]
316    fn deref(&self) -> &Self::Target {
317        unsafe { &*Self::PTR }
318    }
319}
320impl core::fmt::Debug for DMA {
321    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
322        f.debug_struct("DMA").finish()
323    }
324}
325#[doc = "Enhanced Direct Memory Access"]
326pub mod dma;
327#[doc = "ERM"]
328pub struct ERM {
329    _marker: PhantomData<*const ()>,
330}
331unsafe impl Send for ERM {}
332impl ERM {
333    #[doc = r"Pointer to the register block"]
334    pub const PTR: *const erm::RegisterBlock = 0x4001_8000 as *const _;
335    #[doc = r"Return the pointer to the register block"]
336    #[inline(always)]
337    pub const fn ptr() -> *const erm::RegisterBlock {
338        Self::PTR
339    }
340}
341impl Deref for ERM {
342    type Target = erm::RegisterBlock;
343    #[inline(always)]
344    fn deref(&self) -> &Self::Target {
345        unsafe { &*Self::PTR }
346    }
347}
348impl core::fmt::Debug for ERM {
349    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
350        f.debug_struct("ERM").finish()
351    }
352}
353#[doc = "ERM"]
354pub mod erm;
355#[doc = "Error Injection Module"]
356pub struct EIM {
357    _marker: PhantomData<*const ()>,
358}
359unsafe impl Send for EIM {}
360impl EIM {
361    #[doc = r"Pointer to the register block"]
362    pub const PTR: *const eim::RegisterBlock = 0x4001_9000 as *const _;
363    #[doc = r"Return the pointer to the register block"]
364    #[inline(always)]
365    pub const fn ptr() -> *const eim::RegisterBlock {
366        Self::PTR
367    }
368}
369impl Deref for EIM {
370    type Target = eim::RegisterBlock;
371    #[inline(always)]
372    fn deref(&self) -> &Self::Target {
373        unsafe { &*Self::PTR }
374    }
375}
376impl core::fmt::Debug for EIM {
377    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
378        f.debug_struct("EIM").finish()
379    }
380}
381#[doc = "Error Injection Module"]
382pub mod eim;
383#[doc = "FTFC"]
384pub struct FTFC {
385    _marker: PhantomData<*const ()>,
386}
387unsafe impl Send for FTFC {}
388impl FTFC {
389    #[doc = r"Pointer to the register block"]
390    pub const PTR: *const ftfc::RegisterBlock = 0x4002_0000 as *const _;
391    #[doc = r"Return the pointer to the register block"]
392    #[inline(always)]
393    pub const fn ptr() -> *const ftfc::RegisterBlock {
394        Self::PTR
395    }
396}
397impl Deref for FTFC {
398    type Target = ftfc::RegisterBlock;
399    #[inline(always)]
400    fn deref(&self) -> &Self::Target {
401        unsafe { &*Self::PTR }
402    }
403}
404impl core::fmt::Debug for FTFC {
405    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
406        f.debug_struct("FTFC").finish()
407    }
408}
409#[doc = "FTFC"]
410pub mod ftfc;
411#[doc = "DMA channel multiplexor"]
412pub struct DMAMUX {
413    _marker: PhantomData<*const ()>,
414}
415unsafe impl Send for DMAMUX {}
416impl DMAMUX {
417    #[doc = r"Pointer to the register block"]
418    pub const PTR: *const dmamux::RegisterBlock = 0x4002_1000 as *const _;
419    #[doc = r"Return the pointer to the register block"]
420    #[inline(always)]
421    pub const fn ptr() -> *const dmamux::RegisterBlock {
422        Self::PTR
423    }
424}
425impl Deref for DMAMUX {
426    type Target = dmamux::RegisterBlock;
427    #[inline(always)]
428    fn deref(&self) -> &Self::Target {
429        unsafe { &*Self::PTR }
430    }
431}
432impl core::fmt::Debug for DMAMUX {
433    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
434        f.debug_struct("DMAMUX").finish()
435    }
436}
437#[doc = "DMA channel multiplexor"]
438pub mod dmamux;
439#[doc = "Flex Controller Area Network module"]
440pub struct CAN0 {
441    _marker: PhantomData<*const ()>,
442}
443unsafe impl Send for CAN0 {}
444impl CAN0 {
445    #[doc = r"Pointer to the register block"]
446    pub const PTR: *const can0::RegisterBlock = 0x4002_4000 as *const _;
447    #[doc = r"Return the pointer to the register block"]
448    #[inline(always)]
449    pub const fn ptr() -> *const can0::RegisterBlock {
450        Self::PTR
451    }
452}
453impl Deref for CAN0 {
454    type Target = can0::RegisterBlock;
455    #[inline(always)]
456    fn deref(&self) -> &Self::Target {
457        unsafe { &*Self::PTR }
458    }
459}
460impl core::fmt::Debug for CAN0 {
461    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
462        f.debug_struct("CAN0").finish()
463    }
464}
465#[doc = "Flex Controller Area Network module"]
466pub mod can0;
467#[doc = "The LPSPI Memory Map/Register Definition can be found here."]
468pub struct LPSPI0 {
469    _marker: PhantomData<*const ()>,
470}
471unsafe impl Send for LPSPI0 {}
472impl LPSPI0 {
473    #[doc = r"Pointer to the register block"]
474    pub const PTR: *const lpspi0::RegisterBlock = 0x4002_c000 as *const _;
475    #[doc = r"Return the pointer to the register block"]
476    #[inline(always)]
477    pub const fn ptr() -> *const lpspi0::RegisterBlock {
478        Self::PTR
479    }
480}
481impl Deref for LPSPI0 {
482    type Target = lpspi0::RegisterBlock;
483    #[inline(always)]
484    fn deref(&self) -> &Self::Target {
485        unsafe { &*Self::PTR }
486    }
487}
488impl core::fmt::Debug for LPSPI0 {
489    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
490        f.debug_struct("LPSPI0").finish()
491    }
492}
493#[doc = "The LPSPI Memory Map/Register Definition can be found here."]
494pub mod lpspi0;
495#[doc = "Cyclic Redundancy Check"]
496pub struct CRC {
497    _marker: PhantomData<*const ()>,
498}
499unsafe impl Send for CRC {}
500impl CRC {
501    #[doc = r"Pointer to the register block"]
502    pub const PTR: *const crc::RegisterBlock = 0x4003_2000 as *const _;
503    #[doc = r"Return the pointer to the register block"]
504    #[inline(always)]
505    pub const fn ptr() -> *const crc::RegisterBlock {
506        Self::PTR
507    }
508}
509impl Deref for CRC {
510    type Target = crc::RegisterBlock;
511    #[inline(always)]
512    fn deref(&self) -> &Self::Target {
513        unsafe { &*Self::PTR }
514    }
515}
516impl core::fmt::Debug for CRC {
517    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
518        f.debug_struct("CRC").finish()
519    }
520}
521#[doc = "Cyclic Redundancy Check"]
522pub mod crc;
523#[doc = "Programmable Delay Block"]
524pub struct PDB0 {
525    _marker: PhantomData<*const ()>,
526}
527unsafe impl Send for PDB0 {}
528impl PDB0 {
529    #[doc = r"Pointer to the register block"]
530    pub const PTR: *const pdb0::RegisterBlock = 0x4003_6000 as *const _;
531    #[doc = r"Return the pointer to the register block"]
532    #[inline(always)]
533    pub const fn ptr() -> *const pdb0::RegisterBlock {
534        Self::PTR
535    }
536}
537impl Deref for PDB0 {
538    type Target = pdb0::RegisterBlock;
539    #[inline(always)]
540    fn deref(&self) -> &Self::Target {
541        unsafe { &*Self::PTR }
542    }
543}
544impl core::fmt::Debug for PDB0 {
545    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
546        f.debug_struct("PDB0").finish()
547    }
548}
549#[doc = "Programmable Delay Block"]
550pub mod pdb0;
551#[doc = "Low Power Periodic Interrupt Timer (LPIT)"]
552pub struct LPIT0 {
553    _marker: PhantomData<*const ()>,
554}
555unsafe impl Send for LPIT0 {}
556impl LPIT0 {
557    #[doc = r"Pointer to the register block"]
558    pub const PTR: *const lpit0::RegisterBlock = 0x4003_7000 as *const _;
559    #[doc = r"Return the pointer to the register block"]
560    #[inline(always)]
561    pub const fn ptr() -> *const lpit0::RegisterBlock {
562        Self::PTR
563    }
564}
565impl Deref for LPIT0 {
566    type Target = lpit0::RegisterBlock;
567    #[inline(always)]
568    fn deref(&self) -> &Self::Target {
569        unsafe { &*Self::PTR }
570    }
571}
572impl core::fmt::Debug for LPIT0 {
573    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
574        f.debug_struct("LPIT0").finish()
575    }
576}
577#[doc = "Low Power Periodic Interrupt Timer (LPIT)"]
578pub mod lpit0;
579#[doc = "FlexTimer Module"]
580pub struct FTM0 {
581    _marker: PhantomData<*const ()>,
582}
583unsafe impl Send for FTM0 {}
584impl FTM0 {
585    #[doc = r"Pointer to the register block"]
586    pub const PTR: *const ftm0::RegisterBlock = 0x4003_8000 as *const _;
587    #[doc = r"Return the pointer to the register block"]
588    #[inline(always)]
589    pub const fn ptr() -> *const ftm0::RegisterBlock {
590        Self::PTR
591    }
592}
593impl Deref for FTM0 {
594    type Target = ftm0::RegisterBlock;
595    #[inline(always)]
596    fn deref(&self) -> &Self::Target {
597        unsafe { &*Self::PTR }
598    }
599}
600impl core::fmt::Debug for FTM0 {
601    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
602        f.debug_struct("FTM0").finish()
603    }
604}
605#[doc = "FlexTimer Module"]
606pub mod ftm0;
607#[doc = "FlexTimer Module"]
608pub struct FTM1 {
609    _marker: PhantomData<*const ()>,
610}
611unsafe impl Send for FTM1 {}
612impl FTM1 {
613    #[doc = r"Pointer to the register block"]
614    pub const PTR: *const ftm1::RegisterBlock = 0x4003_9000 as *const _;
615    #[doc = r"Return the pointer to the register block"]
616    #[inline(always)]
617    pub const fn ptr() -> *const ftm1::RegisterBlock {
618        Self::PTR
619    }
620}
621impl Deref for FTM1 {
622    type Target = ftm1::RegisterBlock;
623    #[inline(always)]
624    fn deref(&self) -> &Self::Target {
625        unsafe { &*Self::PTR }
626    }
627}
628impl core::fmt::Debug for FTM1 {
629    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
630        f.debug_struct("FTM1").finish()
631    }
632}
633#[doc = "FlexTimer Module"]
634pub mod ftm1;
635#[doc = "Analog-to-Digital Converter"]
636pub struct ADC0 {
637    _marker: PhantomData<*const ()>,
638}
639unsafe impl Send for ADC0 {}
640impl ADC0 {
641    #[doc = r"Pointer to the register block"]
642    pub const PTR: *const adc0::RegisterBlock = 0x4003_b000 as *const _;
643    #[doc = r"Return the pointer to the register block"]
644    #[inline(always)]
645    pub const fn ptr() -> *const adc0::RegisterBlock {
646        Self::PTR
647    }
648}
649impl Deref for ADC0 {
650    type Target = adc0::RegisterBlock;
651    #[inline(always)]
652    fn deref(&self) -> &Self::Target {
653        unsafe { &*Self::PTR }
654    }
655}
656impl core::fmt::Debug for ADC0 {
657    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
658        f.debug_struct("ADC0").finish()
659    }
660}
661#[doc = "Analog-to-Digital Converter"]
662pub mod adc0;
663#[doc = "Secure Real Time Clock"]
664pub struct RTC {
665    _marker: PhantomData<*const ()>,
666}
667unsafe impl Send for RTC {}
668impl RTC {
669    #[doc = r"Pointer to the register block"]
670    pub const PTR: *const rtc::RegisterBlock = 0x4003_d000 as *const _;
671    #[doc = r"Return the pointer to the register block"]
672    #[inline(always)]
673    pub const fn ptr() -> *const rtc::RegisterBlock {
674        Self::PTR
675    }
676}
677impl Deref for RTC {
678    type Target = rtc::RegisterBlock;
679    #[inline(always)]
680    fn deref(&self) -> &Self::Target {
681        unsafe { &*Self::PTR }
682    }
683}
684impl core::fmt::Debug for RTC {
685    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
686        f.debug_struct("RTC").finish()
687    }
688}
689#[doc = "Secure Real Time Clock"]
690pub mod rtc;
691#[doc = "CMU_FC"]
692pub struct CMU_FC_0 {
693    _marker: PhantomData<*const ()>,
694}
695unsafe impl Send for CMU_FC_0 {}
696impl CMU_FC_0 {
697    #[doc = r"Pointer to the register block"]
698    pub const PTR: *const cmu_fc_0::RegisterBlock = 0x4003_e000 as *const _;
699    #[doc = r"Return the pointer to the register block"]
700    #[inline(always)]
701    pub const fn ptr() -> *const cmu_fc_0::RegisterBlock {
702        Self::PTR
703    }
704}
705impl Deref for CMU_FC_0 {
706    type Target = cmu_fc_0::RegisterBlock;
707    #[inline(always)]
708    fn deref(&self) -> &Self::Target {
709        unsafe { &*Self::PTR }
710    }
711}
712impl core::fmt::Debug for CMU_FC_0 {
713    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
714        f.debug_struct("CMU_FC_0").finish()
715    }
716}
717#[doc = "CMU_FC"]
718pub mod cmu_fc_0;
719#[doc = "CMU_FC"]
720pub struct CMU_FC_1 {
721    _marker: PhantomData<*const ()>,
722}
723unsafe impl Send for CMU_FC_1 {}
724impl CMU_FC_1 {
725    #[doc = r"Pointer to the register block"]
726    pub const PTR: *const cmu_fc_1::RegisterBlock = 0x4003_f000 as *const _;
727    #[doc = r"Return the pointer to the register block"]
728    #[inline(always)]
729    pub const fn ptr() -> *const cmu_fc_1::RegisterBlock {
730        Self::PTR
731    }
732}
733impl Deref for CMU_FC_1 {
734    type Target = cmu_fc_1::RegisterBlock;
735    #[inline(always)]
736    fn deref(&self) -> &Self::Target {
737        unsafe { &*Self::PTR }
738    }
739}
740impl core::fmt::Debug for CMU_FC_1 {
741    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
742        f.debug_struct("CMU_FC_1").finish()
743    }
744}
745#[doc = "CMU_FC"]
746pub mod cmu_fc_1;
747#[doc = "Low Power Timer"]
748pub struct LPTMR0 {
749    _marker: PhantomData<*const ()>,
750}
751unsafe impl Send for LPTMR0 {}
752impl LPTMR0 {
753    #[doc = r"Pointer to the register block"]
754    pub const PTR: *const lptmr0::RegisterBlock = 0x4004_0000 as *const _;
755    #[doc = r"Return the pointer to the register block"]
756    #[inline(always)]
757    pub const fn ptr() -> *const lptmr0::RegisterBlock {
758        Self::PTR
759    }
760}
761impl Deref for LPTMR0 {
762    type Target = lptmr0::RegisterBlock;
763    #[inline(always)]
764    fn deref(&self) -> &Self::Target {
765        unsafe { &*Self::PTR }
766    }
767}
768impl core::fmt::Debug for LPTMR0 {
769    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
770        f.debug_struct("LPTMR0").finish()
771    }
772}
773#[doc = "Low Power Timer"]
774pub mod lptmr0;
775#[doc = "System Integration Module"]
776pub struct SIM {
777    _marker: PhantomData<*const ()>,
778}
779unsafe impl Send for SIM {}
780impl SIM {
781    #[doc = r"Pointer to the register block"]
782    pub const PTR: *const sim::RegisterBlock = 0x4004_8000 as *const _;
783    #[doc = r"Return the pointer to the register block"]
784    #[inline(always)]
785    pub const fn ptr() -> *const sim::RegisterBlock {
786        Self::PTR
787    }
788}
789impl Deref for SIM {
790    type Target = sim::RegisterBlock;
791    #[inline(always)]
792    fn deref(&self) -> &Self::Target {
793        unsafe { &*Self::PTR }
794    }
795}
796impl core::fmt::Debug for SIM {
797    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
798        f.debug_struct("SIM").finish()
799    }
800}
801#[doc = "System Integration Module"]
802pub mod sim;
803#[doc = "Pin Control and Interrupts"]
804pub struct PORTA {
805    _marker: PhantomData<*const ()>,
806}
807unsafe impl Send for PORTA {}
808impl PORTA {
809    #[doc = r"Pointer to the register block"]
810    pub const PTR: *const porta::RegisterBlock = 0x4004_9000 as *const _;
811    #[doc = r"Return the pointer to the register block"]
812    #[inline(always)]
813    pub const fn ptr() -> *const porta::RegisterBlock {
814        Self::PTR
815    }
816}
817impl Deref for PORTA {
818    type Target = porta::RegisterBlock;
819    #[inline(always)]
820    fn deref(&self) -> &Self::Target {
821        unsafe { &*Self::PTR }
822    }
823}
824impl core::fmt::Debug for PORTA {
825    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
826        f.debug_struct("PORTA").finish()
827    }
828}
829#[doc = "Pin Control and Interrupts"]
830pub mod porta;
831#[doc = "Pin Control and Interrupts"]
832pub struct PORTB {
833    _marker: PhantomData<*const ()>,
834}
835unsafe impl Send for PORTB {}
836impl PORTB {
837    #[doc = r"Pointer to the register block"]
838    pub const PTR: *const portb::RegisterBlock = 0x4004_a000 as *const _;
839    #[doc = r"Return the pointer to the register block"]
840    #[inline(always)]
841    pub const fn ptr() -> *const portb::RegisterBlock {
842        Self::PTR
843    }
844}
845impl Deref for PORTB {
846    type Target = portb::RegisterBlock;
847    #[inline(always)]
848    fn deref(&self) -> &Self::Target {
849        unsafe { &*Self::PTR }
850    }
851}
852impl core::fmt::Debug for PORTB {
853    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
854        f.debug_struct("PORTB").finish()
855    }
856}
857#[doc = "Pin Control and Interrupts"]
858pub mod portb;
859#[doc = "Pin Control and Interrupts"]
860pub struct PORTC {
861    _marker: PhantomData<*const ()>,
862}
863unsafe impl Send for PORTC {}
864impl PORTC {
865    #[doc = r"Pointer to the register block"]
866    pub const PTR: *const portc::RegisterBlock = 0x4004_b000 as *const _;
867    #[doc = r"Return the pointer to the register block"]
868    #[inline(always)]
869    pub const fn ptr() -> *const portc::RegisterBlock {
870        Self::PTR
871    }
872}
873impl Deref for PORTC {
874    type Target = portc::RegisterBlock;
875    #[inline(always)]
876    fn deref(&self) -> &Self::Target {
877        unsafe { &*Self::PTR }
878    }
879}
880impl core::fmt::Debug for PORTC {
881    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
882        f.debug_struct("PORTC").finish()
883    }
884}
885#[doc = "Pin Control and Interrupts"]
886pub mod portc;
887#[doc = "Pin Control and Interrupts"]
888pub struct PORTD {
889    _marker: PhantomData<*const ()>,
890}
891unsafe impl Send for PORTD {}
892impl PORTD {
893    #[doc = r"Pointer to the register block"]
894    pub const PTR: *const portd::RegisterBlock = 0x4004_c000 as *const _;
895    #[doc = r"Return the pointer to the register block"]
896    #[inline(always)]
897    pub const fn ptr() -> *const portd::RegisterBlock {
898        Self::PTR
899    }
900}
901impl Deref for PORTD {
902    type Target = portd::RegisterBlock;
903    #[inline(always)]
904    fn deref(&self) -> &Self::Target {
905        unsafe { &*Self::PTR }
906    }
907}
908impl core::fmt::Debug for PORTD {
909    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
910        f.debug_struct("PORTD").finish()
911    }
912}
913#[doc = "Pin Control and Interrupts"]
914pub mod portd;
915#[doc = "Pin Control and Interrupts"]
916pub struct PORTE {
917    _marker: PhantomData<*const ()>,
918}
919unsafe impl Send for PORTE {}
920impl PORTE {
921    #[doc = r"Pointer to the register block"]
922    pub const PTR: *const porte::RegisterBlock = 0x4004_d000 as *const _;
923    #[doc = r"Return the pointer to the register block"]
924    #[inline(always)]
925    pub const fn ptr() -> *const porte::RegisterBlock {
926        Self::PTR
927    }
928}
929impl Deref for PORTE {
930    type Target = porte::RegisterBlock;
931    #[inline(always)]
932    fn deref(&self) -> &Self::Target {
933        unsafe { &*Self::PTR }
934    }
935}
936impl core::fmt::Debug for PORTE {
937    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
938        f.debug_struct("PORTE").finish()
939    }
940}
941#[doc = "Pin Control and Interrupts"]
942pub mod porte;
943#[doc = "Watchdog timer"]
944pub struct WDOG {
945    _marker: PhantomData<*const ()>,
946}
947unsafe impl Send for WDOG {}
948impl WDOG {
949    #[doc = r"Pointer to the register block"]
950    pub const PTR: *const wdog::RegisterBlock = 0x4005_2000 as *const _;
951    #[doc = r"Return the pointer to the register block"]
952    #[inline(always)]
953    pub const fn ptr() -> *const wdog::RegisterBlock {
954        Self::PTR
955    }
956}
957impl Deref for WDOG {
958    type Target = wdog::RegisterBlock;
959    #[inline(always)]
960    fn deref(&self) -> &Self::Target {
961        unsafe { &*Self::PTR }
962    }
963}
964impl core::fmt::Debug for WDOG {
965    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
966        f.debug_struct("WDOG").finish()
967    }
968}
969#[doc = "Watchdog timer"]
970pub mod wdog;
971#[doc = "The FLEXIO Memory Map/Register Definition can be found here."]
972pub struct FLEXIO {
973    _marker: PhantomData<*const ()>,
974}
975unsafe impl Send for FLEXIO {}
976impl FLEXIO {
977    #[doc = r"Pointer to the register block"]
978    pub const PTR: *const flexio::RegisterBlock = 0x4005_a000 as *const _;
979    #[doc = r"Return the pointer to the register block"]
980    #[inline(always)]
981    pub const fn ptr() -> *const flexio::RegisterBlock {
982        Self::PTR
983    }
984}
985impl Deref for FLEXIO {
986    type Target = flexio::RegisterBlock;
987    #[inline(always)]
988    fn deref(&self) -> &Self::Target {
989        unsafe { &*Self::PTR }
990    }
991}
992impl core::fmt::Debug for FLEXIO {
993    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
994        f.debug_struct("FLEXIO").finish()
995    }
996}
997#[doc = "The FLEXIO Memory Map/Register Definition can be found here."]
998pub mod flexio;
999#[doc = "TRGMUX"]
1000pub struct TRGMUX {
1001    _marker: PhantomData<*const ()>,
1002}
1003unsafe impl Send for TRGMUX {}
1004impl TRGMUX {
1005    #[doc = r"Pointer to the register block"]
1006    pub const PTR: *const trgmux::RegisterBlock = 0x4006_3000 as *const _;
1007    #[doc = r"Return the pointer to the register block"]
1008    #[inline(always)]
1009    pub const fn ptr() -> *const trgmux::RegisterBlock {
1010        Self::PTR
1011    }
1012}
1013impl Deref for TRGMUX {
1014    type Target = trgmux::RegisterBlock;
1015    #[inline(always)]
1016    fn deref(&self) -> &Self::Target {
1017        unsafe { &*Self::PTR }
1018    }
1019}
1020impl core::fmt::Debug for TRGMUX {
1021    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1022        f.debug_struct("TRGMUX").finish()
1023    }
1024}
1025#[doc = "TRGMUX"]
1026pub mod trgmux;
1027#[doc = "System Clock Generator"]
1028pub struct SCG {
1029    _marker: PhantomData<*const ()>,
1030}
1031unsafe impl Send for SCG {}
1032impl SCG {
1033    #[doc = r"Pointer to the register block"]
1034    pub const PTR: *const scg::RegisterBlock = 0x4006_4000 as *const _;
1035    #[doc = r"Return the pointer to the register block"]
1036    #[inline(always)]
1037    pub const fn ptr() -> *const scg::RegisterBlock {
1038        Self::PTR
1039    }
1040}
1041impl Deref for SCG {
1042    type Target = scg::RegisterBlock;
1043    #[inline(always)]
1044    fn deref(&self) -> &Self::Target {
1045        unsafe { &*Self::PTR }
1046    }
1047}
1048impl core::fmt::Debug for SCG {
1049    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1050        f.debug_struct("SCG").finish()
1051    }
1052}
1053#[doc = "System Clock Generator"]
1054pub mod scg;
1055#[doc = "PCC"]
1056pub struct PCC {
1057    _marker: PhantomData<*const ()>,
1058}
1059unsafe impl Send for PCC {}
1060impl PCC {
1061    #[doc = r"Pointer to the register block"]
1062    pub const PTR: *const pcc::RegisterBlock = 0x4006_5000 as *const _;
1063    #[doc = r"Return the pointer to the register block"]
1064    #[inline(always)]
1065    pub const fn ptr() -> *const pcc::RegisterBlock {
1066        Self::PTR
1067    }
1068}
1069impl Deref for PCC {
1070    type Target = pcc::RegisterBlock;
1071    #[inline(always)]
1072    fn deref(&self) -> &Self::Target {
1073        unsafe { &*Self::PTR }
1074    }
1075}
1076impl core::fmt::Debug for PCC {
1077    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1078        f.debug_struct("PCC").finish()
1079    }
1080}
1081#[doc = "PCC"]
1082pub mod pcc;
1083#[doc = "The LPI2C Memory Map/Register Definition can be found here."]
1084pub struct LPI2C0 {
1085    _marker: PhantomData<*const ()>,
1086}
1087unsafe impl Send for LPI2C0 {}
1088impl LPI2C0 {
1089    #[doc = r"Pointer to the register block"]
1090    pub const PTR: *const lpi2c0::RegisterBlock = 0x4006_6000 as *const _;
1091    #[doc = r"Return the pointer to the register block"]
1092    #[inline(always)]
1093    pub const fn ptr() -> *const lpi2c0::RegisterBlock {
1094        Self::PTR
1095    }
1096}
1097impl Deref for LPI2C0 {
1098    type Target = lpi2c0::RegisterBlock;
1099    #[inline(always)]
1100    fn deref(&self) -> &Self::Target {
1101        unsafe { &*Self::PTR }
1102    }
1103}
1104impl core::fmt::Debug for LPI2C0 {
1105    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1106        f.debug_struct("LPI2C0").finish()
1107    }
1108}
1109#[doc = "The LPI2C Memory Map/Register Definition can be found here."]
1110pub mod lpi2c0;
1111#[doc = "Universal Asynchronous Receiver/Transmitter"]
1112pub struct LPUART0 {
1113    _marker: PhantomData<*const ()>,
1114}
1115unsafe impl Send for LPUART0 {}
1116impl LPUART0 {
1117    #[doc = r"Pointer to the register block"]
1118    pub const PTR: *const lpuart0::RegisterBlock = 0x4006_a000 as *const _;
1119    #[doc = r"Return the pointer to the register block"]
1120    #[inline(always)]
1121    pub const fn ptr() -> *const lpuart0::RegisterBlock {
1122        Self::PTR
1123    }
1124}
1125impl Deref for LPUART0 {
1126    type Target = lpuart0::RegisterBlock;
1127    #[inline(always)]
1128    fn deref(&self) -> &Self::Target {
1129        unsafe { &*Self::PTR }
1130    }
1131}
1132impl core::fmt::Debug for LPUART0 {
1133    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1134        f.debug_struct("LPUART0").finish()
1135    }
1136}
1137#[doc = "Universal Asynchronous Receiver/Transmitter"]
1138pub mod lpuart0;
1139#[doc = "Universal Asynchronous Receiver/Transmitter"]
1140pub struct LPUART1 {
1141    _marker: PhantomData<*const ()>,
1142}
1143unsafe impl Send for LPUART1 {}
1144impl LPUART1 {
1145    #[doc = r"Pointer to the register block"]
1146    pub const PTR: *const lpuart1::RegisterBlock = 0x4006_b000 as *const _;
1147    #[doc = r"Return the pointer to the register block"]
1148    #[inline(always)]
1149    pub const fn ptr() -> *const lpuart1::RegisterBlock {
1150        Self::PTR
1151    }
1152}
1153impl Deref for LPUART1 {
1154    type Target = lpuart1::RegisterBlock;
1155    #[inline(always)]
1156    fn deref(&self) -> &Self::Target {
1157        unsafe { &*Self::PTR }
1158    }
1159}
1160impl core::fmt::Debug for LPUART1 {
1161    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1162        f.debug_struct("LPUART1").finish()
1163    }
1164}
1165#[doc = "Universal Asynchronous Receiver/Transmitter"]
1166pub mod lpuart1;
1167#[doc = "High-Speed Comparator (CMP), Voltage Reference (VREF) Digital-to-Analog Converter (DAC), and Analog Mux (ANMUX)"]
1168pub struct CMP0 {
1169    _marker: PhantomData<*const ()>,
1170}
1171unsafe impl Send for CMP0 {}
1172impl CMP0 {
1173    #[doc = r"Pointer to the register block"]
1174    pub const PTR: *const cmp0::RegisterBlock = 0x4007_3000 as *const _;
1175    #[doc = r"Return the pointer to the register block"]
1176    #[inline(always)]
1177    pub const fn ptr() -> *const cmp0::RegisterBlock {
1178        Self::PTR
1179    }
1180}
1181impl Deref for CMP0 {
1182    type Target = cmp0::RegisterBlock;
1183    #[inline(always)]
1184    fn deref(&self) -> &Self::Target {
1185        unsafe { &*Self::PTR }
1186    }
1187}
1188impl core::fmt::Debug for CMP0 {
1189    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1190        f.debug_struct("CMP0").finish()
1191    }
1192}
1193#[doc = "High-Speed Comparator (CMP), Voltage Reference (VREF) Digital-to-Analog Converter (DAC), and Analog Mux (ANMUX)"]
1194pub mod cmp0;
1195#[doc = "PMC"]
1196pub struct PMC {
1197    _marker: PhantomData<*const ()>,
1198}
1199unsafe impl Send for PMC {}
1200impl PMC {
1201    #[doc = r"Pointer to the register block"]
1202    pub const PTR: *const pmc::RegisterBlock = 0x4007_d000 as *const _;
1203    #[doc = r"Return the pointer to the register block"]
1204    #[inline(always)]
1205    pub const fn ptr() -> *const pmc::RegisterBlock {
1206        Self::PTR
1207    }
1208}
1209impl Deref for PMC {
1210    type Target = pmc::RegisterBlock;
1211    #[inline(always)]
1212    fn deref(&self) -> &Self::Target {
1213        unsafe { &*Self::PTR }
1214    }
1215}
1216impl core::fmt::Debug for PMC {
1217    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1218        f.debug_struct("PMC").finish()
1219    }
1220}
1221#[doc = "PMC"]
1222pub mod pmc;
1223#[doc = "System Mode Controller"]
1224pub struct SMC {
1225    _marker: PhantomData<*const ()>,
1226}
1227unsafe impl Send for SMC {}
1228impl SMC {
1229    #[doc = r"Pointer to the register block"]
1230    pub const PTR: *const smc::RegisterBlock = 0x4007_e000 as *const _;
1231    #[doc = r"Return the pointer to the register block"]
1232    #[inline(always)]
1233    pub const fn ptr() -> *const smc::RegisterBlock {
1234        Self::PTR
1235    }
1236}
1237impl Deref for SMC {
1238    type Target = smc::RegisterBlock;
1239    #[inline(always)]
1240    fn deref(&self) -> &Self::Target {
1241        unsafe { &*Self::PTR }
1242    }
1243}
1244impl core::fmt::Debug for SMC {
1245    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1246        f.debug_struct("SMC").finish()
1247    }
1248}
1249#[doc = "System Mode Controller"]
1250pub mod smc;
1251#[doc = "Reset Control Module"]
1252pub struct RCM {
1253    _marker: PhantomData<*const ()>,
1254}
1255unsafe impl Send for RCM {}
1256impl RCM {
1257    #[doc = r"Pointer to the register block"]
1258    pub const PTR: *const rcm::RegisterBlock = 0x4007_f000 as *const _;
1259    #[doc = r"Return the pointer to the register block"]
1260    #[inline(always)]
1261    pub const fn ptr() -> *const rcm::RegisterBlock {
1262        Self::PTR
1263    }
1264}
1265impl Deref for RCM {
1266    type Target = rcm::RegisterBlock;
1267    #[inline(always)]
1268    fn deref(&self) -> &Self::Target {
1269        unsafe { &*Self::PTR }
1270    }
1271}
1272impl core::fmt::Debug for RCM {
1273    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1274        f.debug_struct("RCM").finish()
1275    }
1276}
1277#[doc = "Reset Control Module"]
1278pub mod rcm;
1279#[doc = "General Purpose Input/Output"]
1280pub struct PTA {
1281    _marker: PhantomData<*const ()>,
1282}
1283unsafe impl Send for PTA {}
1284impl PTA {
1285    #[doc = r"Pointer to the register block"]
1286    pub const PTR: *const pta::RegisterBlock = 0x400f_f000 as *const _;
1287    #[doc = r"Return the pointer to the register block"]
1288    #[inline(always)]
1289    pub const fn ptr() -> *const pta::RegisterBlock {
1290        Self::PTR
1291    }
1292}
1293impl Deref for PTA {
1294    type Target = pta::RegisterBlock;
1295    #[inline(always)]
1296    fn deref(&self) -> &Self::Target {
1297        unsafe { &*Self::PTR }
1298    }
1299}
1300impl core::fmt::Debug for PTA {
1301    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1302        f.debug_struct("PTA").finish()
1303    }
1304}
1305#[doc = "General Purpose Input/Output"]
1306pub mod pta;
1307#[doc = "General Purpose Input/Output"]
1308pub struct PTB {
1309    _marker: PhantomData<*const ()>,
1310}
1311unsafe impl Send for PTB {}
1312impl PTB {
1313    #[doc = r"Pointer to the register block"]
1314    pub const PTR: *const ptb::RegisterBlock = 0x400f_f040 as *const _;
1315    #[doc = r"Return the pointer to the register block"]
1316    #[inline(always)]
1317    pub const fn ptr() -> *const ptb::RegisterBlock {
1318        Self::PTR
1319    }
1320}
1321impl Deref for PTB {
1322    type Target = ptb::RegisterBlock;
1323    #[inline(always)]
1324    fn deref(&self) -> &Self::Target {
1325        unsafe { &*Self::PTR }
1326    }
1327}
1328impl core::fmt::Debug for PTB {
1329    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1330        f.debug_struct("PTB").finish()
1331    }
1332}
1333#[doc = "General Purpose Input/Output"]
1334pub mod ptb;
1335#[doc = "General Purpose Input/Output"]
1336pub struct PTC {
1337    _marker: PhantomData<*const ()>,
1338}
1339unsafe impl Send for PTC {}
1340impl PTC {
1341    #[doc = r"Pointer to the register block"]
1342    pub const PTR: *const ptc::RegisterBlock = 0x400f_f080 as *const _;
1343    #[doc = r"Return the pointer to the register block"]
1344    #[inline(always)]
1345    pub const fn ptr() -> *const ptc::RegisterBlock {
1346        Self::PTR
1347    }
1348}
1349impl Deref for PTC {
1350    type Target = ptc::RegisterBlock;
1351    #[inline(always)]
1352    fn deref(&self) -> &Self::Target {
1353        unsafe { &*Self::PTR }
1354    }
1355}
1356impl core::fmt::Debug for PTC {
1357    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1358        f.debug_struct("PTC").finish()
1359    }
1360}
1361#[doc = "General Purpose Input/Output"]
1362pub mod ptc;
1363#[doc = "General Purpose Input/Output"]
1364pub struct PTD {
1365    _marker: PhantomData<*const ()>,
1366}
1367unsafe impl Send for PTD {}
1368impl PTD {
1369    #[doc = r"Pointer to the register block"]
1370    pub const PTR: *const ptd::RegisterBlock = 0x400f_f0c0 as *const _;
1371    #[doc = r"Return the pointer to the register block"]
1372    #[inline(always)]
1373    pub const fn ptr() -> *const ptd::RegisterBlock {
1374        Self::PTR
1375    }
1376}
1377impl Deref for PTD {
1378    type Target = ptd::RegisterBlock;
1379    #[inline(always)]
1380    fn deref(&self) -> &Self::Target {
1381        unsafe { &*Self::PTR }
1382    }
1383}
1384impl core::fmt::Debug for PTD {
1385    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1386        f.debug_struct("PTD").finish()
1387    }
1388}
1389#[doc = "General Purpose Input/Output"]
1390pub mod ptd;
1391#[doc = "General Purpose Input/Output"]
1392pub struct PTE {
1393    _marker: PhantomData<*const ()>,
1394}
1395unsafe impl Send for PTE {}
1396impl PTE {
1397    #[doc = r"Pointer to the register block"]
1398    pub const PTR: *const pte::RegisterBlock = 0x400f_f100 as *const _;
1399    #[doc = r"Return the pointer to the register block"]
1400    #[inline(always)]
1401    pub const fn ptr() -> *const pte::RegisterBlock {
1402        Self::PTR
1403    }
1404}
1405impl Deref for PTE {
1406    type Target = pte::RegisterBlock;
1407    #[inline(always)]
1408    fn deref(&self) -> &Self::Target {
1409        unsafe { &*Self::PTR }
1410    }
1411}
1412impl core::fmt::Debug for PTE {
1413    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1414        f.debug_struct("PTE").finish()
1415    }
1416}
1417#[doc = "General Purpose Input/Output"]
1418pub mod pte;
1419#[doc = "System Control Registers"]
1420pub struct S32_SCB {
1421    _marker: PhantomData<*const ()>,
1422}
1423unsafe impl Send for S32_SCB {}
1424impl S32_SCB {
1425    #[doc = r"Pointer to the register block"]
1426    pub const PTR: *const s32_scb::RegisterBlock = 0xe000_e000 as *const _;
1427    #[doc = r"Return the pointer to the register block"]
1428    #[inline(always)]
1429    pub const fn ptr() -> *const s32_scb::RegisterBlock {
1430        Self::PTR
1431    }
1432}
1433impl Deref for S32_SCB {
1434    type Target = s32_scb::RegisterBlock;
1435    #[inline(always)]
1436    fn deref(&self) -> &Self::Target {
1437        unsafe { &*Self::PTR }
1438    }
1439}
1440impl core::fmt::Debug for S32_SCB {
1441    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1442        f.debug_struct("S32_SCB").finish()
1443    }
1444}
1445#[doc = "System Control Registers"]
1446pub mod s32_scb;
1447#[doc = "System timer"]
1448pub struct S32_SYSTICK {
1449    _marker: PhantomData<*const ()>,
1450}
1451unsafe impl Send for S32_SYSTICK {}
1452impl S32_SYSTICK {
1453    #[doc = r"Pointer to the register block"]
1454    pub const PTR: *const s32_sys_tick::RegisterBlock = 0xe000_e010 as *const _;
1455    #[doc = r"Return the pointer to the register block"]
1456    #[inline(always)]
1457    pub const fn ptr() -> *const s32_sys_tick::RegisterBlock {
1458        Self::PTR
1459    }
1460}
1461impl Deref for S32_SYSTICK {
1462    type Target = s32_sys_tick::RegisterBlock;
1463    #[inline(always)]
1464    fn deref(&self) -> &Self::Target {
1465        unsafe { &*Self::PTR }
1466    }
1467}
1468impl core::fmt::Debug for S32_SYSTICK {
1469    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1470        f.debug_struct("S32_SYSTICK").finish()
1471    }
1472}
1473#[doc = "System timer"]
1474pub mod s32_sys_tick;
1475#[doc = "Nested Vectored Interrupt Controller"]
1476pub struct S32_NVIC {
1477    _marker: PhantomData<*const ()>,
1478}
1479unsafe impl Send for S32_NVIC {}
1480impl S32_NVIC {
1481    #[doc = r"Pointer to the register block"]
1482    pub const PTR: *const s32_nvic::RegisterBlock = 0xe000_e100 as *const _;
1483    #[doc = r"Return the pointer to the register block"]
1484    #[inline(always)]
1485    pub const fn ptr() -> *const s32_nvic::RegisterBlock {
1486        Self::PTR
1487    }
1488}
1489impl Deref for S32_NVIC {
1490    type Target = s32_nvic::RegisterBlock;
1491    #[inline(always)]
1492    fn deref(&self) -> &Self::Target {
1493        unsafe { &*Self::PTR }
1494    }
1495}
1496impl core::fmt::Debug for S32_NVIC {
1497    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1498        f.debug_struct("S32_NVIC").finish()
1499    }
1500}
1501#[doc = "Nested Vectored Interrupt Controller"]
1502pub mod s32_nvic;
1503#[doc = "Local Memory Controller"]
1504pub struct LMEM {
1505    _marker: PhantomData<*const ()>,
1506}
1507unsafe impl Send for LMEM {}
1508impl LMEM {
1509    #[doc = r"Pointer to the register block"]
1510    pub const PTR: *const lmem::RegisterBlock = 0xe008_2000 as *const _;
1511    #[doc = r"Return the pointer to the register block"]
1512    #[inline(always)]
1513    pub const fn ptr() -> *const lmem::RegisterBlock {
1514        Self::PTR
1515    }
1516}
1517impl Deref for LMEM {
1518    type Target = lmem::RegisterBlock;
1519    #[inline(always)]
1520    fn deref(&self) -> &Self::Target {
1521        unsafe { &*Self::PTR }
1522    }
1523}
1524impl core::fmt::Debug for LMEM {
1525    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1526        f.debug_struct("LMEM").finish()
1527    }
1528}
1529#[doc = "Local Memory Controller"]
1530pub mod lmem;
1531#[doc = "MTB data watchpoint and trace"]
1532pub struct MTB_DWT {
1533    _marker: PhantomData<*const ()>,
1534}
1535unsafe impl Send for MTB_DWT {}
1536impl MTB_DWT {
1537    #[doc = r"Pointer to the register block"]
1538    pub const PTR: *const mtb_dwt::RegisterBlock = 0xf000_1000 as *const _;
1539    #[doc = r"Return the pointer to the register block"]
1540    #[inline(always)]
1541    pub const fn ptr() -> *const mtb_dwt::RegisterBlock {
1542        Self::PTR
1543    }
1544}
1545impl Deref for MTB_DWT {
1546    type Target = mtb_dwt::RegisterBlock;
1547    #[inline(always)]
1548    fn deref(&self) -> &Self::Target {
1549        unsafe { &*Self::PTR }
1550    }
1551}
1552impl core::fmt::Debug for MTB_DWT {
1553    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1554        f.debug_struct("MTB_DWT").finish()
1555    }
1556}
1557#[doc = "MTB data watchpoint and trace"]
1558pub mod mtb_dwt;
1559#[doc = "Core Platform Miscellaneous Control Module"]
1560pub struct MCM {
1561    _marker: PhantomData<*const ()>,
1562}
1563unsafe impl Send for MCM {}
1564impl MCM {
1565    #[doc = r"Pointer to the register block"]
1566    pub const PTR: *const mcm::RegisterBlock = 0xf000_3000 as *const _;
1567    #[doc = r"Return the pointer to the register block"]
1568    #[inline(always)]
1569    pub const fn ptr() -> *const mcm::RegisterBlock {
1570        Self::PTR
1571    }
1572}
1573impl Deref for MCM {
1574    type Target = mcm::RegisterBlock;
1575    #[inline(always)]
1576    fn deref(&self) -> &Self::Target {
1577        unsafe { &*Self::PTR }
1578    }
1579}
1580impl core::fmt::Debug for MCM {
1581    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1582        f.debug_struct("MCM").finish()
1583    }
1584}
1585#[doc = "Core Platform Miscellaneous Control Module"]
1586pub mod mcm;
1587#[no_mangle]
1588static mut DEVICE_PERIPHERALS: bool = false;
1589#[doc = r"All the peripherals"]
1590#[allow(non_snake_case)]
1591pub struct Peripherals {
1592    #[doc = "CSE_PRAM"]
1593    pub CSE_PRAM: CSE_PRAM,
1594    #[doc = "AIPS"]
1595    pub AIPS: AIPS,
1596    #[doc = "MSCM"]
1597    pub MSCM: MSCM,
1598    #[doc = "DMA"]
1599    pub DMA: DMA,
1600    #[doc = "ERM"]
1601    pub ERM: ERM,
1602    #[doc = "EIM"]
1603    pub EIM: EIM,
1604    #[doc = "FTFC"]
1605    pub FTFC: FTFC,
1606    #[doc = "DMAMUX"]
1607    pub DMAMUX: DMAMUX,
1608    #[doc = "CAN0"]
1609    pub CAN0: CAN0,
1610    #[doc = "LPSPI0"]
1611    pub LPSPI0: LPSPI0,
1612    #[doc = "CRC"]
1613    pub CRC: CRC,
1614    #[doc = "PDB0"]
1615    pub PDB0: PDB0,
1616    #[doc = "LPIT0"]
1617    pub LPIT0: LPIT0,
1618    #[doc = "FTM0"]
1619    pub FTM0: FTM0,
1620    #[doc = "FTM1"]
1621    pub FTM1: FTM1,
1622    #[doc = "ADC0"]
1623    pub ADC0: ADC0,
1624    #[doc = "RTC"]
1625    pub RTC: RTC,
1626    #[doc = "CMU_FC_0"]
1627    pub CMU_FC_0: CMU_FC_0,
1628    #[doc = "CMU_FC_1"]
1629    pub CMU_FC_1: CMU_FC_1,
1630    #[doc = "LPTMR0"]
1631    pub LPTMR0: LPTMR0,
1632    #[doc = "SIM"]
1633    pub SIM: SIM,
1634    #[doc = "PORTA"]
1635    pub PORTA: PORTA,
1636    #[doc = "PORTB"]
1637    pub PORTB: PORTB,
1638    #[doc = "PORTC"]
1639    pub PORTC: PORTC,
1640    #[doc = "PORTD"]
1641    pub PORTD: PORTD,
1642    #[doc = "PORTE"]
1643    pub PORTE: PORTE,
1644    #[doc = "WDOG"]
1645    pub WDOG: WDOG,
1646    #[doc = "FLEXIO"]
1647    pub FLEXIO: FLEXIO,
1648    #[doc = "TRGMUX"]
1649    pub TRGMUX: TRGMUX,
1650    #[doc = "SCG"]
1651    pub SCG: SCG,
1652    #[doc = "PCC"]
1653    pub PCC: PCC,
1654    #[doc = "LPI2C0"]
1655    pub LPI2C0: LPI2C0,
1656    #[doc = "LPUART0"]
1657    pub LPUART0: LPUART0,
1658    #[doc = "LPUART1"]
1659    pub LPUART1: LPUART1,
1660    #[doc = "CMP0"]
1661    pub CMP0: CMP0,
1662    #[doc = "PMC"]
1663    pub PMC: PMC,
1664    #[doc = "SMC"]
1665    pub SMC: SMC,
1666    #[doc = "RCM"]
1667    pub RCM: RCM,
1668    #[doc = "PTA"]
1669    pub PTA: PTA,
1670    #[doc = "PTB"]
1671    pub PTB: PTB,
1672    #[doc = "PTC"]
1673    pub PTC: PTC,
1674    #[doc = "PTD"]
1675    pub PTD: PTD,
1676    #[doc = "PTE"]
1677    pub PTE: PTE,
1678    #[doc = "S32_SCB"]
1679    pub S32_SCB: S32_SCB,
1680    #[doc = "S32_SYSTICK"]
1681    pub S32_SYSTICK: S32_SYSTICK,
1682    #[doc = "S32_NVIC"]
1683    pub S32_NVIC: S32_NVIC,
1684    #[doc = "LMEM"]
1685    pub LMEM: LMEM,
1686    #[doc = "MTB_DWT"]
1687    pub MTB_DWT: MTB_DWT,
1688    #[doc = "MCM"]
1689    pub MCM: MCM,
1690}
1691impl Peripherals {
1692    #[doc = r"Returns all the peripherals *once*"]
1693    #[inline]
1694    pub fn take() -> Option<Self> {
1695        cortex_m::interrupt::free(|_| {
1696            if unsafe { DEVICE_PERIPHERALS } {
1697                None
1698            } else {
1699                Some(unsafe { Peripherals::steal() })
1700            }
1701        })
1702    }
1703    #[doc = r"Unchecked version of `Peripherals::take`"]
1704    #[inline]
1705    pub unsafe fn steal() -> Self {
1706        DEVICE_PERIPHERALS = true;
1707        Peripherals {
1708            CSE_PRAM: CSE_PRAM {
1709                _marker: PhantomData,
1710            },
1711            AIPS: AIPS {
1712                _marker: PhantomData,
1713            },
1714            MSCM: MSCM {
1715                _marker: PhantomData,
1716            },
1717            DMA: DMA {
1718                _marker: PhantomData,
1719            },
1720            ERM: ERM {
1721                _marker: PhantomData,
1722            },
1723            EIM: EIM {
1724                _marker: PhantomData,
1725            },
1726            FTFC: FTFC {
1727                _marker: PhantomData,
1728            },
1729            DMAMUX: DMAMUX {
1730                _marker: PhantomData,
1731            },
1732            CAN0: CAN0 {
1733                _marker: PhantomData,
1734            },
1735            LPSPI0: LPSPI0 {
1736                _marker: PhantomData,
1737            },
1738            CRC: CRC {
1739                _marker: PhantomData,
1740            },
1741            PDB0: PDB0 {
1742                _marker: PhantomData,
1743            },
1744            LPIT0: LPIT0 {
1745                _marker: PhantomData,
1746            },
1747            FTM0: FTM0 {
1748                _marker: PhantomData,
1749            },
1750            FTM1: FTM1 {
1751                _marker: PhantomData,
1752            },
1753            ADC0: ADC0 {
1754                _marker: PhantomData,
1755            },
1756            RTC: RTC {
1757                _marker: PhantomData,
1758            },
1759            CMU_FC_0: CMU_FC_0 {
1760                _marker: PhantomData,
1761            },
1762            CMU_FC_1: CMU_FC_1 {
1763                _marker: PhantomData,
1764            },
1765            LPTMR0: LPTMR0 {
1766                _marker: PhantomData,
1767            },
1768            SIM: SIM {
1769                _marker: PhantomData,
1770            },
1771            PORTA: PORTA {
1772                _marker: PhantomData,
1773            },
1774            PORTB: PORTB {
1775                _marker: PhantomData,
1776            },
1777            PORTC: PORTC {
1778                _marker: PhantomData,
1779            },
1780            PORTD: PORTD {
1781                _marker: PhantomData,
1782            },
1783            PORTE: PORTE {
1784                _marker: PhantomData,
1785            },
1786            WDOG: WDOG {
1787                _marker: PhantomData,
1788            },
1789            FLEXIO: FLEXIO {
1790                _marker: PhantomData,
1791            },
1792            TRGMUX: TRGMUX {
1793                _marker: PhantomData,
1794            },
1795            SCG: SCG {
1796                _marker: PhantomData,
1797            },
1798            PCC: PCC {
1799                _marker: PhantomData,
1800            },
1801            LPI2C0: LPI2C0 {
1802                _marker: PhantomData,
1803            },
1804            LPUART0: LPUART0 {
1805                _marker: PhantomData,
1806            },
1807            LPUART1: LPUART1 {
1808                _marker: PhantomData,
1809            },
1810            CMP0: CMP0 {
1811                _marker: PhantomData,
1812            },
1813            PMC: PMC {
1814                _marker: PhantomData,
1815            },
1816            SMC: SMC {
1817                _marker: PhantomData,
1818            },
1819            RCM: RCM {
1820                _marker: PhantomData,
1821            },
1822            PTA: PTA {
1823                _marker: PhantomData,
1824            },
1825            PTB: PTB {
1826                _marker: PhantomData,
1827            },
1828            PTC: PTC {
1829                _marker: PhantomData,
1830            },
1831            PTD: PTD {
1832                _marker: PhantomData,
1833            },
1834            PTE: PTE {
1835                _marker: PhantomData,
1836            },
1837            S32_SCB: S32_SCB {
1838                _marker: PhantomData,
1839            },
1840            S32_SYSTICK: S32_SYSTICK {
1841                _marker: PhantomData,
1842            },
1843            S32_NVIC: S32_NVIC {
1844                _marker: PhantomData,
1845            },
1846            LMEM: LMEM {
1847                _marker: PhantomData,
1848            },
1849            MTB_DWT: MTB_DWT {
1850                _marker: PhantomData,
1851            },
1852            MCM: MCM {
1853                _marker: PhantomData,
1854            },
1855        }
1856    }
1857}