New VA108xx Rust workspace structure + dependency updates
- The workspace is now a monorepo without submodules. The HAL, PAC and BSP are integrated directly - Update all dependencies: embedded-hal v1 and RTIC v2
This commit is contained in:
51
va108xx/src/ioconfig.rs
Normal file
51
va108xx/src/ioconfig.rs
Normal file
@@ -0,0 +1,51 @@
|
||||
#[repr(C)]
|
||||
#[doc = "Register block"]
|
||||
pub struct RegisterBlock {
|
||||
porta: [Porta; 32],
|
||||
portb0: [Portb; 32],
|
||||
_reserved2: [u8; 0x0efc],
|
||||
perid: Perid,
|
||||
}
|
||||
impl RegisterBlock {
|
||||
#[doc = "0x00..0x80 - PORTA Pin Configuration Register"]
|
||||
#[inline(always)]
|
||||
pub const fn porta(&self, n: usize) -> &Porta {
|
||||
&self.porta[n]
|
||||
}
|
||||
#[doc = "Iterator for array of:"]
|
||||
#[doc = "0x00..0x80 - PORTA Pin Configuration Register"]
|
||||
#[inline(always)]
|
||||
pub fn porta_iter(&self) -> impl Iterator<Item = &Porta> {
|
||||
self.porta.iter()
|
||||
}
|
||||
#[doc = "0x80..0x100 - PORTB Pin Configuration Register"]
|
||||
#[inline(always)]
|
||||
pub const fn portb0(&self, n: usize) -> &Portb {
|
||||
&self.portb0[n]
|
||||
}
|
||||
#[doc = "Iterator for array of:"]
|
||||
#[doc = "0x80..0x100 - PORTB Pin Configuration Register"]
|
||||
#[inline(always)]
|
||||
pub fn portb0_iter(&self) -> impl Iterator<Item = &Portb> {
|
||||
self.portb0.iter()
|
||||
}
|
||||
#[doc = "0xffc - Peripheral ID Register"]
|
||||
#[inline(always)]
|
||||
pub const fn perid(&self) -> &Perid {
|
||||
&self.perid
|
||||
}
|
||||
}
|
||||
#[doc = "PORTA (rw) register accessor: PORTA Pin Configuration Register\n\nYou can [`read`](crate::generic::Reg::read) this register and get [`porta::R`]. You can [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`write_with_zero`](crate::generic::Reg::write_with_zero) this register using [`porta::W`]. You can also [`modify`](crate::generic::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [`mod@porta`]
|
||||
module"]
|
||||
#[doc(alias = "PORTA")]
|
||||
pub type Porta = crate::Reg<porta::PortaSpec>;
|
||||
#[doc = "PORTA Pin Configuration Register"]
|
||||
pub mod porta;
|
||||
pub use porta as portb;
|
||||
pub use Porta as Portb;
|
||||
#[doc = "PERID (r) register accessor: Peripheral ID Register\n\nYou can [`read`](crate::generic::Reg::read) this register and get [`perid::R`]. See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [`mod@perid`]
|
||||
module"]
|
||||
#[doc(alias = "PERID")]
|
||||
pub type Perid = crate::Reg<perid::PeridSpec>;
|
||||
#[doc = "Peripheral ID Register"]
|
||||
pub mod perid;
|
||||
Reference in New Issue
Block a user