/* ------------------------------------------- SPECIAL ---------------------------------------------- */
define symbol __ICFEDIT_intvec_start__ = 0x00000000;
/* -------------------------------------------- MEMORY ---------------------------------------------- */
define memory mem with size = 4G;
define symbol __ICFEDIT_region_ROM_start__ = 0x00000100;
define symbol __ICFEDIT_region_ROM_end__ = 0x0003FFFF;
define symbol __ICFEDIT_region_RAM_start__ = 0x10000000;
define symbol __ICFEDIT_region_RAM_end__ = 0x10007FFF;
/* ---------------------------------------- MEMORY REGIONS ------------------------------------------ */
define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to __ICFEDIT_region_ROM_end__];
define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_region_RAM_end__];
/* ----------------------------------------- STACKS & HEAP ----------------------------------------- */
define symbol __ICFEDIT_size_cstack__ = 0x200;
define symbol __ICFEDIT_size_heap__ = 0x100;
define symbol _AHB_RAM_start__ = 0x2007C000;
define symbol _AHB_RAM_end__ = 0x20083FFF;
define region AHB_RAM_region = mem:[from _AHB_RAM_start__ to _AHB_RAM_end__];
/* ----------------------------------------- INITIALIZATION ----------------------------------------- */
initialize by copy { readwrite };
do not initialize { section .noinit };
do not initialize { section USB_DMA_RAM };
place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec };
place in ROM_region { readonly };
place in RAM_region { readwrite,
block CSTACK, block HEAP };
place in AHB_RAM_region
{ readwrite data section AHB_RAM_MEMORY, section USB_DMA_RAM, section EMAC_DMA_RAM};