atsamd51j/
sercom0.rs

1#[repr(C)]
2#[doc = "Register block"]
3pub struct RegisterBlock {
4    _reserved_0_i2cm: [u8; 0x31],
5}
6impl RegisterBlock {
7    #[doc = "0x00..0x31 - USART INTERNAL CLOCK Mode"]
8    #[inline(always)]
9    pub const fn usart_int(&self) -> &UsartInt {
10        unsafe { &*(self as *const Self).cast::<u8>().add(0).cast() }
11    }
12    #[doc = "0x00..0x31 - USART EXTERNAL CLOCK Mode"]
13    #[inline(always)]
14    pub const fn usart_ext(&self) -> &UsartExt {
15        unsafe { &*(self as *const Self).cast::<u8>().add(0).cast() }
16    }
17    #[doc = "0x00..0x31 - SPI Master Mode"]
18    #[inline(always)]
19    pub const fn spim(&self) -> &Spim {
20        unsafe { &*(self as *const Self).cast::<u8>().add(0).cast() }
21    }
22    #[doc = "0x00..0x31 - SPI Slave Mode"]
23    #[inline(always)]
24    pub const fn spis(&self) -> &Spis {
25        unsafe { &*(self as *const Self).cast::<u8>().add(0).cast() }
26    }
27    #[doc = "0x00..0x2c - I2C Slave Mode"]
28    #[inline(always)]
29    pub const fn i2cs(&self) -> &I2cs {
30        unsafe { &*(self as *const Self).cast::<u8>().add(0).cast() }
31    }
32    #[doc = "0x00..0x31 - I2C Master Mode"]
33    #[inline(always)]
34    pub const fn i2cm(&self) -> &I2cm {
35        unsafe { &*(self as *const Self).cast::<u8>().add(0).cast() }
36    }
37}
38#[doc = "I2C Master Mode"]
39pub use self::i2cm::I2cm;
40#[doc = r"Cluster"]
41#[doc = "I2C Master Mode"]
42pub mod i2cm;
43#[doc = "I2C Slave Mode"]
44pub use self::i2cs::I2cs;
45#[doc = r"Cluster"]
46#[doc = "I2C Slave Mode"]
47pub mod i2cs;
48#[doc = "SPI Slave Mode"]
49pub use self::spis::Spis;
50#[doc = r"Cluster"]
51#[doc = "SPI Slave Mode"]
52pub mod spis;
53#[doc = "SPI Master Mode"]
54pub use self::spim::Spim;
55#[doc = r"Cluster"]
56#[doc = "SPI Master Mode"]
57pub mod spim;
58#[doc = "USART EXTERNAL CLOCK Mode"]
59pub use self::usart_ext::UsartExt;
60#[doc = r"Cluster"]
61#[doc = "USART EXTERNAL CLOCK Mode"]
62pub mod usart_ext;
63#[doc = "USART INTERNAL CLOCK Mode"]
64pub use self::usart_int::UsartInt;
65#[doc = r"Cluster"]
66#[doc = "USART INTERNAL CLOCK Mode"]
67pub mod usart_int;