mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-16 08:38:26 +00:00
migrate more board parameters to board files
This commit is contained in:
parent
728fab3b62
commit
d6790489f1
2 changed files with 14 additions and 1 deletions
|
|
@ -12,15 +12,23 @@ pub const SPIM_RAM_IFRAM_ADDR: usize = utralib::HW_IFRAM0_MEM + utralib::HW_IFRA
|
|||
// app uart buffer
|
||||
pub const APP_UART_IFRAM_ADDR: usize = utralib::HW_IFRAM0_MEM + utralib::HW_IFRAM0_MEM_LEN - 3 * 4096;
|
||||
|
||||
// display buffer: 1 page for double-buffering, rounded up to 1 page for commands
|
||||
pub const DISPLAY_IFRAM_ADDR: usize = utralib::HW_IFRAM0_MEM + utralib::HW_IFRAM0_MEM_LEN - 5 * 4096;
|
||||
|
||||
// Flash needs 4096 bytes for Rx, and 0 bytes for Tx + 16 bytes for cmd for 2 pages total. This is released
|
||||
// after boot.
|
||||
pub const SPIM_FLASH_IFRAM_ADDR: usize = utralib::HW_IFRAM0_MEM + utralib::HW_IFRAM0_MEM_LEN - 5 * 4096;
|
||||
pub const SPIM_FLASH_IFRAM_ADDR: usize = utralib::HW_IFRAM0_MEM + utralib::HW_IFRAM0_MEM_LEN - 7 * 4096;
|
||||
|
||||
// USB pages - USB subsystem is a hog, needs a lot of pages
|
||||
pub const CRG_IFRAM_PAGES: usize = 22;
|
||||
pub const CRG_UDC_MEMBASE: usize =
|
||||
utralib::HW_IFRAM1_MEM + utralib::HW_IFRAM1_MEM_LEN - CRG_IFRAM_PAGES * 0x1000;
|
||||
|
||||
// MANUALLY SYNCED TO ALLOCATIONS ABOVE
|
||||
// inclusive numbering - we allocate pages from the top-down, so the last number should generally be 31
|
||||
pub const IFRAM0_RESERVED_PAGE_RANGE: [usize; 2] = [31 - 7, 31];
|
||||
pub const IFRAM1_RESERVED_PAGE_RANGE: [usize; 2] = [31 - CRG_IFRAM_PAGES, 31];
|
||||
|
||||
/// Setup pins for the baosec display
|
||||
pub fn setup_display_pins(iox: &dyn IoSetup) -> crate::udma::SpimChannel {
|
||||
const SPI_CS_PIN: u8 = 5;
|
||||
|
|
|
|||
|
|
@ -20,6 +20,11 @@ pub const CRG_IFRAM_PAGES: usize = 22;
|
|||
pub const CRG_UDC_MEMBASE: usize =
|
||||
utralib::HW_IFRAM1_MEM + utralib::HW_IFRAM1_MEM_LEN - CRG_IFRAM_PAGES * 0x1000;
|
||||
|
||||
// MANUALLY SYNCED TO ALLOCATIONS ABOVE
|
||||
// inclusive numbering - we allocate pages from the top-down, so the last number should generally be 31
|
||||
pub const IFRAM0_RESERVED_PAGE_RANGE: [usize; 2] = [31 - 5, 31];
|
||||
pub const IFRAM1_RESERVED_PAGE_RANGE: [usize; 2] = [31 - CRG_IFRAM_PAGES, 31];
|
||||
|
||||
/// Setup pins for the baosor display (Precursor memory LCD target)
|
||||
pub fn setup_display_pins(iox: &dyn IoSetup) -> crate::udma::SpimChannel {
|
||||
const SPI_CS_PIN: u8 = 5;
|
||||
|
|
|
|||
Loading…
Reference in a new issue