1#![doc = "Peripheral access API for ESP32-S3 microcontrollers (generated using svd2rust v0.35.0 ( ))\n\nYou can find an overview of the generated API [here].\n\nAPI features to be included in the [next] svd2rust 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.35.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"]
2#![allow(non_camel_case_types)]
3#![allow(non_snake_case)]
4#![doc(html_logo_url = "https://avatars.githubusercontent.com/u/46717278")]
5#![no_std]
6use core::marker::PhantomData;
7use core::ops::Deref;
8#[doc = r"Number available in the NVIC for configuring priority"]
9pub const NVIC_PRIO_BITS: u8 = 0;
10#[allow(unused_imports)]
11use generic::*;
12#[doc = r"Common register and bit access and modify traits"]
13pub mod generic;
14#[cfg(feature = "rt")]
15extern "C" {
16 fn WIFI_MAC();
17 fn WIFI_NMI();
18 fn WIFI_PWR();
19 fn WIFI_BB();
20 fn BT_MAC();
21 fn BT_BB();
22 fn BT_BB_NMI();
23 fn RWBT();
24 fn RWBLE();
25 fn RWBT_NMI();
26 fn RWBLE_NMI();
27 fn I2C_MASTER();
28 fn SLC0();
29 fn SLC1();
30 fn UHCI0();
31 fn UHCI1();
32 fn GPIO();
33 fn GPIO_NMI();
34 fn GPIO_INTR_2();
35 fn GPIO_NMI_2();
36 fn SPI1();
37 fn SPI2();
38 fn SPI3();
39 fn LCD_CAM();
40 fn I2S0();
41 fn I2S1();
42 fn UART0();
43 fn UART1();
44 fn UART2();
45 fn SDIO_HOST();
46 fn MCPWM0();
47 fn MCPWM1();
48 fn LEDC();
49 fn EFUSE();
50 fn TWAI0();
51 fn USB();
52 fn RTC_CORE();
53 fn RMT();
54 fn PCNT();
55 fn I2C_EXT0();
56 fn I2C_EXT1();
57 fn SPI2_DMA();
58 fn SPI3_DMA();
59 fn WDT();
60 fn TIMER1();
61 fn TIMER2();
62 fn TG0_T0_LEVEL();
63 fn TG0_T1_LEVEL();
64 fn TG0_WDT_LEVEL();
65 fn TG1_T0_LEVEL();
66 fn TG1_T1_LEVEL();
67 fn TG1_WDT_LEVEL();
68 fn CACHE_IA();
69 fn SYSTIMER_TARGET0();
70 fn SYSTIMER_TARGET1();
71 fn SYSTIMER_TARGET2();
72 fn SPI_MEM_REJECT_CACHE();
73 fn DCACHE_PRELOAD0();
74 fn ICACHE_PRELOAD0();
75 fn DCACHE_SYNC0();
76 fn ICACHE_SYNC0();
77 fn APB_ADC();
78 fn DMA_IN_CH0();
79 fn DMA_IN_CH1();
80 fn DMA_IN_CH2();
81 fn DMA_IN_CH3();
82 fn DMA_IN_CH4();
83 fn DMA_OUT_CH0();
84 fn DMA_OUT_CH1();
85 fn DMA_OUT_CH2();
86 fn DMA_OUT_CH3();
87 fn DMA_OUT_CH4();
88 fn RSA();
89 fn SHA();
90 fn FROM_CPU_INTR0();
91 fn FROM_CPU_INTR1();
92 fn FROM_CPU_INTR2();
93 fn FROM_CPU_INTR3();
94 fn ASSIST_DEBUG();
95 fn DMA_APBPERI_PMS();
96 fn CORE0_IRAM0_PMS();
97 fn CORE0_DRAM0_PMS();
98 fn CORE0_PIF_PMS();
99 fn CORE0_PIF_PMS_SIZE();
100 fn CORE1_IRAM0_PMS();
101 fn CORE1_DRAM0_PMS();
102 fn CORE1_PIF_PMS();
103 fn CORE1_PIF_PMS_SIZE();
104 fn BACKUP_PMS_VIOLATE();
105 fn CACHE_CORE0_ACS();
106 fn CACHE_CORE1_ACS();
107 fn USB_DEVICE();
108 fn PERI_BACKUP();
109 fn DMA_EXTMEM_REJECT();
110}
111#[doc(hidden)]
112#[repr(C)]
113pub union Vector {
114 pub _handler: unsafe extern "C" fn(),
115 _reserved: u32,
116}
117#[cfg(feature = "rt")]
118#[link_section = ".rwtext"]
119#[doc(hidden)]
120pub static __INTERRUPTS: [Vector; 99] = [
121 Vector { _handler: WIFI_MAC },
122 Vector { _handler: WIFI_NMI },
123 Vector { _handler: WIFI_PWR },
124 Vector { _handler: WIFI_BB },
125 Vector { _handler: BT_MAC },
126 Vector { _handler: BT_BB },
127 Vector {
128 _handler: BT_BB_NMI,
129 },
130 Vector { _handler: RWBT },
131 Vector { _handler: RWBLE },
132 Vector { _handler: RWBT_NMI },
133 Vector {
134 _handler: RWBLE_NMI,
135 },
136 Vector {
137 _handler: I2C_MASTER,
138 },
139 Vector { _handler: SLC0 },
140 Vector { _handler: SLC1 },
141 Vector { _handler: UHCI0 },
142 Vector { _handler: UHCI1 },
143 Vector { _handler: GPIO },
144 Vector { _handler: GPIO_NMI },
145 Vector {
146 _handler: GPIO_INTR_2,
147 },
148 Vector {
149 _handler: GPIO_NMI_2,
150 },
151 Vector { _handler: SPI1 },
152 Vector { _handler: SPI2 },
153 Vector { _handler: SPI3 },
154 Vector { _reserved: 0 },
155 Vector { _handler: LCD_CAM },
156 Vector { _handler: I2S0 },
157 Vector { _handler: I2S1 },
158 Vector { _handler: UART0 },
159 Vector { _handler: UART1 },
160 Vector { _handler: UART2 },
161 Vector {
162 _handler: SDIO_HOST,
163 },
164 Vector { _handler: MCPWM0 },
165 Vector { _handler: MCPWM1 },
166 Vector { _reserved: 0 },
167 Vector { _reserved: 0 },
168 Vector { _handler: LEDC },
169 Vector { _handler: EFUSE },
170 Vector { _handler: TWAI0 },
171 Vector { _handler: USB },
172 Vector { _handler: RTC_CORE },
173 Vector { _handler: RMT },
174 Vector { _handler: PCNT },
175 Vector { _handler: I2C_EXT0 },
176 Vector { _handler: I2C_EXT1 },
177 Vector { _handler: SPI2_DMA },
178 Vector { _handler: SPI3_DMA },
179 Vector { _reserved: 0 },
180 Vector { _handler: WDT },
181 Vector { _handler: TIMER1 },
182 Vector { _handler: TIMER2 },
183 Vector {
184 _handler: TG0_T0_LEVEL,
185 },
186 Vector {
187 _handler: TG0_T1_LEVEL,
188 },
189 Vector {
190 _handler: TG0_WDT_LEVEL,
191 },
192 Vector {
193 _handler: TG1_T0_LEVEL,
194 },
195 Vector {
196 _handler: TG1_T1_LEVEL,
197 },
198 Vector {
199 _handler: TG1_WDT_LEVEL,
200 },
201 Vector { _handler: CACHE_IA },
202 Vector {
203 _handler: SYSTIMER_TARGET0,
204 },
205 Vector {
206 _handler: SYSTIMER_TARGET1,
207 },
208 Vector {
209 _handler: SYSTIMER_TARGET2,
210 },
211 Vector {
212 _handler: SPI_MEM_REJECT_CACHE,
213 },
214 Vector {
215 _handler: DCACHE_PRELOAD0,
216 },
217 Vector {
218 _handler: ICACHE_PRELOAD0,
219 },
220 Vector {
221 _handler: DCACHE_SYNC0,
222 },
223 Vector {
224 _handler: ICACHE_SYNC0,
225 },
226 Vector { _handler: APB_ADC },
227 Vector {
228 _handler: DMA_IN_CH0,
229 },
230 Vector {
231 _handler: DMA_IN_CH1,
232 },
233 Vector {
234 _handler: DMA_IN_CH2,
235 },
236 Vector {
237 _handler: DMA_IN_CH3,
238 },
239 Vector {
240 _handler: DMA_IN_CH4,
241 },
242 Vector {
243 _handler: DMA_OUT_CH0,
244 },
245 Vector {
246 _handler: DMA_OUT_CH1,
247 },
248 Vector {
249 _handler: DMA_OUT_CH2,
250 },
251 Vector {
252 _handler: DMA_OUT_CH3,
253 },
254 Vector {
255 _handler: DMA_OUT_CH4,
256 },
257 Vector { _handler: RSA },
258 Vector { _handler: SHA },
259 Vector { _reserved: 0 },
260 Vector {
261 _handler: FROM_CPU_INTR0,
262 },
263 Vector {
264 _handler: FROM_CPU_INTR1,
265 },
266 Vector {
267 _handler: FROM_CPU_INTR2,
268 },
269 Vector {
270 _handler: FROM_CPU_INTR3,
271 },
272 Vector {
273 _handler: ASSIST_DEBUG,
274 },
275 Vector {
276 _handler: DMA_APBPERI_PMS,
277 },
278 Vector {
279 _handler: CORE0_IRAM0_PMS,
280 },
281 Vector {
282 _handler: CORE0_DRAM0_PMS,
283 },
284 Vector {
285 _handler: CORE0_PIF_PMS,
286 },
287 Vector {
288 _handler: CORE0_PIF_PMS_SIZE,
289 },
290 Vector {
291 _handler: CORE1_IRAM0_PMS,
292 },
293 Vector {
294 _handler: CORE1_DRAM0_PMS,
295 },
296 Vector {
297 _handler: CORE1_PIF_PMS,
298 },
299 Vector {
300 _handler: CORE1_PIF_PMS_SIZE,
301 },
302 Vector {
303 _handler: BACKUP_PMS_VIOLATE,
304 },
305 Vector {
306 _handler: CACHE_CORE0_ACS,
307 },
308 Vector {
309 _handler: CACHE_CORE1_ACS,
310 },
311 Vector {
312 _handler: USB_DEVICE,
313 },
314 Vector {
315 _handler: PERI_BACKUP,
316 },
317 Vector {
318 _handler: DMA_EXTMEM_REJECT,
319 },
320];
321#[doc = r"Enumeration of all the interrupts."]
322#[cfg_attr(feature = "defmt", derive(defmt::Format))]
323#[derive(Copy, Clone, Debug, PartialEq, Eq)]
324#[repr(u16)]
325pub enum Interrupt {
326 #[doc = "0 - WIFI_MAC"]
327 WIFI_MAC = 0,
328 #[doc = "1 - WIFI_NMI"]
329 WIFI_NMI = 1,
330 #[doc = "2 - WIFI_PWR"]
331 WIFI_PWR = 2,
332 #[doc = "3 - WIFI_BB"]
333 WIFI_BB = 3,
334 #[doc = "4 - BT_MAC"]
335 BT_MAC = 4,
336 #[doc = "5 - BT_BB"]
337 BT_BB = 5,
338 #[doc = "6 - BT_BB_NMI"]
339 BT_BB_NMI = 6,
340 #[doc = "7 - RWBT"]
341 RWBT = 7,
342 #[doc = "8 - RWBLE"]
343 RWBLE = 8,
344 #[doc = "9 - RWBT_NMI"]
345 RWBT_NMI = 9,
346 #[doc = "10 - RWBLE_NMI"]
347 RWBLE_NMI = 10,
348 #[doc = "11 - I2C_MASTER"]
349 I2C_MASTER = 11,
350 #[doc = "12 - SLC0"]
351 SLC0 = 12,
352 #[doc = "13 - SLC1"]
353 SLC1 = 13,
354 #[doc = "14 - UHCI0"]
355 UHCI0 = 14,
356 #[doc = "15 - UHCI1"]
357 UHCI1 = 15,
358 #[doc = "16 - GPIO"]
359 GPIO = 16,
360 #[doc = "17 - GPIO_NMI"]
361 GPIO_NMI = 17,
362 #[doc = "18 - GPIO_INTR_2"]
363 GPIO_INTR_2 = 18,
364 #[doc = "19 - GPIO_NMI_2"]
365 GPIO_NMI_2 = 19,
366 #[doc = "20 - SPI1"]
367 SPI1 = 20,
368 #[doc = "21 - SPI2"]
369 SPI2 = 21,
370 #[doc = "22 - SPI3"]
371 SPI3 = 22,
372 #[doc = "24 - LCD_CAM"]
373 LCD_CAM = 24,
374 #[doc = "25 - I2S0"]
375 I2S0 = 25,
376 #[doc = "26 - I2S1"]
377 I2S1 = 26,
378 #[doc = "27 - UART0"]
379 UART0 = 27,
380 #[doc = "28 - UART1"]
381 UART1 = 28,
382 #[doc = "29 - UART2"]
383 UART2 = 29,
384 #[doc = "30 - SDIO_HOST"]
385 SDIO_HOST = 30,
386 #[doc = "31 - MCPWM0"]
387 MCPWM0 = 31,
388 #[doc = "32 - MCPWM1"]
389 MCPWM1 = 32,
390 #[doc = "35 - LEDC"]
391 LEDC = 35,
392 #[doc = "36 - EFUSE"]
393 EFUSE = 36,
394 #[doc = "37 - TWAI0"]
395 TWAI0 = 37,
396 #[doc = "38 - USB"]
397 USB = 38,
398 #[doc = "39 - RTC_CORE"]
399 RTC_CORE = 39,
400 #[doc = "40 - RMT"]
401 RMT = 40,
402 #[doc = "41 - PCNT"]
403 PCNT = 41,
404 #[doc = "42 - I2C_EXT0"]
405 I2C_EXT0 = 42,
406 #[doc = "43 - I2C_EXT1"]
407 I2C_EXT1 = 43,
408 #[doc = "44 - SPI2_DMA"]
409 SPI2_DMA = 44,
410 #[doc = "45 - SPI3_DMA"]
411 SPI3_DMA = 45,
412 #[doc = "47 - WDT"]
413 WDT = 47,
414 #[doc = "48 - TIMER1"]
415 TIMER1 = 48,
416 #[doc = "49 - TIMER2"]
417 TIMER2 = 49,
418 #[doc = "50 - TG0_T0_LEVEL"]
419 TG0_T0_LEVEL = 50,
420 #[doc = "51 - TG0_T1_LEVEL"]
421 TG0_T1_LEVEL = 51,
422 #[doc = "52 - TG0_WDT_LEVEL"]
423 TG0_WDT_LEVEL = 52,
424 #[doc = "53 - TG1_T0_LEVEL"]
425 TG1_T0_LEVEL = 53,
426 #[doc = "54 - TG1_T1_LEVEL"]
427 TG1_T1_LEVEL = 54,
428 #[doc = "55 - TG1_WDT_LEVEL"]
429 TG1_WDT_LEVEL = 55,
430 #[doc = "56 - CACHE_IA"]
431 CACHE_IA = 56,
432 #[doc = "57 - SYSTIMER_TARGET0"]
433 SYSTIMER_TARGET0 = 57,
434 #[doc = "58 - SYSTIMER_TARGET1"]
435 SYSTIMER_TARGET1 = 58,
436 #[doc = "59 - SYSTIMER_TARGET2"]
437 SYSTIMER_TARGET2 = 59,
438 #[doc = "60 - SPI_MEM_REJECT_CACHE"]
439 SPI_MEM_REJECT_CACHE = 60,
440 #[doc = "61 - DCACHE_PRELOAD0"]
441 DCACHE_PRELOAD0 = 61,
442 #[doc = "62 - ICACHE_PRELOAD0"]
443 ICACHE_PRELOAD0 = 62,
444 #[doc = "63 - DCACHE_SYNC0"]
445 DCACHE_SYNC0 = 63,
446 #[doc = "64 - ICACHE_SYNC0"]
447 ICACHE_SYNC0 = 64,
448 #[doc = "65 - APB_ADC"]
449 APB_ADC = 65,
450 #[doc = "66 - DMA_IN_CH0"]
451 DMA_IN_CH0 = 66,
452 #[doc = "67 - DMA_IN_CH1"]
453 DMA_IN_CH1 = 67,
454 #[doc = "68 - DMA_IN_CH2"]
455 DMA_IN_CH2 = 68,
456 #[doc = "69 - DMA_IN_CH3"]
457 DMA_IN_CH3 = 69,
458 #[doc = "70 - DMA_IN_CH4"]
459 DMA_IN_CH4 = 70,
460 #[doc = "71 - DMA_OUT_CH0"]
461 DMA_OUT_CH0 = 71,
462 #[doc = "72 - DMA_OUT_CH1"]
463 DMA_OUT_CH1 = 72,
464 #[doc = "73 - DMA_OUT_CH2"]
465 DMA_OUT_CH2 = 73,
466 #[doc = "74 - DMA_OUT_CH3"]
467 DMA_OUT_CH3 = 74,
468 #[doc = "75 - DMA_OUT_CH4"]
469 DMA_OUT_CH4 = 75,
470 #[doc = "76 - RSA"]
471 RSA = 76,
472 #[doc = "77 - SHA"]
473 SHA = 77,
474 #[doc = "79 - FROM_CPU_INTR0"]
475 FROM_CPU_INTR0 = 79,
476 #[doc = "80 - FROM_CPU_INTR1"]
477 FROM_CPU_INTR1 = 80,
478 #[doc = "81 - FROM_CPU_INTR2"]
479 FROM_CPU_INTR2 = 81,
480 #[doc = "82 - FROM_CPU_INTR3"]
481 FROM_CPU_INTR3 = 82,
482 #[doc = "83 - ASSIST_DEBUG"]
483 ASSIST_DEBUG = 83,
484 #[doc = "84 - DMA_APBPERI_PMS"]
485 DMA_APBPERI_PMS = 84,
486 #[doc = "85 - CORE0_IRAM0_PMS"]
487 CORE0_IRAM0_PMS = 85,
488 #[doc = "86 - CORE0_DRAM0_PMS"]
489 CORE0_DRAM0_PMS = 86,
490 #[doc = "87 - CORE0_PIF_PMS"]
491 CORE0_PIF_PMS = 87,
492 #[doc = "88 - CORE0_PIF_PMS_SIZE"]
493 CORE0_PIF_PMS_SIZE = 88,
494 #[doc = "89 - CORE1_IRAM0_PMS"]
495 CORE1_IRAM0_PMS = 89,
496 #[doc = "90 - CORE1_DRAM0_PMS"]
497 CORE1_DRAM0_PMS = 90,
498 #[doc = "91 - CORE1_PIF_PMS"]
499 CORE1_PIF_PMS = 91,
500 #[doc = "92 - CORE1_PIF_PMS_SIZE"]
501 CORE1_PIF_PMS_SIZE = 92,
502 #[doc = "93 - BACKUP_PMS_VIOLATE"]
503 BACKUP_PMS_VIOLATE = 93,
504 #[doc = "94 - CACHE_CORE0_ACS"]
505 CACHE_CORE0_ACS = 94,
506 #[doc = "95 - CACHE_CORE1_ACS"]
507 CACHE_CORE1_ACS = 95,
508 #[doc = "96 - USB_DEVICE"]
509 USB_DEVICE = 96,
510 #[doc = "97 - PERI_BACKUP"]
511 PERI_BACKUP = 97,
512 #[doc = "98 - DMA_EXTMEM_REJECT"]
513 DMA_EXTMEM_REJECT = 98,
514}
515#[doc = r" TryFromInterruptError"]
516#[cfg_attr(feature = "defmt", derive(defmt::Format))]
517#[derive(Debug, Copy, Clone)]
518pub struct TryFromInterruptError(());
519impl Interrupt {
520 #[doc = r" Attempt to convert a given value into an `Interrupt`"]
521 #[inline]
522 pub fn try_from(value: u16) -> Result<Self, TryFromInterruptError> {
523 match value {
524 0 => Ok(Interrupt::WIFI_MAC),
525 1 => Ok(Interrupt::WIFI_NMI),
526 2 => Ok(Interrupt::WIFI_PWR),
527 3 => Ok(Interrupt::WIFI_BB),
528 4 => Ok(Interrupt::BT_MAC),
529 5 => Ok(Interrupt::BT_BB),
530 6 => Ok(Interrupt::BT_BB_NMI),
531 7 => Ok(Interrupt::RWBT),
532 8 => Ok(Interrupt::RWBLE),
533 9 => Ok(Interrupt::RWBT_NMI),
534 10 => Ok(Interrupt::RWBLE_NMI),
535 11 => Ok(Interrupt::I2C_MASTER),
536 12 => Ok(Interrupt::SLC0),
537 13 => Ok(Interrupt::SLC1),
538 14 => Ok(Interrupt::UHCI0),
539 15 => Ok(Interrupt::UHCI1),
540 16 => Ok(Interrupt::GPIO),
541 17 => Ok(Interrupt::GPIO_NMI),
542 18 => Ok(Interrupt::GPIO_INTR_2),
543 19 => Ok(Interrupt::GPIO_NMI_2),
544 20 => Ok(Interrupt::SPI1),
545 21 => Ok(Interrupt::SPI2),
546 22 => Ok(Interrupt::SPI3),
547 24 => Ok(Interrupt::LCD_CAM),
548 25 => Ok(Interrupt::I2S0),
549 26 => Ok(Interrupt::I2S1),
550 27 => Ok(Interrupt::UART0),
551 28 => Ok(Interrupt::UART1),
552 29 => Ok(Interrupt::UART2),
553 30 => Ok(Interrupt::SDIO_HOST),
554 31 => Ok(Interrupt::MCPWM0),
555 32 => Ok(Interrupt::MCPWM1),
556 35 => Ok(Interrupt::LEDC),
557 36 => Ok(Interrupt::EFUSE),
558 37 => Ok(Interrupt::TWAI0),
559 38 => Ok(Interrupt::USB),
560 39 => Ok(Interrupt::RTC_CORE),
561 40 => Ok(Interrupt::RMT),
562 41 => Ok(Interrupt::PCNT),
563 42 => Ok(Interrupt::I2C_EXT0),
564 43 => Ok(Interrupt::I2C_EXT1),
565 44 => Ok(Interrupt::SPI2_DMA),
566 45 => Ok(Interrupt::SPI3_DMA),
567 47 => Ok(Interrupt::WDT),
568 48 => Ok(Interrupt::TIMER1),
569 49 => Ok(Interrupt::TIMER2),
570 50 => Ok(Interrupt::TG0_T0_LEVEL),
571 51 => Ok(Interrupt::TG0_T1_LEVEL),
572 52 => Ok(Interrupt::TG0_WDT_LEVEL),
573 53 => Ok(Interrupt::TG1_T0_LEVEL),
574 54 => Ok(Interrupt::TG1_T1_LEVEL),
575 55 => Ok(Interrupt::TG1_WDT_LEVEL),
576 56 => Ok(Interrupt::CACHE_IA),
577 57 => Ok(Interrupt::SYSTIMER_TARGET0),
578 58 => Ok(Interrupt::SYSTIMER_TARGET1),
579 59 => Ok(Interrupt::SYSTIMER_TARGET2),
580 60 => Ok(Interrupt::SPI_MEM_REJECT_CACHE),
581 61 => Ok(Interrupt::DCACHE_PRELOAD0),
582 62 => Ok(Interrupt::ICACHE_PRELOAD0),
583 63 => Ok(Interrupt::DCACHE_SYNC0),
584 64 => Ok(Interrupt::ICACHE_SYNC0),
585 65 => Ok(Interrupt::APB_ADC),
586 66 => Ok(Interrupt::DMA_IN_CH0),
587 67 => Ok(Interrupt::DMA_IN_CH1),
588 68 => Ok(Interrupt::DMA_IN_CH2),
589 69 => Ok(Interrupt::DMA_IN_CH3),
590 70 => Ok(Interrupt::DMA_IN_CH4),
591 71 => Ok(Interrupt::DMA_OUT_CH0),
592 72 => Ok(Interrupt::DMA_OUT_CH1),
593 73 => Ok(Interrupt::DMA_OUT_CH2),
594 74 => Ok(Interrupt::DMA_OUT_CH3),
595 75 => Ok(Interrupt::DMA_OUT_CH4),
596 76 => Ok(Interrupt::RSA),
597 77 => Ok(Interrupt::SHA),
598 79 => Ok(Interrupt::FROM_CPU_INTR0),
599 80 => Ok(Interrupt::FROM_CPU_INTR1),
600 81 => Ok(Interrupt::FROM_CPU_INTR2),
601 82 => Ok(Interrupt::FROM_CPU_INTR3),
602 83 => Ok(Interrupt::ASSIST_DEBUG),
603 84 => Ok(Interrupt::DMA_APBPERI_PMS),
604 85 => Ok(Interrupt::CORE0_IRAM0_PMS),
605 86 => Ok(Interrupt::CORE0_DRAM0_PMS),
606 87 => Ok(Interrupt::CORE0_PIF_PMS),
607 88 => Ok(Interrupt::CORE0_PIF_PMS_SIZE),
608 89 => Ok(Interrupt::CORE1_IRAM0_PMS),
609 90 => Ok(Interrupt::CORE1_DRAM0_PMS),
610 91 => Ok(Interrupt::CORE1_PIF_PMS),
611 92 => Ok(Interrupt::CORE1_PIF_PMS_SIZE),
612 93 => Ok(Interrupt::BACKUP_PMS_VIOLATE),
613 94 => Ok(Interrupt::CACHE_CORE0_ACS),
614 95 => Ok(Interrupt::CACHE_CORE1_ACS),
615 96 => Ok(Interrupt::USB_DEVICE),
616 97 => Ok(Interrupt::PERI_BACKUP),
617 98 => Ok(Interrupt::DMA_EXTMEM_REJECT),
618 _ => Err(TryFromInterruptError(())),
619 }
620 }
621}
622#[doc = "AES (Advanced Encryption Standard) Accelerator"]
623pub struct AES {
624 _marker: PhantomData<*const ()>,
625}
626unsafe impl Send for AES {}
627impl AES {
628 #[doc = r"Pointer to the register block"]
629 pub const PTR: *const aes::RegisterBlock = 0x6003_a000 as *const _;
630 #[doc = r"Return the pointer to the register block"]
631 #[inline(always)]
632 pub const fn ptr() -> *const aes::RegisterBlock {
633 Self::PTR
634 }
635 #[doc = r" Steal an instance of this peripheral"]
636 #[doc = r""]
637 #[doc = r" # Safety"]
638 #[doc = r""]
639 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
640 #[doc = r" that may race with any existing instances, for example by only"]
641 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
642 #[doc = r" original peripheral and using critical sections to coordinate"]
643 #[doc = r" access between multiple new instances."]
644 #[doc = r""]
645 #[doc = r" Additionally, other software such as HALs may rely on only one"]
646 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
647 #[doc = r" no stolen instances are passed to such software."]
648 pub unsafe fn steal() -> Self {
649 Self {
650 _marker: PhantomData,
651 }
652 }
653}
654impl Deref for AES {
655 type Target = aes::RegisterBlock;
656 #[inline(always)]
657 fn deref(&self) -> &Self::Target {
658 unsafe { &*Self::PTR }
659 }
660}
661impl core::fmt::Debug for AES {
662 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
663 f.debug_struct("AES").finish()
664 }
665}
666#[doc = "AES (Advanced Encryption Standard) Accelerator"]
667pub mod aes;
668#[doc = "APB (Advanced Peripheral Bus) Controller"]
669pub struct APB_CTRL {
670 _marker: PhantomData<*const ()>,
671}
672unsafe impl Send for APB_CTRL {}
673impl APB_CTRL {
674 #[doc = r"Pointer to the register block"]
675 pub const PTR: *const apb_ctrl::RegisterBlock = 0x6002_6000 as *const _;
676 #[doc = r"Return the pointer to the register block"]
677 #[inline(always)]
678 pub const fn ptr() -> *const apb_ctrl::RegisterBlock {
679 Self::PTR
680 }
681 #[doc = r" Steal an instance of this peripheral"]
682 #[doc = r""]
683 #[doc = r" # Safety"]
684 #[doc = r""]
685 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
686 #[doc = r" that may race with any existing instances, for example by only"]
687 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
688 #[doc = r" original peripheral and using critical sections to coordinate"]
689 #[doc = r" access between multiple new instances."]
690 #[doc = r""]
691 #[doc = r" Additionally, other software such as HALs may rely on only one"]
692 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
693 #[doc = r" no stolen instances are passed to such software."]
694 pub unsafe fn steal() -> Self {
695 Self {
696 _marker: PhantomData,
697 }
698 }
699}
700impl Deref for APB_CTRL {
701 type Target = apb_ctrl::RegisterBlock;
702 #[inline(always)]
703 fn deref(&self) -> &Self::Target {
704 unsafe { &*Self::PTR }
705 }
706}
707impl core::fmt::Debug for APB_CTRL {
708 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
709 f.debug_struct("APB_CTRL").finish()
710 }
711}
712#[doc = "APB (Advanced Peripheral Bus) Controller"]
713pub mod apb_ctrl;
714#[doc = "SAR (Successive Approximation Register) Analog-to-Digital Converter"]
715pub struct APB_SARADC {
716 _marker: PhantomData<*const ()>,
717}
718unsafe impl Send for APB_SARADC {}
719impl APB_SARADC {
720 #[doc = r"Pointer to the register block"]
721 pub const PTR: *const apb_saradc::RegisterBlock = 0x6004_0000 as *const _;
722 #[doc = r"Return the pointer to the register block"]
723 #[inline(always)]
724 pub const fn ptr() -> *const apb_saradc::RegisterBlock {
725 Self::PTR
726 }
727 #[doc = r" Steal an instance of this peripheral"]
728 #[doc = r""]
729 #[doc = r" # Safety"]
730 #[doc = r""]
731 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
732 #[doc = r" that may race with any existing instances, for example by only"]
733 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
734 #[doc = r" original peripheral and using critical sections to coordinate"]
735 #[doc = r" access between multiple new instances."]
736 #[doc = r""]
737 #[doc = r" Additionally, other software such as HALs may rely on only one"]
738 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
739 #[doc = r" no stolen instances are passed to such software."]
740 pub unsafe fn steal() -> Self {
741 Self {
742 _marker: PhantomData,
743 }
744 }
745}
746impl Deref for APB_SARADC {
747 type Target = apb_saradc::RegisterBlock;
748 #[inline(always)]
749 fn deref(&self) -> &Self::Target {
750 unsafe { &*Self::PTR }
751 }
752}
753impl core::fmt::Debug for APB_SARADC {
754 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
755 f.debug_struct("APB_SARADC").finish()
756 }
757}
758#[doc = "SAR (Successive Approximation Register) Analog-to-Digital Converter"]
759pub mod apb_saradc;
760#[doc = "BB Peripheral"]
761pub struct BB {
762 _marker: PhantomData<*const ()>,
763}
764unsafe impl Send for BB {}
765impl BB {
766 #[doc = r"Pointer to the register block"]
767 pub const PTR: *const bb::RegisterBlock = 0x6001_d000 as *const _;
768 #[doc = r"Return the pointer to the register block"]
769 #[inline(always)]
770 pub const fn ptr() -> *const bb::RegisterBlock {
771 Self::PTR
772 }
773 #[doc = r" Steal an instance of this peripheral"]
774 #[doc = r""]
775 #[doc = r" # Safety"]
776 #[doc = r""]
777 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
778 #[doc = r" that may race with any existing instances, for example by only"]
779 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
780 #[doc = r" original peripheral and using critical sections to coordinate"]
781 #[doc = r" access between multiple new instances."]
782 #[doc = r""]
783 #[doc = r" Additionally, other software such as HALs may rely on only one"]
784 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
785 #[doc = r" no stolen instances are passed to such software."]
786 pub unsafe fn steal() -> Self {
787 Self {
788 _marker: PhantomData,
789 }
790 }
791}
792impl Deref for BB {
793 type Target = bb::RegisterBlock;
794 #[inline(always)]
795 fn deref(&self) -> &Self::Target {
796 unsafe { &*Self::PTR }
797 }
798}
799impl core::fmt::Debug for BB {
800 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
801 f.debug_struct("BB").finish()
802 }
803}
804#[doc = "BB Peripheral"]
805pub mod bb;
806#[doc = "Debug Assist"]
807pub struct ASSIST_DEBUG {
808 _marker: PhantomData<*const ()>,
809}
810unsafe impl Send for ASSIST_DEBUG {}
811impl ASSIST_DEBUG {
812 #[doc = r"Pointer to the register block"]
813 pub const PTR: *const assist_debug::RegisterBlock = 0x600c_e000 as *const _;
814 #[doc = r"Return the pointer to the register block"]
815 #[inline(always)]
816 pub const fn ptr() -> *const assist_debug::RegisterBlock {
817 Self::PTR
818 }
819 #[doc = r" Steal an instance of this peripheral"]
820 #[doc = r""]
821 #[doc = r" # Safety"]
822 #[doc = r""]
823 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
824 #[doc = r" that may race with any existing instances, for example by only"]
825 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
826 #[doc = r" original peripheral and using critical sections to coordinate"]
827 #[doc = r" access between multiple new instances."]
828 #[doc = r""]
829 #[doc = r" Additionally, other software such as HALs may rely on only one"]
830 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
831 #[doc = r" no stolen instances are passed to such software."]
832 pub unsafe fn steal() -> Self {
833 Self {
834 _marker: PhantomData,
835 }
836 }
837}
838impl Deref for ASSIST_DEBUG {
839 type Target = assist_debug::RegisterBlock;
840 #[inline(always)]
841 fn deref(&self) -> &Self::Target {
842 unsafe { &*Self::PTR }
843 }
844}
845impl core::fmt::Debug for ASSIST_DEBUG {
846 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
847 f.debug_struct("ASSIST_DEBUG").finish()
848 }
849}
850#[doc = "Debug Assist"]
851pub mod assist_debug;
852#[doc = "DMA (Direct Memory Access) Controller"]
853pub struct DMA {
854 _marker: PhantomData<*const ()>,
855}
856unsafe impl Send for DMA {}
857impl DMA {
858 #[doc = r"Pointer to the register block"]
859 pub const PTR: *const dma::RegisterBlock = 0x6003_f000 as *const _;
860 #[doc = r"Return the pointer to the register block"]
861 #[inline(always)]
862 pub const fn ptr() -> *const dma::RegisterBlock {
863 Self::PTR
864 }
865 #[doc = r" Steal an instance of this peripheral"]
866 #[doc = r""]
867 #[doc = r" # Safety"]
868 #[doc = r""]
869 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
870 #[doc = r" that may race with any existing instances, for example by only"]
871 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
872 #[doc = r" original peripheral and using critical sections to coordinate"]
873 #[doc = r" access between multiple new instances."]
874 #[doc = r""]
875 #[doc = r" Additionally, other software such as HALs may rely on only one"]
876 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
877 #[doc = r" no stolen instances are passed to such software."]
878 pub unsafe fn steal() -> Self {
879 Self {
880 _marker: PhantomData,
881 }
882 }
883}
884impl Deref for DMA {
885 type Target = dma::RegisterBlock;
886 #[inline(always)]
887 fn deref(&self) -> &Self::Target {
888 unsafe { &*Self::PTR }
889 }
890}
891impl core::fmt::Debug for DMA {
892 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
893 f.debug_struct("DMA").finish()
894 }
895}
896#[doc = "DMA (Direct Memory Access) Controller"]
897pub mod dma;
898#[doc = "Digital Signature"]
899pub struct DS {
900 _marker: PhantomData<*const ()>,
901}
902unsafe impl Send for DS {}
903impl DS {
904 #[doc = r"Pointer to the register block"]
905 pub const PTR: *const ds::RegisterBlock = 0x6003_d000 as *const _;
906 #[doc = r"Return the pointer to the register block"]
907 #[inline(always)]
908 pub const fn ptr() -> *const ds::RegisterBlock {
909 Self::PTR
910 }
911 #[doc = r" Steal an instance of this peripheral"]
912 #[doc = r""]
913 #[doc = r" # Safety"]
914 #[doc = r""]
915 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
916 #[doc = r" that may race with any existing instances, for example by only"]
917 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
918 #[doc = r" original peripheral and using critical sections to coordinate"]
919 #[doc = r" access between multiple new instances."]
920 #[doc = r""]
921 #[doc = r" Additionally, other software such as HALs may rely on only one"]
922 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
923 #[doc = r" no stolen instances are passed to such software."]
924 pub unsafe fn steal() -> Self {
925 Self {
926 _marker: PhantomData,
927 }
928 }
929}
930impl Deref for DS {
931 type Target = ds::RegisterBlock;
932 #[inline(always)]
933 fn deref(&self) -> &Self::Target {
934 unsafe { &*Self::PTR }
935 }
936}
937impl core::fmt::Debug for DS {
938 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
939 f.debug_struct("DS").finish()
940 }
941}
942#[doc = "Digital Signature"]
943pub mod ds;
944#[doc = "eFuse Controller"]
945pub struct EFUSE {
946 _marker: PhantomData<*const ()>,
947}
948unsafe impl Send for EFUSE {}
949impl EFUSE {
950 #[doc = r"Pointer to the register block"]
951 pub const PTR: *const efuse::RegisterBlock = 0x6000_7000 as *const _;
952 #[doc = r"Return the pointer to the register block"]
953 #[inline(always)]
954 pub const fn ptr() -> *const efuse::RegisterBlock {
955 Self::PTR
956 }
957 #[doc = r" Steal an instance of this peripheral"]
958 #[doc = r""]
959 #[doc = r" # Safety"]
960 #[doc = r""]
961 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
962 #[doc = r" that may race with any existing instances, for example by only"]
963 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
964 #[doc = r" original peripheral and using critical sections to coordinate"]
965 #[doc = r" access between multiple new instances."]
966 #[doc = r""]
967 #[doc = r" Additionally, other software such as HALs may rely on only one"]
968 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
969 #[doc = r" no stolen instances are passed to such software."]
970 pub unsafe fn steal() -> Self {
971 Self {
972 _marker: PhantomData,
973 }
974 }
975}
976impl Deref for EFUSE {
977 type Target = efuse::RegisterBlock;
978 #[inline(always)]
979 fn deref(&self) -> &Self::Target {
980 unsafe { &*Self::PTR }
981 }
982}
983impl core::fmt::Debug for EFUSE {
984 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
985 f.debug_struct("EFUSE").finish()
986 }
987}
988#[doc = "eFuse Controller"]
989pub mod efuse;
990#[doc = "External Memory"]
991pub struct EXTMEM {
992 _marker: PhantomData<*const ()>,
993}
994unsafe impl Send for EXTMEM {}
995impl EXTMEM {
996 #[doc = r"Pointer to the register block"]
997 pub const PTR: *const extmem::RegisterBlock = 0x600c_4000 as *const _;
998 #[doc = r"Return the pointer to the register block"]
999 #[inline(always)]
1000 pub const fn ptr() -> *const extmem::RegisterBlock {
1001 Self::PTR
1002 }
1003 #[doc = r" Steal an instance of this peripheral"]
1004 #[doc = r""]
1005 #[doc = r" # Safety"]
1006 #[doc = r""]
1007 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1008 #[doc = r" that may race with any existing instances, for example by only"]
1009 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1010 #[doc = r" original peripheral and using critical sections to coordinate"]
1011 #[doc = r" access between multiple new instances."]
1012 #[doc = r""]
1013 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1014 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1015 #[doc = r" no stolen instances are passed to such software."]
1016 pub unsafe fn steal() -> Self {
1017 Self {
1018 _marker: PhantomData,
1019 }
1020 }
1021}
1022impl Deref for EXTMEM {
1023 type Target = extmem::RegisterBlock;
1024 #[inline(always)]
1025 fn deref(&self) -> &Self::Target {
1026 unsafe { &*Self::PTR }
1027 }
1028}
1029impl core::fmt::Debug for EXTMEM {
1030 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1031 f.debug_struct("EXTMEM").finish()
1032 }
1033}
1034#[doc = "External Memory"]
1035pub mod extmem;
1036#[doc = "General Purpose Input/Output"]
1037pub struct GPIO {
1038 _marker: PhantomData<*const ()>,
1039}
1040unsafe impl Send for GPIO {}
1041impl GPIO {
1042 #[doc = r"Pointer to the register block"]
1043 pub const PTR: *const gpio::RegisterBlock = 0x6000_4000 as *const _;
1044 #[doc = r"Return the pointer to the register block"]
1045 #[inline(always)]
1046 pub const fn ptr() -> *const gpio::RegisterBlock {
1047 Self::PTR
1048 }
1049 #[doc = r" Steal an instance of this peripheral"]
1050 #[doc = r""]
1051 #[doc = r" # Safety"]
1052 #[doc = r""]
1053 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1054 #[doc = r" that may race with any existing instances, for example by only"]
1055 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1056 #[doc = r" original peripheral and using critical sections to coordinate"]
1057 #[doc = r" access between multiple new instances."]
1058 #[doc = r""]
1059 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1060 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1061 #[doc = r" no stolen instances are passed to such software."]
1062 pub unsafe fn steal() -> Self {
1063 Self {
1064 _marker: PhantomData,
1065 }
1066 }
1067}
1068impl Deref for GPIO {
1069 type Target = gpio::RegisterBlock;
1070 #[inline(always)]
1071 fn deref(&self) -> &Self::Target {
1072 unsafe { &*Self::PTR }
1073 }
1074}
1075impl core::fmt::Debug for GPIO {
1076 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1077 f.debug_struct("GPIO").finish()
1078 }
1079}
1080#[doc = "General Purpose Input/Output"]
1081pub mod gpio;
1082#[doc = "Sigma-Delta Modulation"]
1083pub struct GPIO_SD {
1084 _marker: PhantomData<*const ()>,
1085}
1086unsafe impl Send for GPIO_SD {}
1087impl GPIO_SD {
1088 #[doc = r"Pointer to the register block"]
1089 pub const PTR: *const gpio_sd::RegisterBlock = 0x6000_4f00 as *const _;
1090 #[doc = r"Return the pointer to the register block"]
1091 #[inline(always)]
1092 pub const fn ptr() -> *const gpio_sd::RegisterBlock {
1093 Self::PTR
1094 }
1095 #[doc = r" Steal an instance of this peripheral"]
1096 #[doc = r""]
1097 #[doc = r" # Safety"]
1098 #[doc = r""]
1099 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1100 #[doc = r" that may race with any existing instances, for example by only"]
1101 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1102 #[doc = r" original peripheral and using critical sections to coordinate"]
1103 #[doc = r" access between multiple new instances."]
1104 #[doc = r""]
1105 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1106 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1107 #[doc = r" no stolen instances are passed to such software."]
1108 pub unsafe fn steal() -> Self {
1109 Self {
1110 _marker: PhantomData,
1111 }
1112 }
1113}
1114impl Deref for GPIO_SD {
1115 type Target = gpio_sd::RegisterBlock;
1116 #[inline(always)]
1117 fn deref(&self) -> &Self::Target {
1118 unsafe { &*Self::PTR }
1119 }
1120}
1121impl core::fmt::Debug for GPIO_SD {
1122 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1123 f.debug_struct("GPIO_SD").finish()
1124 }
1125}
1126#[doc = "Sigma-Delta Modulation"]
1127pub mod gpio_sd;
1128#[doc = "HMAC (Hash-based Message Authentication Code) Accelerator"]
1129pub struct HMAC {
1130 _marker: PhantomData<*const ()>,
1131}
1132unsafe impl Send for HMAC {}
1133impl HMAC {
1134 #[doc = r"Pointer to the register block"]
1135 pub const PTR: *const hmac::RegisterBlock = 0x6003_e000 as *const _;
1136 #[doc = r"Return the pointer to the register block"]
1137 #[inline(always)]
1138 pub const fn ptr() -> *const hmac::RegisterBlock {
1139 Self::PTR
1140 }
1141 #[doc = r" Steal an instance of this peripheral"]
1142 #[doc = r""]
1143 #[doc = r" # Safety"]
1144 #[doc = r""]
1145 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1146 #[doc = r" that may race with any existing instances, for example by only"]
1147 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1148 #[doc = r" original peripheral and using critical sections to coordinate"]
1149 #[doc = r" access between multiple new instances."]
1150 #[doc = r""]
1151 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1152 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1153 #[doc = r" no stolen instances are passed to such software."]
1154 pub unsafe fn steal() -> Self {
1155 Self {
1156 _marker: PhantomData,
1157 }
1158 }
1159}
1160impl Deref for HMAC {
1161 type Target = hmac::RegisterBlock;
1162 #[inline(always)]
1163 fn deref(&self) -> &Self::Target {
1164 unsafe { &*Self::PTR }
1165 }
1166}
1167impl core::fmt::Debug for HMAC {
1168 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1169 f.debug_struct("HMAC").finish()
1170 }
1171}
1172#[doc = "HMAC (Hash-based Message Authentication Code) Accelerator"]
1173pub mod hmac;
1174#[doc = "I2C (Inter-Integrated Circuit) Controller 0"]
1175pub struct I2C0 {
1176 _marker: PhantomData<*const ()>,
1177}
1178unsafe impl Send for I2C0 {}
1179impl I2C0 {
1180 #[doc = r"Pointer to the register block"]
1181 pub const PTR: *const i2c0::RegisterBlock = 0x6001_3000 as *const _;
1182 #[doc = r"Return the pointer to the register block"]
1183 #[inline(always)]
1184 pub const fn ptr() -> *const i2c0::RegisterBlock {
1185 Self::PTR
1186 }
1187 #[doc = r" Steal an instance of this peripheral"]
1188 #[doc = r""]
1189 #[doc = r" # Safety"]
1190 #[doc = r""]
1191 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1192 #[doc = r" that may race with any existing instances, for example by only"]
1193 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1194 #[doc = r" original peripheral and using critical sections to coordinate"]
1195 #[doc = r" access between multiple new instances."]
1196 #[doc = r""]
1197 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1198 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1199 #[doc = r" no stolen instances are passed to such software."]
1200 pub unsafe fn steal() -> Self {
1201 Self {
1202 _marker: PhantomData,
1203 }
1204 }
1205}
1206impl Deref for I2C0 {
1207 type Target = i2c0::RegisterBlock;
1208 #[inline(always)]
1209 fn deref(&self) -> &Self::Target {
1210 unsafe { &*Self::PTR }
1211 }
1212}
1213impl core::fmt::Debug for I2C0 {
1214 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1215 f.debug_struct("I2C0").finish()
1216 }
1217}
1218#[doc = "I2C (Inter-Integrated Circuit) Controller 0"]
1219pub mod i2c0;
1220#[doc = "I2C (Inter-Integrated Circuit) Controller 1"]
1221pub struct I2C1 {
1222 _marker: PhantomData<*const ()>,
1223}
1224unsafe impl Send for I2C1 {}
1225impl I2C1 {
1226 #[doc = r"Pointer to the register block"]
1227 pub const PTR: *const i2c0::RegisterBlock = 0x6002_7000 as *const _;
1228 #[doc = r"Return the pointer to the register block"]
1229 #[inline(always)]
1230 pub const fn ptr() -> *const i2c0::RegisterBlock {
1231 Self::PTR
1232 }
1233 #[doc = r" Steal an instance of this peripheral"]
1234 #[doc = r""]
1235 #[doc = r" # Safety"]
1236 #[doc = r""]
1237 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1238 #[doc = r" that may race with any existing instances, for example by only"]
1239 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1240 #[doc = r" original peripheral and using critical sections to coordinate"]
1241 #[doc = r" access between multiple new instances."]
1242 #[doc = r""]
1243 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1244 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1245 #[doc = r" no stolen instances are passed to such software."]
1246 pub unsafe fn steal() -> Self {
1247 Self {
1248 _marker: PhantomData,
1249 }
1250 }
1251}
1252impl Deref for I2C1 {
1253 type Target = i2c0::RegisterBlock;
1254 #[inline(always)]
1255 fn deref(&self) -> &Self::Target {
1256 unsafe { &*Self::PTR }
1257 }
1258}
1259impl core::fmt::Debug for I2C1 {
1260 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1261 f.debug_struct("I2C1").finish()
1262 }
1263}
1264#[doc = "I2C (Inter-Integrated Circuit) Controller 1"]
1265pub use self::i2c0 as i2c1;
1266#[doc = "I2S (Inter-IC Sound) Controller 0"]
1267pub struct I2S0 {
1268 _marker: PhantomData<*const ()>,
1269}
1270unsafe impl Send for I2S0 {}
1271impl I2S0 {
1272 #[doc = r"Pointer to the register block"]
1273 pub const PTR: *const i2s0::RegisterBlock = 0x6000_f000 as *const _;
1274 #[doc = r"Return the pointer to the register block"]
1275 #[inline(always)]
1276 pub const fn ptr() -> *const i2s0::RegisterBlock {
1277 Self::PTR
1278 }
1279 #[doc = r" Steal an instance of this peripheral"]
1280 #[doc = r""]
1281 #[doc = r" # Safety"]
1282 #[doc = r""]
1283 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1284 #[doc = r" that may race with any existing instances, for example by only"]
1285 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1286 #[doc = r" original peripheral and using critical sections to coordinate"]
1287 #[doc = r" access between multiple new instances."]
1288 #[doc = r""]
1289 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1290 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1291 #[doc = r" no stolen instances are passed to such software."]
1292 pub unsafe fn steal() -> Self {
1293 Self {
1294 _marker: PhantomData,
1295 }
1296 }
1297}
1298impl Deref for I2S0 {
1299 type Target = i2s0::RegisterBlock;
1300 #[inline(always)]
1301 fn deref(&self) -> &Self::Target {
1302 unsafe { &*Self::PTR }
1303 }
1304}
1305impl core::fmt::Debug for I2S0 {
1306 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1307 f.debug_struct("I2S0").finish()
1308 }
1309}
1310#[doc = "I2S (Inter-IC Sound) Controller 0"]
1311pub mod i2s0;
1312#[doc = "I2S (Inter-IC Sound) Controller 1"]
1313pub struct I2S1 {
1314 _marker: PhantomData<*const ()>,
1315}
1316unsafe impl Send for I2S1 {}
1317impl I2S1 {
1318 #[doc = r"Pointer to the register block"]
1319 pub const PTR: *const i2s1::RegisterBlock = 0x6002_d000 as *const _;
1320 #[doc = r"Return the pointer to the register block"]
1321 #[inline(always)]
1322 pub const fn ptr() -> *const i2s1::RegisterBlock {
1323 Self::PTR
1324 }
1325 #[doc = r" Steal an instance of this peripheral"]
1326 #[doc = r""]
1327 #[doc = r" # Safety"]
1328 #[doc = r""]
1329 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1330 #[doc = r" that may race with any existing instances, for example by only"]
1331 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1332 #[doc = r" original peripheral and using critical sections to coordinate"]
1333 #[doc = r" access between multiple new instances."]
1334 #[doc = r""]
1335 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1336 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1337 #[doc = r" no stolen instances are passed to such software."]
1338 pub unsafe fn steal() -> Self {
1339 Self {
1340 _marker: PhantomData,
1341 }
1342 }
1343}
1344impl Deref for I2S1 {
1345 type Target = i2s1::RegisterBlock;
1346 #[inline(always)]
1347 fn deref(&self) -> &Self::Target {
1348 unsafe { &*Self::PTR }
1349 }
1350}
1351impl core::fmt::Debug for I2S1 {
1352 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1353 f.debug_struct("I2S1").finish()
1354 }
1355}
1356#[doc = "I2S (Inter-IC Sound) Controller 1"]
1357pub mod i2s1;
1358#[doc = "Interrupt Controller (Core 0)"]
1359pub struct INTERRUPT_CORE0 {
1360 _marker: PhantomData<*const ()>,
1361}
1362unsafe impl Send for INTERRUPT_CORE0 {}
1363impl INTERRUPT_CORE0 {
1364 #[doc = r"Pointer to the register block"]
1365 pub const PTR: *const interrupt_core0::RegisterBlock = 0x600c_2000 as *const _;
1366 #[doc = r"Return the pointer to the register block"]
1367 #[inline(always)]
1368 pub const fn ptr() -> *const interrupt_core0::RegisterBlock {
1369 Self::PTR
1370 }
1371 #[doc = r" Steal an instance of this peripheral"]
1372 #[doc = r""]
1373 #[doc = r" # Safety"]
1374 #[doc = r""]
1375 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1376 #[doc = r" that may race with any existing instances, for example by only"]
1377 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1378 #[doc = r" original peripheral and using critical sections to coordinate"]
1379 #[doc = r" access between multiple new instances."]
1380 #[doc = r""]
1381 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1382 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1383 #[doc = r" no stolen instances are passed to such software."]
1384 pub unsafe fn steal() -> Self {
1385 Self {
1386 _marker: PhantomData,
1387 }
1388 }
1389}
1390impl Deref for INTERRUPT_CORE0 {
1391 type Target = interrupt_core0::RegisterBlock;
1392 #[inline(always)]
1393 fn deref(&self) -> &Self::Target {
1394 unsafe { &*Self::PTR }
1395 }
1396}
1397impl core::fmt::Debug for INTERRUPT_CORE0 {
1398 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1399 f.debug_struct("INTERRUPT_CORE0").finish()
1400 }
1401}
1402#[doc = "Interrupt Controller (Core 0)"]
1403pub mod interrupt_core0;
1404#[doc = "Interrupt Controller (Core 1)"]
1405pub struct INTERRUPT_CORE1 {
1406 _marker: PhantomData<*const ()>,
1407}
1408unsafe impl Send for INTERRUPT_CORE1 {}
1409impl INTERRUPT_CORE1 {
1410 #[doc = r"Pointer to the register block"]
1411 pub const PTR: *const interrupt_core1::RegisterBlock = 0x600c_2000 as *const _;
1412 #[doc = r"Return the pointer to the register block"]
1413 #[inline(always)]
1414 pub const fn ptr() -> *const interrupt_core1::RegisterBlock {
1415 Self::PTR
1416 }
1417 #[doc = r" Steal an instance of this peripheral"]
1418 #[doc = r""]
1419 #[doc = r" # Safety"]
1420 #[doc = r""]
1421 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1422 #[doc = r" that may race with any existing instances, for example by only"]
1423 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1424 #[doc = r" original peripheral and using critical sections to coordinate"]
1425 #[doc = r" access between multiple new instances."]
1426 #[doc = r""]
1427 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1428 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1429 #[doc = r" no stolen instances are passed to such software."]
1430 pub unsafe fn steal() -> Self {
1431 Self {
1432 _marker: PhantomData,
1433 }
1434 }
1435}
1436impl Deref for INTERRUPT_CORE1 {
1437 type Target = interrupt_core1::RegisterBlock;
1438 #[inline(always)]
1439 fn deref(&self) -> &Self::Target {
1440 unsafe { &*Self::PTR }
1441 }
1442}
1443impl core::fmt::Debug for INTERRUPT_CORE1 {
1444 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1445 f.debug_struct("INTERRUPT_CORE1").finish()
1446 }
1447}
1448#[doc = "Interrupt Controller (Core 1)"]
1449pub mod interrupt_core1;
1450#[doc = "Input/Output Multiplexer"]
1451pub struct IO_MUX {
1452 _marker: PhantomData<*const ()>,
1453}
1454unsafe impl Send for IO_MUX {}
1455impl IO_MUX {
1456 #[doc = r"Pointer to the register block"]
1457 pub const PTR: *const io_mux::RegisterBlock = 0x6000_9000 as *const _;
1458 #[doc = r"Return the pointer to the register block"]
1459 #[inline(always)]
1460 pub const fn ptr() -> *const io_mux::RegisterBlock {
1461 Self::PTR
1462 }
1463 #[doc = r" Steal an instance of this peripheral"]
1464 #[doc = r""]
1465 #[doc = r" # Safety"]
1466 #[doc = r""]
1467 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1468 #[doc = r" that may race with any existing instances, for example by only"]
1469 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1470 #[doc = r" original peripheral and using critical sections to coordinate"]
1471 #[doc = r" access between multiple new instances."]
1472 #[doc = r""]
1473 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1474 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1475 #[doc = r" no stolen instances are passed to such software."]
1476 pub unsafe fn steal() -> Self {
1477 Self {
1478 _marker: PhantomData,
1479 }
1480 }
1481}
1482impl Deref for IO_MUX {
1483 type Target = io_mux::RegisterBlock;
1484 #[inline(always)]
1485 fn deref(&self) -> &Self::Target {
1486 unsafe { &*Self::PTR }
1487 }
1488}
1489impl core::fmt::Debug for IO_MUX {
1490 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1491 f.debug_struct("IO_MUX").finish()
1492 }
1493}
1494#[doc = "Input/Output Multiplexer"]
1495pub mod io_mux;
1496#[doc = "Camera/LCD Controller"]
1497pub struct LCD_CAM {
1498 _marker: PhantomData<*const ()>,
1499}
1500unsafe impl Send for LCD_CAM {}
1501impl LCD_CAM {
1502 #[doc = r"Pointer to the register block"]
1503 pub const PTR: *const lcd_cam::RegisterBlock = 0x6004_1000 as *const _;
1504 #[doc = r"Return the pointer to the register block"]
1505 #[inline(always)]
1506 pub const fn ptr() -> *const lcd_cam::RegisterBlock {
1507 Self::PTR
1508 }
1509 #[doc = r" Steal an instance of this peripheral"]
1510 #[doc = r""]
1511 #[doc = r" # Safety"]
1512 #[doc = r""]
1513 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1514 #[doc = r" that may race with any existing instances, for example by only"]
1515 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1516 #[doc = r" original peripheral and using critical sections to coordinate"]
1517 #[doc = r" access between multiple new instances."]
1518 #[doc = r""]
1519 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1520 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1521 #[doc = r" no stolen instances are passed to such software."]
1522 pub unsafe fn steal() -> Self {
1523 Self {
1524 _marker: PhantomData,
1525 }
1526 }
1527}
1528impl Deref for LCD_CAM {
1529 type Target = lcd_cam::RegisterBlock;
1530 #[inline(always)]
1531 fn deref(&self) -> &Self::Target {
1532 unsafe { &*Self::PTR }
1533 }
1534}
1535impl core::fmt::Debug for LCD_CAM {
1536 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1537 f.debug_struct("LCD_CAM").finish()
1538 }
1539}
1540#[doc = "Camera/LCD Controller"]
1541pub mod lcd_cam;
1542#[doc = "LED Control PWM (Pulse Width Modulation)"]
1543pub struct LEDC {
1544 _marker: PhantomData<*const ()>,
1545}
1546unsafe impl Send for LEDC {}
1547impl LEDC {
1548 #[doc = r"Pointer to the register block"]
1549 pub const PTR: *const ledc::RegisterBlock = 0x6001_9000 as *const _;
1550 #[doc = r"Return the pointer to the register block"]
1551 #[inline(always)]
1552 pub const fn ptr() -> *const ledc::RegisterBlock {
1553 Self::PTR
1554 }
1555 #[doc = r" Steal an instance of this peripheral"]
1556 #[doc = r""]
1557 #[doc = r" # Safety"]
1558 #[doc = r""]
1559 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1560 #[doc = r" that may race with any existing instances, for example by only"]
1561 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1562 #[doc = r" original peripheral and using critical sections to coordinate"]
1563 #[doc = r" access between multiple new instances."]
1564 #[doc = r""]
1565 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1566 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1567 #[doc = r" no stolen instances are passed to such software."]
1568 pub unsafe fn steal() -> Self {
1569 Self {
1570 _marker: PhantomData,
1571 }
1572 }
1573}
1574impl Deref for LEDC {
1575 type Target = ledc::RegisterBlock;
1576 #[inline(always)]
1577 fn deref(&self) -> &Self::Target {
1578 unsafe { &*Self::PTR }
1579 }
1580}
1581impl core::fmt::Debug for LEDC {
1582 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1583 f.debug_struct("LEDC").finish()
1584 }
1585}
1586#[doc = "LED Control PWM (Pulse Width Modulation)"]
1587pub mod ledc;
1588#[doc = "Pulse Count Controller"]
1589pub struct PCNT {
1590 _marker: PhantomData<*const ()>,
1591}
1592unsafe impl Send for PCNT {}
1593impl PCNT {
1594 #[doc = r"Pointer to the register block"]
1595 pub const PTR: *const pcnt::RegisterBlock = 0x6001_7000 as *const _;
1596 #[doc = r"Return the pointer to the register block"]
1597 #[inline(always)]
1598 pub const fn ptr() -> *const pcnt::RegisterBlock {
1599 Self::PTR
1600 }
1601 #[doc = r" Steal an instance of this peripheral"]
1602 #[doc = r""]
1603 #[doc = r" # Safety"]
1604 #[doc = r""]
1605 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1606 #[doc = r" that may race with any existing instances, for example by only"]
1607 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1608 #[doc = r" original peripheral and using critical sections to coordinate"]
1609 #[doc = r" access between multiple new instances."]
1610 #[doc = r""]
1611 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1612 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1613 #[doc = r" no stolen instances are passed to such software."]
1614 pub unsafe fn steal() -> Self {
1615 Self {
1616 _marker: PhantomData,
1617 }
1618 }
1619}
1620impl Deref for PCNT {
1621 type Target = pcnt::RegisterBlock;
1622 #[inline(always)]
1623 fn deref(&self) -> &Self::Target {
1624 unsafe { &*Self::PTR }
1625 }
1626}
1627impl core::fmt::Debug for PCNT {
1628 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1629 f.debug_struct("PCNT").finish()
1630 }
1631}
1632#[doc = "Pulse Count Controller"]
1633pub mod pcnt;
1634#[doc = "PERI_BACKUP Peripheral"]
1635pub struct PERI_BACKUP {
1636 _marker: PhantomData<*const ()>,
1637}
1638unsafe impl Send for PERI_BACKUP {}
1639impl PERI_BACKUP {
1640 #[doc = r"Pointer to the register block"]
1641 pub const PTR: *const peri_backup::RegisterBlock = 0x6002_a000 as *const _;
1642 #[doc = r"Return the pointer to the register block"]
1643 #[inline(always)]
1644 pub const fn ptr() -> *const peri_backup::RegisterBlock {
1645 Self::PTR
1646 }
1647 #[doc = r" Steal an instance of this peripheral"]
1648 #[doc = r""]
1649 #[doc = r" # Safety"]
1650 #[doc = r""]
1651 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1652 #[doc = r" that may race with any existing instances, for example by only"]
1653 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1654 #[doc = r" original peripheral and using critical sections to coordinate"]
1655 #[doc = r" access between multiple new instances."]
1656 #[doc = r""]
1657 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1658 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1659 #[doc = r" no stolen instances are passed to such software."]
1660 pub unsafe fn steal() -> Self {
1661 Self {
1662 _marker: PhantomData,
1663 }
1664 }
1665}
1666impl Deref for PERI_BACKUP {
1667 type Target = peri_backup::RegisterBlock;
1668 #[inline(always)]
1669 fn deref(&self) -> &Self::Target {
1670 unsafe { &*Self::PTR }
1671 }
1672}
1673impl core::fmt::Debug for PERI_BACKUP {
1674 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1675 f.debug_struct("PERI_BACKUP").finish()
1676 }
1677}
1678#[doc = "PERI_BACKUP Peripheral"]
1679pub mod peri_backup;
1680#[doc = "Motor Control Pulse-Width Modulation 0"]
1681pub struct MCPWM0 {
1682 _marker: PhantomData<*const ()>,
1683}
1684unsafe impl Send for MCPWM0 {}
1685impl MCPWM0 {
1686 #[doc = r"Pointer to the register block"]
1687 pub const PTR: *const mcpwm0::RegisterBlock = 0x6001_e000 as *const _;
1688 #[doc = r"Return the pointer to the register block"]
1689 #[inline(always)]
1690 pub const fn ptr() -> *const mcpwm0::RegisterBlock {
1691 Self::PTR
1692 }
1693 #[doc = r" Steal an instance of this peripheral"]
1694 #[doc = r""]
1695 #[doc = r" # Safety"]
1696 #[doc = r""]
1697 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1698 #[doc = r" that may race with any existing instances, for example by only"]
1699 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1700 #[doc = r" original peripheral and using critical sections to coordinate"]
1701 #[doc = r" access between multiple new instances."]
1702 #[doc = r""]
1703 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1704 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1705 #[doc = r" no stolen instances are passed to such software."]
1706 pub unsafe fn steal() -> Self {
1707 Self {
1708 _marker: PhantomData,
1709 }
1710 }
1711}
1712impl Deref for MCPWM0 {
1713 type Target = mcpwm0::RegisterBlock;
1714 #[inline(always)]
1715 fn deref(&self) -> &Self::Target {
1716 unsafe { &*Self::PTR }
1717 }
1718}
1719impl core::fmt::Debug for MCPWM0 {
1720 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1721 f.debug_struct("MCPWM0").finish()
1722 }
1723}
1724#[doc = "Motor Control Pulse-Width Modulation 0"]
1725pub mod mcpwm0;
1726#[doc = "Motor Control Pulse-Width Modulation 1"]
1727pub struct MCPWM1 {
1728 _marker: PhantomData<*const ()>,
1729}
1730unsafe impl Send for MCPWM1 {}
1731impl MCPWM1 {
1732 #[doc = r"Pointer to the register block"]
1733 pub const PTR: *const mcpwm0::RegisterBlock = 0x6002_c000 as *const _;
1734 #[doc = r"Return the pointer to the register block"]
1735 #[inline(always)]
1736 pub const fn ptr() -> *const mcpwm0::RegisterBlock {
1737 Self::PTR
1738 }
1739 #[doc = r" Steal an instance of this peripheral"]
1740 #[doc = r""]
1741 #[doc = r" # Safety"]
1742 #[doc = r""]
1743 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1744 #[doc = r" that may race with any existing instances, for example by only"]
1745 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1746 #[doc = r" original peripheral and using critical sections to coordinate"]
1747 #[doc = r" access between multiple new instances."]
1748 #[doc = r""]
1749 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1750 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1751 #[doc = r" no stolen instances are passed to such software."]
1752 pub unsafe fn steal() -> Self {
1753 Self {
1754 _marker: PhantomData,
1755 }
1756 }
1757}
1758impl Deref for MCPWM1 {
1759 type Target = mcpwm0::RegisterBlock;
1760 #[inline(always)]
1761 fn deref(&self) -> &Self::Target {
1762 unsafe { &*Self::PTR }
1763 }
1764}
1765impl core::fmt::Debug for MCPWM1 {
1766 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1767 f.debug_struct("MCPWM1").finish()
1768 }
1769}
1770#[doc = "Motor Control Pulse-Width Modulation 1"]
1771pub use self::mcpwm0 as mcpwm1;
1772#[doc = "Remote Control"]
1773pub struct RMT {
1774 _marker: PhantomData<*const ()>,
1775}
1776unsafe impl Send for RMT {}
1777impl RMT {
1778 #[doc = r"Pointer to the register block"]
1779 pub const PTR: *const rmt::RegisterBlock = 0x6001_6000 as *const _;
1780 #[doc = r"Return the pointer to the register block"]
1781 #[inline(always)]
1782 pub const fn ptr() -> *const rmt::RegisterBlock {
1783 Self::PTR
1784 }
1785 #[doc = r" Steal an instance of this peripheral"]
1786 #[doc = r""]
1787 #[doc = r" # Safety"]
1788 #[doc = r""]
1789 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1790 #[doc = r" that may race with any existing instances, for example by only"]
1791 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1792 #[doc = r" original peripheral and using critical sections to coordinate"]
1793 #[doc = r" access between multiple new instances."]
1794 #[doc = r""]
1795 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1796 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1797 #[doc = r" no stolen instances are passed to such software."]
1798 pub unsafe fn steal() -> Self {
1799 Self {
1800 _marker: PhantomData,
1801 }
1802 }
1803}
1804impl Deref for RMT {
1805 type Target = rmt::RegisterBlock;
1806 #[inline(always)]
1807 fn deref(&self) -> &Self::Target {
1808 unsafe { &*Self::PTR }
1809 }
1810}
1811impl core::fmt::Debug for RMT {
1812 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1813 f.debug_struct("RMT").finish()
1814 }
1815}
1816#[doc = "Remote Control"]
1817pub mod rmt;
1818#[doc = "Hardware Random Number Generator"]
1819pub struct RNG {
1820 _marker: PhantomData<*const ()>,
1821}
1822unsafe impl Send for RNG {}
1823impl RNG {
1824 #[doc = r"Pointer to the register block"]
1825 pub const PTR: *const rng::RegisterBlock = 0x6003_4f6c as *const _;
1826 #[doc = r"Return the pointer to the register block"]
1827 #[inline(always)]
1828 pub const fn ptr() -> *const rng::RegisterBlock {
1829 Self::PTR
1830 }
1831 #[doc = r" Steal an instance of this peripheral"]
1832 #[doc = r""]
1833 #[doc = r" # Safety"]
1834 #[doc = r""]
1835 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1836 #[doc = r" that may race with any existing instances, for example by only"]
1837 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1838 #[doc = r" original peripheral and using critical sections to coordinate"]
1839 #[doc = r" access between multiple new instances."]
1840 #[doc = r""]
1841 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1842 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1843 #[doc = r" no stolen instances are passed to such software."]
1844 pub unsafe fn steal() -> Self {
1845 Self {
1846 _marker: PhantomData,
1847 }
1848 }
1849}
1850impl Deref for RNG {
1851 type Target = rng::RegisterBlock;
1852 #[inline(always)]
1853 fn deref(&self) -> &Self::Target {
1854 unsafe { &*Self::PTR }
1855 }
1856}
1857impl core::fmt::Debug for RNG {
1858 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1859 f.debug_struct("RNG").finish()
1860 }
1861}
1862#[doc = "Hardware Random Number Generator"]
1863pub mod rng;
1864#[doc = "RSA (Rivest Shamir Adleman) Accelerator"]
1865pub struct RSA {
1866 _marker: PhantomData<*const ()>,
1867}
1868unsafe impl Send for RSA {}
1869impl RSA {
1870 #[doc = r"Pointer to the register block"]
1871 pub const PTR: *const rsa::RegisterBlock = 0x6003_c000 as *const _;
1872 #[doc = r"Return the pointer to the register block"]
1873 #[inline(always)]
1874 pub const fn ptr() -> *const rsa::RegisterBlock {
1875 Self::PTR
1876 }
1877 #[doc = r" Steal an instance of this peripheral"]
1878 #[doc = r""]
1879 #[doc = r" # Safety"]
1880 #[doc = r""]
1881 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1882 #[doc = r" that may race with any existing instances, for example by only"]
1883 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1884 #[doc = r" original peripheral and using critical sections to coordinate"]
1885 #[doc = r" access between multiple new instances."]
1886 #[doc = r""]
1887 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1888 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1889 #[doc = r" no stolen instances are passed to such software."]
1890 pub unsafe fn steal() -> Self {
1891 Self {
1892 _marker: PhantomData,
1893 }
1894 }
1895}
1896impl Deref for RSA {
1897 type Target = rsa::RegisterBlock;
1898 #[inline(always)]
1899 fn deref(&self) -> &Self::Target {
1900 unsafe { &*Self::PTR }
1901 }
1902}
1903impl core::fmt::Debug for RSA {
1904 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1905 f.debug_struct("RSA").finish()
1906 }
1907}
1908#[doc = "RSA (Rivest Shamir Adleman) Accelerator"]
1909pub mod rsa;
1910#[doc = "Real-Time Clock Control"]
1911pub struct RTC_CNTL {
1912 _marker: PhantomData<*const ()>,
1913}
1914unsafe impl Send for RTC_CNTL {}
1915impl RTC_CNTL {
1916 #[doc = r"Pointer to the register block"]
1917 pub const PTR: *const rtc_cntl::RegisterBlock = 0x6000_8000 as *const _;
1918 #[doc = r"Return the pointer to the register block"]
1919 #[inline(always)]
1920 pub const fn ptr() -> *const rtc_cntl::RegisterBlock {
1921 Self::PTR
1922 }
1923 #[doc = r" Steal an instance of this peripheral"]
1924 #[doc = r""]
1925 #[doc = r" # Safety"]
1926 #[doc = r""]
1927 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1928 #[doc = r" that may race with any existing instances, for example by only"]
1929 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1930 #[doc = r" original peripheral and using critical sections to coordinate"]
1931 #[doc = r" access between multiple new instances."]
1932 #[doc = r""]
1933 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1934 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1935 #[doc = r" no stolen instances are passed to such software."]
1936 pub unsafe fn steal() -> Self {
1937 Self {
1938 _marker: PhantomData,
1939 }
1940 }
1941}
1942impl Deref for RTC_CNTL {
1943 type Target = rtc_cntl::RegisterBlock;
1944 #[inline(always)]
1945 fn deref(&self) -> &Self::Target {
1946 unsafe { &*Self::PTR }
1947 }
1948}
1949impl core::fmt::Debug for RTC_CNTL {
1950 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1951 f.debug_struct("RTC_CNTL").finish()
1952 }
1953}
1954#[doc = "Real-Time Clock Control"]
1955pub mod rtc_cntl;
1956#[doc = "Low-power I2C (Inter-Integrated Circuit) Controller"]
1957pub struct RTC_I2C {
1958 _marker: PhantomData<*const ()>,
1959}
1960unsafe impl Send for RTC_I2C {}
1961impl RTC_I2C {
1962 #[doc = r"Pointer to the register block"]
1963 pub const PTR: *const rtc_i2c::RegisterBlock = 0x6000_8c00 as *const _;
1964 #[doc = r"Return the pointer to the register block"]
1965 #[inline(always)]
1966 pub const fn ptr() -> *const rtc_i2c::RegisterBlock {
1967 Self::PTR
1968 }
1969 #[doc = r" Steal an instance of this peripheral"]
1970 #[doc = r""]
1971 #[doc = r" # Safety"]
1972 #[doc = r""]
1973 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
1974 #[doc = r" that may race with any existing instances, for example by only"]
1975 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
1976 #[doc = r" original peripheral and using critical sections to coordinate"]
1977 #[doc = r" access between multiple new instances."]
1978 #[doc = r""]
1979 #[doc = r" Additionally, other software such as HALs may rely on only one"]
1980 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
1981 #[doc = r" no stolen instances are passed to such software."]
1982 pub unsafe fn steal() -> Self {
1983 Self {
1984 _marker: PhantomData,
1985 }
1986 }
1987}
1988impl Deref for RTC_I2C {
1989 type Target = rtc_i2c::RegisterBlock;
1990 #[inline(always)]
1991 fn deref(&self) -> &Self::Target {
1992 unsafe { &*Self::PTR }
1993 }
1994}
1995impl core::fmt::Debug for RTC_I2C {
1996 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
1997 f.debug_struct("RTC_I2C").finish()
1998 }
1999}
2000#[doc = "Low-power I2C (Inter-Integrated Circuit) Controller"]
2001pub mod rtc_i2c;
2002#[doc = "Low-power Input/Output"]
2003pub struct RTC_IO {
2004 _marker: PhantomData<*const ()>,
2005}
2006unsafe impl Send for RTC_IO {}
2007impl RTC_IO {
2008 #[doc = r"Pointer to the register block"]
2009 pub const PTR: *const rtc_io::RegisterBlock = 0x6000_8400 as *const _;
2010 #[doc = r"Return the pointer to the register block"]
2011 #[inline(always)]
2012 pub const fn ptr() -> *const rtc_io::RegisterBlock {
2013 Self::PTR
2014 }
2015 #[doc = r" Steal an instance of this peripheral"]
2016 #[doc = r""]
2017 #[doc = r" # Safety"]
2018 #[doc = r""]
2019 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2020 #[doc = r" that may race with any existing instances, for example by only"]
2021 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2022 #[doc = r" original peripheral and using critical sections to coordinate"]
2023 #[doc = r" access between multiple new instances."]
2024 #[doc = r""]
2025 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2026 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2027 #[doc = r" no stolen instances are passed to such software."]
2028 pub unsafe fn steal() -> Self {
2029 Self {
2030 _marker: PhantomData,
2031 }
2032 }
2033}
2034impl Deref for RTC_IO {
2035 type Target = rtc_io::RegisterBlock;
2036 #[inline(always)]
2037 fn deref(&self) -> &Self::Target {
2038 unsafe { &*Self::PTR }
2039 }
2040}
2041impl core::fmt::Debug for RTC_IO {
2042 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2043 f.debug_struct("RTC_IO").finish()
2044 }
2045}
2046#[doc = "Low-power Input/Output"]
2047pub mod rtc_io;
2048#[doc = "SD/MMC Host Controller"]
2049pub struct SDHOST {
2050 _marker: PhantomData<*const ()>,
2051}
2052unsafe impl Send for SDHOST {}
2053impl SDHOST {
2054 #[doc = r"Pointer to the register block"]
2055 pub const PTR: *const sdhost::RegisterBlock = 0x6002_8000 as *const _;
2056 #[doc = r"Return the pointer to the register block"]
2057 #[inline(always)]
2058 pub const fn ptr() -> *const sdhost::RegisterBlock {
2059 Self::PTR
2060 }
2061 #[doc = r" Steal an instance of this peripheral"]
2062 #[doc = r""]
2063 #[doc = r" # Safety"]
2064 #[doc = r""]
2065 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2066 #[doc = r" that may race with any existing instances, for example by only"]
2067 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2068 #[doc = r" original peripheral and using critical sections to coordinate"]
2069 #[doc = r" access between multiple new instances."]
2070 #[doc = r""]
2071 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2072 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2073 #[doc = r" no stolen instances are passed to such software."]
2074 pub unsafe fn steal() -> Self {
2075 Self {
2076 _marker: PhantomData,
2077 }
2078 }
2079}
2080impl Deref for SDHOST {
2081 type Target = sdhost::RegisterBlock;
2082 #[inline(always)]
2083 fn deref(&self) -> &Self::Target {
2084 unsafe { &*Self::PTR }
2085 }
2086}
2087impl core::fmt::Debug for SDHOST {
2088 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2089 f.debug_struct("SDHOST").finish()
2090 }
2091}
2092#[doc = "SD/MMC Host Controller"]
2093pub mod sdhost;
2094#[doc = "SENS Peripheral"]
2095pub struct SENS {
2096 _marker: PhantomData<*const ()>,
2097}
2098unsafe impl Send for SENS {}
2099impl SENS {
2100 #[doc = r"Pointer to the register block"]
2101 pub const PTR: *const sens::RegisterBlock = 0x6000_8800 as *const _;
2102 #[doc = r"Return the pointer to the register block"]
2103 #[inline(always)]
2104 pub const fn ptr() -> *const sens::RegisterBlock {
2105 Self::PTR
2106 }
2107 #[doc = r" Steal an instance of this peripheral"]
2108 #[doc = r""]
2109 #[doc = r" # Safety"]
2110 #[doc = r""]
2111 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2112 #[doc = r" that may race with any existing instances, for example by only"]
2113 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2114 #[doc = r" original peripheral and using critical sections to coordinate"]
2115 #[doc = r" access between multiple new instances."]
2116 #[doc = r""]
2117 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2118 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2119 #[doc = r" no stolen instances are passed to such software."]
2120 pub unsafe fn steal() -> Self {
2121 Self {
2122 _marker: PhantomData,
2123 }
2124 }
2125}
2126impl Deref for SENS {
2127 type Target = sens::RegisterBlock;
2128 #[inline(always)]
2129 fn deref(&self) -> &Self::Target {
2130 unsafe { &*Self::PTR }
2131 }
2132}
2133impl core::fmt::Debug for SENS {
2134 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2135 f.debug_struct("SENS").finish()
2136 }
2137}
2138#[doc = "SENS Peripheral"]
2139pub mod sens;
2140#[doc = "SENSITIVE Peripheral"]
2141pub struct SENSITIVE {
2142 _marker: PhantomData<*const ()>,
2143}
2144unsafe impl Send for SENSITIVE {}
2145impl SENSITIVE {
2146 #[doc = r"Pointer to the register block"]
2147 pub const PTR: *const sensitive::RegisterBlock = 0x600c_1000 as *const _;
2148 #[doc = r"Return the pointer to the register block"]
2149 #[inline(always)]
2150 pub const fn ptr() -> *const sensitive::RegisterBlock {
2151 Self::PTR
2152 }
2153 #[doc = r" Steal an instance of this peripheral"]
2154 #[doc = r""]
2155 #[doc = r" # Safety"]
2156 #[doc = r""]
2157 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2158 #[doc = r" that may race with any existing instances, for example by only"]
2159 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2160 #[doc = r" original peripheral and using critical sections to coordinate"]
2161 #[doc = r" access between multiple new instances."]
2162 #[doc = r""]
2163 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2164 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2165 #[doc = r" no stolen instances are passed to such software."]
2166 pub unsafe fn steal() -> Self {
2167 Self {
2168 _marker: PhantomData,
2169 }
2170 }
2171}
2172impl Deref for SENSITIVE {
2173 type Target = sensitive::RegisterBlock;
2174 #[inline(always)]
2175 fn deref(&self) -> &Self::Target {
2176 unsafe { &*Self::PTR }
2177 }
2178}
2179impl core::fmt::Debug for SENSITIVE {
2180 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2181 f.debug_struct("SENSITIVE").finish()
2182 }
2183}
2184#[doc = "SENSITIVE Peripheral"]
2185pub mod sensitive;
2186#[doc = "SHA (Secure Hash Algorithm) Accelerator"]
2187pub struct SHA {
2188 _marker: PhantomData<*const ()>,
2189}
2190unsafe impl Send for SHA {}
2191impl SHA {
2192 #[doc = r"Pointer to the register block"]
2193 pub const PTR: *const sha::RegisterBlock = 0x6003_b000 as *const _;
2194 #[doc = r"Return the pointer to the register block"]
2195 #[inline(always)]
2196 pub const fn ptr() -> *const sha::RegisterBlock {
2197 Self::PTR
2198 }
2199 #[doc = r" Steal an instance of this peripheral"]
2200 #[doc = r""]
2201 #[doc = r" # Safety"]
2202 #[doc = r""]
2203 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2204 #[doc = r" that may race with any existing instances, for example by only"]
2205 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2206 #[doc = r" original peripheral and using critical sections to coordinate"]
2207 #[doc = r" access between multiple new instances."]
2208 #[doc = r""]
2209 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2210 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2211 #[doc = r" no stolen instances are passed to such software."]
2212 pub unsafe fn steal() -> Self {
2213 Self {
2214 _marker: PhantomData,
2215 }
2216 }
2217}
2218impl Deref for SHA {
2219 type Target = sha::RegisterBlock;
2220 #[inline(always)]
2221 fn deref(&self) -> &Self::Target {
2222 unsafe { &*Self::PTR }
2223 }
2224}
2225impl core::fmt::Debug for SHA {
2226 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2227 f.debug_struct("SHA").finish()
2228 }
2229}
2230#[doc = "SHA (Secure Hash Algorithm) Accelerator"]
2231pub mod sha;
2232#[doc = "SPI (Serial Peripheral Interface) Controller 0"]
2233pub struct SPI0 {
2234 _marker: PhantomData<*const ()>,
2235}
2236unsafe impl Send for SPI0 {}
2237impl SPI0 {
2238 #[doc = r"Pointer to the register block"]
2239 pub const PTR: *const spi0::RegisterBlock = 0x6000_3000 as *const _;
2240 #[doc = r"Return the pointer to the register block"]
2241 #[inline(always)]
2242 pub const fn ptr() -> *const spi0::RegisterBlock {
2243 Self::PTR
2244 }
2245 #[doc = r" Steal an instance of this peripheral"]
2246 #[doc = r""]
2247 #[doc = r" # Safety"]
2248 #[doc = r""]
2249 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2250 #[doc = r" that may race with any existing instances, for example by only"]
2251 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2252 #[doc = r" original peripheral and using critical sections to coordinate"]
2253 #[doc = r" access between multiple new instances."]
2254 #[doc = r""]
2255 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2256 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2257 #[doc = r" no stolen instances are passed to such software."]
2258 pub unsafe fn steal() -> Self {
2259 Self {
2260 _marker: PhantomData,
2261 }
2262 }
2263}
2264impl Deref for SPI0 {
2265 type Target = spi0::RegisterBlock;
2266 #[inline(always)]
2267 fn deref(&self) -> &Self::Target {
2268 unsafe { &*Self::PTR }
2269 }
2270}
2271impl core::fmt::Debug for SPI0 {
2272 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2273 f.debug_struct("SPI0").finish()
2274 }
2275}
2276#[doc = "SPI (Serial Peripheral Interface) Controller 0"]
2277pub mod spi0;
2278#[doc = "SPI (Serial Peripheral Interface) Controller 1"]
2279pub struct SPI1 {
2280 _marker: PhantomData<*const ()>,
2281}
2282unsafe impl Send for SPI1 {}
2283impl SPI1 {
2284 #[doc = r"Pointer to the register block"]
2285 pub const PTR: *const spi1::RegisterBlock = 0x6000_2000 as *const _;
2286 #[doc = r"Return the pointer to the register block"]
2287 #[inline(always)]
2288 pub const fn ptr() -> *const spi1::RegisterBlock {
2289 Self::PTR
2290 }
2291 #[doc = r" Steal an instance of this peripheral"]
2292 #[doc = r""]
2293 #[doc = r" # Safety"]
2294 #[doc = r""]
2295 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2296 #[doc = r" that may race with any existing instances, for example by only"]
2297 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2298 #[doc = r" original peripheral and using critical sections to coordinate"]
2299 #[doc = r" access between multiple new instances."]
2300 #[doc = r""]
2301 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2302 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2303 #[doc = r" no stolen instances are passed to such software."]
2304 pub unsafe fn steal() -> Self {
2305 Self {
2306 _marker: PhantomData,
2307 }
2308 }
2309}
2310impl Deref for SPI1 {
2311 type Target = spi1::RegisterBlock;
2312 #[inline(always)]
2313 fn deref(&self) -> &Self::Target {
2314 unsafe { &*Self::PTR }
2315 }
2316}
2317impl core::fmt::Debug for SPI1 {
2318 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2319 f.debug_struct("SPI1").finish()
2320 }
2321}
2322#[doc = "SPI (Serial Peripheral Interface) Controller 1"]
2323pub mod spi1;
2324#[doc = "SPI (Serial Peripheral Interface) Controller 2"]
2325pub struct SPI2 {
2326 _marker: PhantomData<*const ()>,
2327}
2328unsafe impl Send for SPI2 {}
2329impl SPI2 {
2330 #[doc = r"Pointer to the register block"]
2331 pub const PTR: *const spi2::RegisterBlock = 0x6002_4000 as *const _;
2332 #[doc = r"Return the pointer to the register block"]
2333 #[inline(always)]
2334 pub const fn ptr() -> *const spi2::RegisterBlock {
2335 Self::PTR
2336 }
2337 #[doc = r" Steal an instance of this peripheral"]
2338 #[doc = r""]
2339 #[doc = r" # Safety"]
2340 #[doc = r""]
2341 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2342 #[doc = r" that may race with any existing instances, for example by only"]
2343 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2344 #[doc = r" original peripheral and using critical sections to coordinate"]
2345 #[doc = r" access between multiple new instances."]
2346 #[doc = r""]
2347 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2348 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2349 #[doc = r" no stolen instances are passed to such software."]
2350 pub unsafe fn steal() -> Self {
2351 Self {
2352 _marker: PhantomData,
2353 }
2354 }
2355}
2356impl Deref for SPI2 {
2357 type Target = spi2::RegisterBlock;
2358 #[inline(always)]
2359 fn deref(&self) -> &Self::Target {
2360 unsafe { &*Self::PTR }
2361 }
2362}
2363impl core::fmt::Debug for SPI2 {
2364 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2365 f.debug_struct("SPI2").finish()
2366 }
2367}
2368#[doc = "SPI (Serial Peripheral Interface) Controller 2"]
2369pub mod spi2;
2370#[doc = "SPI (Serial Peripheral Interface) Controller 3"]
2371pub struct SPI3 {
2372 _marker: PhantomData<*const ()>,
2373}
2374unsafe impl Send for SPI3 {}
2375impl SPI3 {
2376 #[doc = r"Pointer to the register block"]
2377 pub const PTR: *const spi2::RegisterBlock = 0x6002_5000 as *const _;
2378 #[doc = r"Return the pointer to the register block"]
2379 #[inline(always)]
2380 pub const fn ptr() -> *const spi2::RegisterBlock {
2381 Self::PTR
2382 }
2383 #[doc = r" Steal an instance of this peripheral"]
2384 #[doc = r""]
2385 #[doc = r" # Safety"]
2386 #[doc = r""]
2387 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2388 #[doc = r" that may race with any existing instances, for example by only"]
2389 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2390 #[doc = r" original peripheral and using critical sections to coordinate"]
2391 #[doc = r" access between multiple new instances."]
2392 #[doc = r""]
2393 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2394 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2395 #[doc = r" no stolen instances are passed to such software."]
2396 pub unsafe fn steal() -> Self {
2397 Self {
2398 _marker: PhantomData,
2399 }
2400 }
2401}
2402impl Deref for SPI3 {
2403 type Target = spi2::RegisterBlock;
2404 #[inline(always)]
2405 fn deref(&self) -> &Self::Target {
2406 unsafe { &*Self::PTR }
2407 }
2408}
2409impl core::fmt::Debug for SPI3 {
2410 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2411 f.debug_struct("SPI3").finish()
2412 }
2413}
2414#[doc = "SPI (Serial Peripheral Interface) Controller 3"]
2415pub use self::spi2 as spi3;
2416#[doc = "System Configuration Registers"]
2417pub struct SYSTEM {
2418 _marker: PhantomData<*const ()>,
2419}
2420unsafe impl Send for SYSTEM {}
2421impl SYSTEM {
2422 #[doc = r"Pointer to the register block"]
2423 pub const PTR: *const system::RegisterBlock = 0x600c_0000 as *const _;
2424 #[doc = r"Return the pointer to the register block"]
2425 #[inline(always)]
2426 pub const fn ptr() -> *const system::RegisterBlock {
2427 Self::PTR
2428 }
2429 #[doc = r" Steal an instance of this peripheral"]
2430 #[doc = r""]
2431 #[doc = r" # Safety"]
2432 #[doc = r""]
2433 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2434 #[doc = r" that may race with any existing instances, for example by only"]
2435 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2436 #[doc = r" original peripheral and using critical sections to coordinate"]
2437 #[doc = r" access between multiple new instances."]
2438 #[doc = r""]
2439 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2440 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2441 #[doc = r" no stolen instances are passed to such software."]
2442 pub unsafe fn steal() -> Self {
2443 Self {
2444 _marker: PhantomData,
2445 }
2446 }
2447}
2448impl Deref for SYSTEM {
2449 type Target = system::RegisterBlock;
2450 #[inline(always)]
2451 fn deref(&self) -> &Self::Target {
2452 unsafe { &*Self::PTR }
2453 }
2454}
2455impl core::fmt::Debug for SYSTEM {
2456 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2457 f.debug_struct("SYSTEM").finish()
2458 }
2459}
2460#[doc = "System Configuration Registers"]
2461pub mod system;
2462#[doc = "System Timer"]
2463pub struct SYSTIMER {
2464 _marker: PhantomData<*const ()>,
2465}
2466unsafe impl Send for SYSTIMER {}
2467impl SYSTIMER {
2468 #[doc = r"Pointer to the register block"]
2469 pub const PTR: *const systimer::RegisterBlock = 0x6002_3000 as *const _;
2470 #[doc = r"Return the pointer to the register block"]
2471 #[inline(always)]
2472 pub const fn ptr() -> *const systimer::RegisterBlock {
2473 Self::PTR
2474 }
2475 #[doc = r" Steal an instance of this peripheral"]
2476 #[doc = r""]
2477 #[doc = r" # Safety"]
2478 #[doc = r""]
2479 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2480 #[doc = r" that may race with any existing instances, for example by only"]
2481 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2482 #[doc = r" original peripheral and using critical sections to coordinate"]
2483 #[doc = r" access between multiple new instances."]
2484 #[doc = r""]
2485 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2486 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2487 #[doc = r" no stolen instances are passed to such software."]
2488 pub unsafe fn steal() -> Self {
2489 Self {
2490 _marker: PhantomData,
2491 }
2492 }
2493}
2494impl Deref for SYSTIMER {
2495 type Target = systimer::RegisterBlock;
2496 #[inline(always)]
2497 fn deref(&self) -> &Self::Target {
2498 unsafe { &*Self::PTR }
2499 }
2500}
2501impl core::fmt::Debug for SYSTIMER {
2502 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2503 f.debug_struct("SYSTIMER").finish()
2504 }
2505}
2506#[doc = "System Timer"]
2507pub mod systimer;
2508#[doc = "Timer Group 0"]
2509pub struct TIMG0 {
2510 _marker: PhantomData<*const ()>,
2511}
2512unsafe impl Send for TIMG0 {}
2513impl TIMG0 {
2514 #[doc = r"Pointer to the register block"]
2515 pub const PTR: *const timg0::RegisterBlock = 0x6001_f000 as *const _;
2516 #[doc = r"Return the pointer to the register block"]
2517 #[inline(always)]
2518 pub const fn ptr() -> *const timg0::RegisterBlock {
2519 Self::PTR
2520 }
2521 #[doc = r" Steal an instance of this peripheral"]
2522 #[doc = r""]
2523 #[doc = r" # Safety"]
2524 #[doc = r""]
2525 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2526 #[doc = r" that may race with any existing instances, for example by only"]
2527 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2528 #[doc = r" original peripheral and using critical sections to coordinate"]
2529 #[doc = r" access between multiple new instances."]
2530 #[doc = r""]
2531 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2532 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2533 #[doc = r" no stolen instances are passed to such software."]
2534 pub unsafe fn steal() -> Self {
2535 Self {
2536 _marker: PhantomData,
2537 }
2538 }
2539}
2540impl Deref for TIMG0 {
2541 type Target = timg0::RegisterBlock;
2542 #[inline(always)]
2543 fn deref(&self) -> &Self::Target {
2544 unsafe { &*Self::PTR }
2545 }
2546}
2547impl core::fmt::Debug for TIMG0 {
2548 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2549 f.debug_struct("TIMG0").finish()
2550 }
2551}
2552#[doc = "Timer Group 0"]
2553pub mod timg0;
2554#[doc = "Timer Group 1"]
2555pub struct TIMG1 {
2556 _marker: PhantomData<*const ()>,
2557}
2558unsafe impl Send for TIMG1 {}
2559impl TIMG1 {
2560 #[doc = r"Pointer to the register block"]
2561 pub const PTR: *const timg0::RegisterBlock = 0x6002_0000 as *const _;
2562 #[doc = r"Return the pointer to the register block"]
2563 #[inline(always)]
2564 pub const fn ptr() -> *const timg0::RegisterBlock {
2565 Self::PTR
2566 }
2567 #[doc = r" Steal an instance of this peripheral"]
2568 #[doc = r""]
2569 #[doc = r" # Safety"]
2570 #[doc = r""]
2571 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2572 #[doc = r" that may race with any existing instances, for example by only"]
2573 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2574 #[doc = r" original peripheral and using critical sections to coordinate"]
2575 #[doc = r" access between multiple new instances."]
2576 #[doc = r""]
2577 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2578 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2579 #[doc = r" no stolen instances are passed to such software."]
2580 pub unsafe fn steal() -> Self {
2581 Self {
2582 _marker: PhantomData,
2583 }
2584 }
2585}
2586impl Deref for TIMG1 {
2587 type Target = timg0::RegisterBlock;
2588 #[inline(always)]
2589 fn deref(&self) -> &Self::Target {
2590 unsafe { &*Self::PTR }
2591 }
2592}
2593impl core::fmt::Debug for TIMG1 {
2594 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2595 f.debug_struct("TIMG1").finish()
2596 }
2597}
2598#[doc = "Timer Group 1"]
2599pub use self::timg0 as timg1;
2600#[doc = "Two-Wire Automotive Interface"]
2601pub struct TWAI0 {
2602 _marker: PhantomData<*const ()>,
2603}
2604unsafe impl Send for TWAI0 {}
2605impl TWAI0 {
2606 #[doc = r"Pointer to the register block"]
2607 pub const PTR: *const twai0::RegisterBlock = 0x6002_b000 as *const _;
2608 #[doc = r"Return the pointer to the register block"]
2609 #[inline(always)]
2610 pub const fn ptr() -> *const twai0::RegisterBlock {
2611 Self::PTR
2612 }
2613 #[doc = r" Steal an instance of this peripheral"]
2614 #[doc = r""]
2615 #[doc = r" # Safety"]
2616 #[doc = r""]
2617 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2618 #[doc = r" that may race with any existing instances, for example by only"]
2619 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2620 #[doc = r" original peripheral and using critical sections to coordinate"]
2621 #[doc = r" access between multiple new instances."]
2622 #[doc = r""]
2623 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2624 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2625 #[doc = r" no stolen instances are passed to such software."]
2626 pub unsafe fn steal() -> Self {
2627 Self {
2628 _marker: PhantomData,
2629 }
2630 }
2631}
2632impl Deref for TWAI0 {
2633 type Target = twai0::RegisterBlock;
2634 #[inline(always)]
2635 fn deref(&self) -> &Self::Target {
2636 unsafe { &*Self::PTR }
2637 }
2638}
2639impl core::fmt::Debug for TWAI0 {
2640 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2641 f.debug_struct("TWAI0").finish()
2642 }
2643}
2644#[doc = "Two-Wire Automotive Interface"]
2645pub mod twai0;
2646#[doc = "UART (Universal Asynchronous Receiver-Transmitter) Controller 0"]
2647pub struct UART0 {
2648 _marker: PhantomData<*const ()>,
2649}
2650unsafe impl Send for UART0 {}
2651impl UART0 {
2652 #[doc = r"Pointer to the register block"]
2653 pub const PTR: *const uart0::RegisterBlock = 0x6000_0000 as *const _;
2654 #[doc = r"Return the pointer to the register block"]
2655 #[inline(always)]
2656 pub const fn ptr() -> *const uart0::RegisterBlock {
2657 Self::PTR
2658 }
2659 #[doc = r" Steal an instance of this peripheral"]
2660 #[doc = r""]
2661 #[doc = r" # Safety"]
2662 #[doc = r""]
2663 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2664 #[doc = r" that may race with any existing instances, for example by only"]
2665 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2666 #[doc = r" original peripheral and using critical sections to coordinate"]
2667 #[doc = r" access between multiple new instances."]
2668 #[doc = r""]
2669 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2670 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2671 #[doc = r" no stolen instances are passed to such software."]
2672 pub unsafe fn steal() -> Self {
2673 Self {
2674 _marker: PhantomData,
2675 }
2676 }
2677}
2678impl Deref for UART0 {
2679 type Target = uart0::RegisterBlock;
2680 #[inline(always)]
2681 fn deref(&self) -> &Self::Target {
2682 unsafe { &*Self::PTR }
2683 }
2684}
2685impl core::fmt::Debug for UART0 {
2686 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2687 f.debug_struct("UART0").finish()
2688 }
2689}
2690#[doc = "UART (Universal Asynchronous Receiver-Transmitter) Controller 0"]
2691pub mod uart0;
2692#[doc = "UART (Universal Asynchronous Receiver-Transmitter) Controller 1"]
2693pub struct UART1 {
2694 _marker: PhantomData<*const ()>,
2695}
2696unsafe impl Send for UART1 {}
2697impl UART1 {
2698 #[doc = r"Pointer to the register block"]
2699 pub const PTR: *const uart0::RegisterBlock = 0x6001_0000 as *const _;
2700 #[doc = r"Return the pointer to the register block"]
2701 #[inline(always)]
2702 pub const fn ptr() -> *const uart0::RegisterBlock {
2703 Self::PTR
2704 }
2705 #[doc = r" Steal an instance of this peripheral"]
2706 #[doc = r""]
2707 #[doc = r" # Safety"]
2708 #[doc = r""]
2709 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2710 #[doc = r" that may race with any existing instances, for example by only"]
2711 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2712 #[doc = r" original peripheral and using critical sections to coordinate"]
2713 #[doc = r" access between multiple new instances."]
2714 #[doc = r""]
2715 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2716 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2717 #[doc = r" no stolen instances are passed to such software."]
2718 pub unsafe fn steal() -> Self {
2719 Self {
2720 _marker: PhantomData,
2721 }
2722 }
2723}
2724impl Deref for UART1 {
2725 type Target = uart0::RegisterBlock;
2726 #[inline(always)]
2727 fn deref(&self) -> &Self::Target {
2728 unsafe { &*Self::PTR }
2729 }
2730}
2731impl core::fmt::Debug for UART1 {
2732 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2733 f.debug_struct("UART1").finish()
2734 }
2735}
2736#[doc = "UART (Universal Asynchronous Receiver-Transmitter) Controller 1"]
2737pub use self::uart0 as uart1;
2738#[doc = "UART (Universal Asynchronous Receiver-Transmitter) Controller 2"]
2739pub struct UART2 {
2740 _marker: PhantomData<*const ()>,
2741}
2742unsafe impl Send for UART2 {}
2743impl UART2 {
2744 #[doc = r"Pointer to the register block"]
2745 pub const PTR: *const uart0::RegisterBlock = 0x6002_e000 as *const _;
2746 #[doc = r"Return the pointer to the register block"]
2747 #[inline(always)]
2748 pub const fn ptr() -> *const uart0::RegisterBlock {
2749 Self::PTR
2750 }
2751 #[doc = r" Steal an instance of this peripheral"]
2752 #[doc = r""]
2753 #[doc = r" # Safety"]
2754 #[doc = r""]
2755 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2756 #[doc = r" that may race with any existing instances, for example by only"]
2757 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2758 #[doc = r" original peripheral and using critical sections to coordinate"]
2759 #[doc = r" access between multiple new instances."]
2760 #[doc = r""]
2761 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2762 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2763 #[doc = r" no stolen instances are passed to such software."]
2764 pub unsafe fn steal() -> Self {
2765 Self {
2766 _marker: PhantomData,
2767 }
2768 }
2769}
2770impl Deref for UART2 {
2771 type Target = uart0::RegisterBlock;
2772 #[inline(always)]
2773 fn deref(&self) -> &Self::Target {
2774 unsafe { &*Self::PTR }
2775 }
2776}
2777impl core::fmt::Debug for UART2 {
2778 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2779 f.debug_struct("UART2").finish()
2780 }
2781}
2782#[doc = "UART (Universal Asynchronous Receiver-Transmitter) Controller 2"]
2783pub use self::uart0 as uart2;
2784#[doc = "Universal Host Controller Interface 0"]
2785pub struct UHCI0 {
2786 _marker: PhantomData<*const ()>,
2787}
2788unsafe impl Send for UHCI0 {}
2789impl UHCI0 {
2790 #[doc = r"Pointer to the register block"]
2791 pub const PTR: *const uhci0::RegisterBlock = 0x6001_4000 as *const _;
2792 #[doc = r"Return the pointer to the register block"]
2793 #[inline(always)]
2794 pub const fn ptr() -> *const uhci0::RegisterBlock {
2795 Self::PTR
2796 }
2797 #[doc = r" Steal an instance of this peripheral"]
2798 #[doc = r""]
2799 #[doc = r" # Safety"]
2800 #[doc = r""]
2801 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2802 #[doc = r" that may race with any existing instances, for example by only"]
2803 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2804 #[doc = r" original peripheral and using critical sections to coordinate"]
2805 #[doc = r" access between multiple new instances."]
2806 #[doc = r""]
2807 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2808 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2809 #[doc = r" no stolen instances are passed to such software."]
2810 pub unsafe fn steal() -> Self {
2811 Self {
2812 _marker: PhantomData,
2813 }
2814 }
2815}
2816impl Deref for UHCI0 {
2817 type Target = uhci0::RegisterBlock;
2818 #[inline(always)]
2819 fn deref(&self) -> &Self::Target {
2820 unsafe { &*Self::PTR }
2821 }
2822}
2823impl core::fmt::Debug for UHCI0 {
2824 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2825 f.debug_struct("UHCI0").finish()
2826 }
2827}
2828#[doc = "Universal Host Controller Interface 0"]
2829pub mod uhci0;
2830#[doc = "Universal Host Controller Interface 1"]
2831pub struct UHCI1 {
2832 _marker: PhantomData<*const ()>,
2833}
2834unsafe impl Send for UHCI1 {}
2835impl UHCI1 {
2836 #[doc = r"Pointer to the register block"]
2837 pub const PTR: *const uhci0::RegisterBlock = 0x6000_c000 as *const _;
2838 #[doc = r"Return the pointer to the register block"]
2839 #[inline(always)]
2840 pub const fn ptr() -> *const uhci0::RegisterBlock {
2841 Self::PTR
2842 }
2843 #[doc = r" Steal an instance of this peripheral"]
2844 #[doc = r""]
2845 #[doc = r" # Safety"]
2846 #[doc = r""]
2847 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2848 #[doc = r" that may race with any existing instances, for example by only"]
2849 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2850 #[doc = r" original peripheral and using critical sections to coordinate"]
2851 #[doc = r" access between multiple new instances."]
2852 #[doc = r""]
2853 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2854 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2855 #[doc = r" no stolen instances are passed to such software."]
2856 pub unsafe fn steal() -> Self {
2857 Self {
2858 _marker: PhantomData,
2859 }
2860 }
2861}
2862impl Deref for UHCI1 {
2863 type Target = uhci0::RegisterBlock;
2864 #[inline(always)]
2865 fn deref(&self) -> &Self::Target {
2866 unsafe { &*Self::PTR }
2867 }
2868}
2869impl core::fmt::Debug for UHCI1 {
2870 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2871 f.debug_struct("UHCI1").finish()
2872 }
2873}
2874#[doc = "Universal Host Controller Interface 1"]
2875pub use self::uhci0 as uhci1;
2876#[doc = "USB OTG (On-The-Go)"]
2877pub struct USB0 {
2878 _marker: PhantomData<*const ()>,
2879}
2880unsafe impl Send for USB0 {}
2881impl USB0 {
2882 #[doc = r"Pointer to the register block"]
2883 pub const PTR: *const usb0::RegisterBlock = 0x6008_0000 as *const _;
2884 #[doc = r"Return the pointer to the register block"]
2885 #[inline(always)]
2886 pub const fn ptr() -> *const usb0::RegisterBlock {
2887 Self::PTR
2888 }
2889 #[doc = r" Steal an instance of this peripheral"]
2890 #[doc = r""]
2891 #[doc = r" # Safety"]
2892 #[doc = r""]
2893 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2894 #[doc = r" that may race with any existing instances, for example by only"]
2895 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2896 #[doc = r" original peripheral and using critical sections to coordinate"]
2897 #[doc = r" access between multiple new instances."]
2898 #[doc = r""]
2899 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2900 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2901 #[doc = r" no stolen instances are passed to such software."]
2902 pub unsafe fn steal() -> Self {
2903 Self {
2904 _marker: PhantomData,
2905 }
2906 }
2907}
2908impl Deref for USB0 {
2909 type Target = usb0::RegisterBlock;
2910 #[inline(always)]
2911 fn deref(&self) -> &Self::Target {
2912 unsafe { &*Self::PTR }
2913 }
2914}
2915impl core::fmt::Debug for USB0 {
2916 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2917 f.debug_struct("USB0").finish()
2918 }
2919}
2920#[doc = "USB OTG (On-The-Go)"]
2921pub mod usb0;
2922#[doc = "Full-speed USB Serial/JTAG Controller"]
2923pub struct USB_DEVICE {
2924 _marker: PhantomData<*const ()>,
2925}
2926unsafe impl Send for USB_DEVICE {}
2927impl USB_DEVICE {
2928 #[doc = r"Pointer to the register block"]
2929 pub const PTR: *const usb_device::RegisterBlock = 0x6003_8000 as *const _;
2930 #[doc = r"Return the pointer to the register block"]
2931 #[inline(always)]
2932 pub const fn ptr() -> *const usb_device::RegisterBlock {
2933 Self::PTR
2934 }
2935 #[doc = r" Steal an instance of this peripheral"]
2936 #[doc = r""]
2937 #[doc = r" # Safety"]
2938 #[doc = r""]
2939 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2940 #[doc = r" that may race with any existing instances, for example by only"]
2941 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2942 #[doc = r" original peripheral and using critical sections to coordinate"]
2943 #[doc = r" access between multiple new instances."]
2944 #[doc = r""]
2945 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2946 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2947 #[doc = r" no stolen instances are passed to such software."]
2948 pub unsafe fn steal() -> Self {
2949 Self {
2950 _marker: PhantomData,
2951 }
2952 }
2953}
2954impl Deref for USB_DEVICE {
2955 type Target = usb_device::RegisterBlock;
2956 #[inline(always)]
2957 fn deref(&self) -> &Self::Target {
2958 unsafe { &*Self::PTR }
2959 }
2960}
2961impl core::fmt::Debug for USB_DEVICE {
2962 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
2963 f.debug_struct("USB_DEVICE").finish()
2964 }
2965}
2966#[doc = "Full-speed USB Serial/JTAG Controller"]
2967pub mod usb_device;
2968#[doc = "USB_WRAP Peripheral"]
2969pub struct USB_WRAP {
2970 _marker: PhantomData<*const ()>,
2971}
2972unsafe impl Send for USB_WRAP {}
2973impl USB_WRAP {
2974 #[doc = r"Pointer to the register block"]
2975 pub const PTR: *const usb_wrap::RegisterBlock = 0x6003_9000 as *const _;
2976 #[doc = r"Return the pointer to the register block"]
2977 #[inline(always)]
2978 pub const fn ptr() -> *const usb_wrap::RegisterBlock {
2979 Self::PTR
2980 }
2981 #[doc = r" Steal an instance of this peripheral"]
2982 #[doc = r""]
2983 #[doc = r" # Safety"]
2984 #[doc = r""]
2985 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
2986 #[doc = r" that may race with any existing instances, for example by only"]
2987 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
2988 #[doc = r" original peripheral and using critical sections to coordinate"]
2989 #[doc = r" access between multiple new instances."]
2990 #[doc = r""]
2991 #[doc = r" Additionally, other software such as HALs may rely on only one"]
2992 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
2993 #[doc = r" no stolen instances are passed to such software."]
2994 pub unsafe fn steal() -> Self {
2995 Self {
2996 _marker: PhantomData,
2997 }
2998 }
2999}
3000impl Deref for USB_WRAP {
3001 type Target = usb_wrap::RegisterBlock;
3002 #[inline(always)]
3003 fn deref(&self) -> &Self::Target {
3004 unsafe { &*Self::PTR }
3005 }
3006}
3007impl core::fmt::Debug for USB_WRAP {
3008 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
3009 f.debug_struct("USB_WRAP").finish()
3010 }
3011}
3012#[doc = "USB_WRAP Peripheral"]
3013pub mod usb_wrap;
3014#[doc = "WCL Peripheral"]
3015pub struct WCL {
3016 _marker: PhantomData<*const ()>,
3017}
3018unsafe impl Send for WCL {}
3019impl WCL {
3020 #[doc = r"Pointer to the register block"]
3021 pub const PTR: *const wcl::RegisterBlock = 0x600d_0000 as *const _;
3022 #[doc = r"Return the pointer to the register block"]
3023 #[inline(always)]
3024 pub const fn ptr() -> *const wcl::RegisterBlock {
3025 Self::PTR
3026 }
3027 #[doc = r" Steal an instance of this peripheral"]
3028 #[doc = r""]
3029 #[doc = r" # Safety"]
3030 #[doc = r""]
3031 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
3032 #[doc = r" that may race with any existing instances, for example by only"]
3033 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
3034 #[doc = r" original peripheral and using critical sections to coordinate"]
3035 #[doc = r" access between multiple new instances."]
3036 #[doc = r""]
3037 #[doc = r" Additionally, other software such as HALs may rely on only one"]
3038 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
3039 #[doc = r" no stolen instances are passed to such software."]
3040 pub unsafe fn steal() -> Self {
3041 Self {
3042 _marker: PhantomData,
3043 }
3044 }
3045}
3046impl Deref for WCL {
3047 type Target = wcl::RegisterBlock;
3048 #[inline(always)]
3049 fn deref(&self) -> &Self::Target {
3050 unsafe { &*Self::PTR }
3051 }
3052}
3053impl core::fmt::Debug for WCL {
3054 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
3055 f.debug_struct("WCL").finish()
3056 }
3057}
3058#[doc = "WCL Peripheral"]
3059pub mod wcl;
3060#[doc = "XTS-AES-128 Flash Encryption"]
3061pub struct XTS_AES {
3062 _marker: PhantomData<*const ()>,
3063}
3064unsafe impl Send for XTS_AES {}
3065impl XTS_AES {
3066 #[doc = r"Pointer to the register block"]
3067 pub const PTR: *const xts_aes::RegisterBlock = 0x600c_c000 as *const _;
3068 #[doc = r"Return the pointer to the register block"]
3069 #[inline(always)]
3070 pub const fn ptr() -> *const xts_aes::RegisterBlock {
3071 Self::PTR
3072 }
3073 #[doc = r" Steal an instance of this peripheral"]
3074 #[doc = r""]
3075 #[doc = r" # Safety"]
3076 #[doc = r""]
3077 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
3078 #[doc = r" that may race with any existing instances, for example by only"]
3079 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
3080 #[doc = r" original peripheral and using critical sections to coordinate"]
3081 #[doc = r" access between multiple new instances."]
3082 #[doc = r""]
3083 #[doc = r" Additionally, other software such as HALs may rely on only one"]
3084 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
3085 #[doc = r" no stolen instances are passed to such software."]
3086 pub unsafe fn steal() -> Self {
3087 Self {
3088 _marker: PhantomData,
3089 }
3090 }
3091}
3092impl Deref for XTS_AES {
3093 type Target = xts_aes::RegisterBlock;
3094 #[inline(always)]
3095 fn deref(&self) -> &Self::Target {
3096 unsafe { &*Self::PTR }
3097 }
3098}
3099impl core::fmt::Debug for XTS_AES {
3100 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
3101 f.debug_struct("XTS_AES").finish()
3102 }
3103}
3104#[doc = "XTS-AES-128 Flash Encryption"]
3105pub mod xts_aes;
3106#[doc = "NRX Peripheral"]
3107pub struct NRX {
3108 _marker: PhantomData<*const ()>,
3109}
3110unsafe impl Send for NRX {}
3111impl NRX {
3112 #[doc = r"Pointer to the register block"]
3113 pub const PTR: *const nrx::RegisterBlock = 0x6001_cc00 as *const _;
3114 #[doc = r"Return the pointer to the register block"]
3115 #[inline(always)]
3116 pub const fn ptr() -> *const nrx::RegisterBlock {
3117 Self::PTR
3118 }
3119 #[doc = r" Steal an instance of this peripheral"]
3120 #[doc = r""]
3121 #[doc = r" # Safety"]
3122 #[doc = r""]
3123 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
3124 #[doc = r" that may race with any existing instances, for example by only"]
3125 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
3126 #[doc = r" original peripheral and using critical sections to coordinate"]
3127 #[doc = r" access between multiple new instances."]
3128 #[doc = r""]
3129 #[doc = r" Additionally, other software such as HALs may rely on only one"]
3130 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
3131 #[doc = r" no stolen instances are passed to such software."]
3132 pub unsafe fn steal() -> Self {
3133 Self {
3134 _marker: PhantomData,
3135 }
3136 }
3137}
3138impl Deref for NRX {
3139 type Target = nrx::RegisterBlock;
3140 #[inline(always)]
3141 fn deref(&self) -> &Self::Target {
3142 unsafe { &*Self::PTR }
3143 }
3144}
3145impl core::fmt::Debug for NRX {
3146 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
3147 f.debug_struct("NRX").finish()
3148 }
3149}
3150#[doc = "NRX Peripheral"]
3151pub mod nrx;
3152#[doc = "need des"]
3153pub struct FE {
3154 _marker: PhantomData<*const ()>,
3155}
3156unsafe impl Send for FE {}
3157impl FE {
3158 #[doc = r"Pointer to the register block"]
3159 pub const PTR: *const fe::RegisterBlock = 0x6000_6000 as *const _;
3160 #[doc = r"Return the pointer to the register block"]
3161 #[inline(always)]
3162 pub const fn ptr() -> *const fe::RegisterBlock {
3163 Self::PTR
3164 }
3165 #[doc = r" Steal an instance of this peripheral"]
3166 #[doc = r""]
3167 #[doc = r" # Safety"]
3168 #[doc = r""]
3169 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
3170 #[doc = r" that may race with any existing instances, for example by only"]
3171 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
3172 #[doc = r" original peripheral and using critical sections to coordinate"]
3173 #[doc = r" access between multiple new instances."]
3174 #[doc = r""]
3175 #[doc = r" Additionally, other software such as HALs may rely on only one"]
3176 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
3177 #[doc = r" no stolen instances are passed to such software."]
3178 pub unsafe fn steal() -> Self {
3179 Self {
3180 _marker: PhantomData,
3181 }
3182 }
3183}
3184impl Deref for FE {
3185 type Target = fe::RegisterBlock;
3186 #[inline(always)]
3187 fn deref(&self) -> &Self::Target {
3188 unsafe { &*Self::PTR }
3189 }
3190}
3191impl core::fmt::Debug for FE {
3192 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
3193 f.debug_struct("FE").finish()
3194 }
3195}
3196#[doc = "need des"]
3197pub mod fe;
3198#[doc = "need des"]
3199pub struct FE2 {
3200 _marker: PhantomData<*const ()>,
3201}
3202unsafe impl Send for FE2 {}
3203impl FE2 {
3204 #[doc = r"Pointer to the register block"]
3205 pub const PTR: *const fe2::RegisterBlock = 0x6000_5000 as *const _;
3206 #[doc = r"Return the pointer to the register block"]
3207 #[inline(always)]
3208 pub const fn ptr() -> *const fe2::RegisterBlock {
3209 Self::PTR
3210 }
3211 #[doc = r" Steal an instance of this peripheral"]
3212 #[doc = r""]
3213 #[doc = r" # Safety"]
3214 #[doc = r""]
3215 #[doc = r" Ensure that the new instance of the peripheral cannot be used in a way"]
3216 #[doc = r" that may race with any existing instances, for example by only"]
3217 #[doc = r" accessing read-only or write-only registers, or by consuming the"]
3218 #[doc = r" original peripheral and using critical sections to coordinate"]
3219 #[doc = r" access between multiple new instances."]
3220 #[doc = r""]
3221 #[doc = r" Additionally, other software such as HALs may rely on only one"]
3222 #[doc = r" peripheral instance existing to ensure memory safety; ensure"]
3223 #[doc = r" no stolen instances are passed to such software."]
3224 pub unsafe fn steal() -> Self {
3225 Self {
3226 _marker: PhantomData,
3227 }
3228 }
3229}
3230impl Deref for FE2 {
3231 type Target = fe2::RegisterBlock;
3232 #[inline(always)]
3233 fn deref(&self) -> &Self::Target {
3234 unsafe { &*Self::PTR }
3235 }
3236}
3237impl core::fmt::Debug for FE2 {
3238 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
3239 f.debug_struct("FE2").finish()
3240 }
3241}
3242#[doc = "need des"]
3243pub mod fe2;
3244#[no_mangle]
3245static mut DEVICE_PERIPHERALS: bool = false;
3246#[doc = r" All the peripherals."]
3247#[allow(non_snake_case)]
3248pub struct Peripherals {
3249 #[doc = "AES"]
3250 pub AES: AES,
3251 #[doc = "APB_CTRL"]
3252 pub APB_CTRL: APB_CTRL,
3253 #[doc = "APB_SARADC"]
3254 pub APB_SARADC: APB_SARADC,
3255 #[doc = "BB"]
3256 pub BB: BB,
3257 #[doc = "ASSIST_DEBUG"]
3258 pub ASSIST_DEBUG: ASSIST_DEBUG,
3259 #[doc = "DMA"]
3260 pub DMA: DMA,
3261 #[doc = "DS"]
3262 pub DS: DS,
3263 #[doc = "EFUSE"]
3264 pub EFUSE: EFUSE,
3265 #[doc = "EXTMEM"]
3266 pub EXTMEM: EXTMEM,
3267 #[doc = "GPIO"]
3268 pub GPIO: GPIO,
3269 #[doc = "GPIO_SD"]
3270 pub GPIO_SD: GPIO_SD,
3271 #[doc = "HMAC"]
3272 pub HMAC: HMAC,
3273 #[doc = "I2C0"]
3274 pub I2C0: I2C0,
3275 #[doc = "I2C1"]
3276 pub I2C1: I2C1,
3277 #[doc = "I2S0"]
3278 pub I2S0: I2S0,
3279 #[doc = "I2S1"]
3280 pub I2S1: I2S1,
3281 #[doc = "INTERRUPT_CORE0"]
3282 pub INTERRUPT_CORE0: INTERRUPT_CORE0,
3283 #[doc = "INTERRUPT_CORE1"]
3284 pub INTERRUPT_CORE1: INTERRUPT_CORE1,
3285 #[doc = "IO_MUX"]
3286 pub IO_MUX: IO_MUX,
3287 #[doc = "LCD_CAM"]
3288 pub LCD_CAM: LCD_CAM,
3289 #[doc = "LEDC"]
3290 pub LEDC: LEDC,
3291 #[doc = "PCNT"]
3292 pub PCNT: PCNT,
3293 #[doc = "PERI_BACKUP"]
3294 pub PERI_BACKUP: PERI_BACKUP,
3295 #[doc = "MCPWM0"]
3296 pub MCPWM0: MCPWM0,
3297 #[doc = "MCPWM1"]
3298 pub MCPWM1: MCPWM1,
3299 #[doc = "RMT"]
3300 pub RMT: RMT,
3301 #[doc = "RNG"]
3302 pub RNG: RNG,
3303 #[doc = "RSA"]
3304 pub RSA: RSA,
3305 #[doc = "RTC_CNTL"]
3306 pub RTC_CNTL: RTC_CNTL,
3307 #[doc = "RTC_I2C"]
3308 pub RTC_I2C: RTC_I2C,
3309 #[doc = "RTC_IO"]
3310 pub RTC_IO: RTC_IO,
3311 #[doc = "SDHOST"]
3312 pub SDHOST: SDHOST,
3313 #[doc = "SENS"]
3314 pub SENS: SENS,
3315 #[doc = "SENSITIVE"]
3316 pub SENSITIVE: SENSITIVE,
3317 #[doc = "SHA"]
3318 pub SHA: SHA,
3319 #[doc = "SPI0"]
3320 pub SPI0: SPI0,
3321 #[doc = "SPI1"]
3322 pub SPI1: SPI1,
3323 #[doc = "SPI2"]
3324 pub SPI2: SPI2,
3325 #[doc = "SPI3"]
3326 pub SPI3: SPI3,
3327 #[doc = "SYSTEM"]
3328 pub SYSTEM: SYSTEM,
3329 #[doc = "SYSTIMER"]
3330 pub SYSTIMER: SYSTIMER,
3331 #[doc = "TIMG0"]
3332 pub TIMG0: TIMG0,
3333 #[doc = "TIMG1"]
3334 pub TIMG1: TIMG1,
3335 #[doc = "TWAI0"]
3336 pub TWAI0: TWAI0,
3337 #[doc = "UART0"]
3338 pub UART0: UART0,
3339 #[doc = "UART1"]
3340 pub UART1: UART1,
3341 #[doc = "UART2"]
3342 pub UART2: UART2,
3343 #[doc = "UHCI0"]
3344 pub UHCI0: UHCI0,
3345 #[doc = "UHCI1"]
3346 pub UHCI1: UHCI1,
3347 #[doc = "USB0"]
3348 pub USB0: USB0,
3349 #[doc = "USB_DEVICE"]
3350 pub USB_DEVICE: USB_DEVICE,
3351 #[doc = "USB_WRAP"]
3352 pub USB_WRAP: USB_WRAP,
3353 #[doc = "WCL"]
3354 pub WCL: WCL,
3355 #[doc = "XTS_AES"]
3356 pub XTS_AES: XTS_AES,
3357 #[doc = "NRX"]
3358 pub NRX: NRX,
3359 #[doc = "FE"]
3360 pub FE: FE,
3361 #[doc = "FE2"]
3362 pub FE2: FE2,
3363}
3364impl Peripherals {
3365 #[doc = r" Returns all the peripherals *once*."]
3366 #[cfg(feature = "critical-section")]
3367 #[inline]
3368 pub fn take() -> Option<Self> {
3369 critical_section::with(|_| {
3370 if unsafe { DEVICE_PERIPHERALS } {
3371 return None;
3372 }
3373 Some(unsafe { Peripherals::steal() })
3374 })
3375 }
3376 #[doc = r" Unchecked version of `Peripherals::take`."]
3377 #[doc = r""]
3378 #[doc = r" # Safety"]
3379 #[doc = r""]
3380 #[doc = r" Each of the returned peripherals must be used at most once."]
3381 #[inline]
3382 pub unsafe fn steal() -> Self {
3383 DEVICE_PERIPHERALS = true;
3384 Peripherals {
3385 AES: AES::steal(),
3386 APB_CTRL: APB_CTRL::steal(),
3387 APB_SARADC: APB_SARADC::steal(),
3388 BB: BB::steal(),
3389 ASSIST_DEBUG: ASSIST_DEBUG::steal(),
3390 DMA: DMA::steal(),
3391 DS: DS::steal(),
3392 EFUSE: EFUSE::steal(),
3393 EXTMEM: EXTMEM::steal(),
3394 GPIO: GPIO::steal(),
3395 GPIO_SD: GPIO_SD::steal(),
3396 HMAC: HMAC::steal(),
3397 I2C0: I2C0::steal(),
3398 I2C1: I2C1::steal(),
3399 I2S0: I2S0::steal(),
3400 I2S1: I2S1::steal(),
3401 INTERRUPT_CORE0: INTERRUPT_CORE0::steal(),
3402 INTERRUPT_CORE1: INTERRUPT_CORE1::steal(),
3403 IO_MUX: IO_MUX::steal(),
3404 LCD_CAM: LCD_CAM::steal(),
3405 LEDC: LEDC::steal(),
3406 PCNT: PCNT::steal(),
3407 PERI_BACKUP: PERI_BACKUP::steal(),
3408 MCPWM0: MCPWM0::steal(),
3409 MCPWM1: MCPWM1::steal(),
3410 RMT: RMT::steal(),
3411 RNG: RNG::steal(),
3412 RSA: RSA::steal(),
3413 RTC_CNTL: RTC_CNTL::steal(),
3414 RTC_I2C: RTC_I2C::steal(),
3415 RTC_IO: RTC_IO::steal(),
3416 SDHOST: SDHOST::steal(),
3417 SENS: SENS::steal(),
3418 SENSITIVE: SENSITIVE::steal(),
3419 SHA: SHA::steal(),
3420 SPI0: SPI0::steal(),
3421 SPI1: SPI1::steal(),
3422 SPI2: SPI2::steal(),
3423 SPI3: SPI3::steal(),
3424 SYSTEM: SYSTEM::steal(),
3425 SYSTIMER: SYSTIMER::steal(),
3426 TIMG0: TIMG0::steal(),
3427 TIMG1: TIMG1::steal(),
3428 TWAI0: TWAI0::steal(),
3429 UART0: UART0::steal(),
3430 UART1: UART1::steal(),
3431 UART2: UART2::steal(),
3432 UHCI0: UHCI0::steal(),
3433 UHCI1: UHCI1::steal(),
3434 USB0: USB0::steal(),
3435 USB_DEVICE: USB_DEVICE::steal(),
3436 USB_WRAP: USB_WRAP::steal(),
3437 WCL: WCL::steal(),
3438 XTS_AES: XTS_AES::steal(),
3439 NRX: NRX::steal(),
3440 FE: FE::steal(),
3441 FE2: FE2::steal(),
3442 }
3443 }
3444}