Clean IRAM and DRAM address space conversion macros

This commit is contained in:
wuzhenghui
2022-07-29 17:07:39 +08:00
parent 65aea5d177
commit 7cb9304b65
12 changed files with 24 additions and 32 deletions

View File

@@ -175,6 +175,10 @@
#define SOC_DIRAM_DRAM_LOW 0x3FCA0000
#define SOC_DIRAM_DRAM_HIGH 0x3FCE0000
#define SOC_I_D_OFFSET (SOC_DIRAM_IRAM_LOW - SOC_DIRAM_DRAM_LOW)
#define MAP_DRAM_TO_IRAM(addr) (addr + SOC_I_D_OFFSET)
#define MAP_IRAM_TO_DRAM(addr) (addr - SOC_I_D_OFFSET)
// Region of memory accessible via DMA. See esp_ptr_dma_capable().
#define SOC_DMA_LOW 0x3FC88000
#define SOC_DMA_HIGH 0x3FD00000
@@ -187,8 +191,6 @@
//(excluding RTC data region, that's checked separately.) See esp_ptr_internal().
#define SOC_MEM_INTERNAL_LOW 0x3FCA0000
#define SOC_MEM_INTERNAL_HIGH 0x3FCE0000
#define SOC_MEM_INTERNAL_LOW1 0x4037C000
#define SOC_MEM_INTERNAL_HIGH1 0x403C0000
#define SOC_MAX_CONTIGUOUS_RAM_SIZE (SOC_IRAM_HIGH - SOC_IRAM_LOW) ///< Largest span of contiguous memory (DRAM or IRAM) in the address space