From 4f381a1c68920caa1b369d45f01f1c9e66a19441 Mon Sep 17 00:00:00 2001 From: "dzzxzz@gmail.com" Date: Fri, 20 Apr 2012 03:19:23 +0000 Subject: [PATCH] update the IAR project for lpc176x, using the specified icf file and correct the rtthread-lpc17xx.icf file git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2094 bbd45198-f89e-11dd-88c7-29a3b14d5316 --- bsp/lpc176x/project.ewp | 266 ++++++++++++++++++++++++------- bsp/lpc176x/rtthread-lpc17xx.icf | 24 ++- bsp/lpc176x/template.ewp | 266 ++++++++++++++++++++++++------- 3 files changed, 438 insertions(+), 118 deletions(-) diff --git a/bsp/lpc176x/project.ewp b/bsp/lpc176x/project.ewp index b5dd6673c3..f5ba2b9c01 100644 --- a/bsp/lpc176x/project.ewp +++ b/bsp/lpc176x/project.ewp @@ -10,7 +10,7 @@ General 3 - 17 + 20 1 1 - + + + ICCARM 2 - 21 + 26 1 1 - - + + + + + + + + + + + + AARM 2 - 7 + 8 1 1 - @@ -813,7 +891,7 @@ General 3 - 17 + 20 1 0 - + + + ICCARM 2 - 21 + 26 1 0 - - + + + + + + + + + + + + AARM 2 - 7 + 8 1 0 - diff --git a/bsp/lpc176x/rtthread-lpc17xx.icf b/bsp/lpc176x/rtthread-lpc17xx.icf index 68d22fff9e..b24c7f2e89 100644 --- a/bsp/lpc176x/rtthread-lpc17xx.icf +++ b/bsp/lpc176x/rtthread-lpc17xx.icf @@ -4,29 +4,37 @@ /*-Specials-*/ define symbol __ICFEDIT_intvec_start__ = 0x00000000; /*-Memory Regions-*/ -define symbol __ICFEDIT_region_ROM_start__ = 0x00000000; +define symbol __ICFEDIT_region_ROM_start__ = 0x00000100; define symbol __ICFEDIT_region_ROM_end__ = 0x0007FFFF; -define symbol __ICFEDIT_region_RAM_start__ = 0x20000000; -define symbol __ICFEDIT_region_RAM_end__ = 0x2000FFFF; +define symbol __ICFEDIT_region_RAM_start__ = 0x10000000; +define symbol __ICFEDIT_region_RAM_end__ = 0x10007FFF; /*-Sizes-*/ -define symbol __ICFEDIT_size_cstack__ = 0x400; -define symbol __ICFEDIT_size_heap__ = 0x800; +define symbol __ICFEDIT_size_cstack__ = 0x800; +define symbol __ICFEDIT_size_heap__ = 0x400; /**** End of ICF editor section. ###ICF###*/ - define memory mem with size = 4G; 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__]; +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__]; + define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { }; define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { }; initialize by copy { readwrite }; -//initialize by copy with packing = none { section __DLIB_PERTHREAD }; // Required in a multi-threaded application do not initialize { section .noinit }; +do not initialize { section USB_DMA_RAM }; -place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec }; +keep { section FSymTab }; +keep { section VSymTab }; +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}; + diff --git a/bsp/lpc176x/template.ewp b/bsp/lpc176x/template.ewp index 3f66c77438..82f30e4724 100644 --- a/bsp/lpc176x/template.ewp +++ b/bsp/lpc176x/template.ewp @@ -12,7 +12,7 @@ General 3 - 17 + 20 1 1 - + + + ICCARM 2 - 21 + 26 1 1 - - + + + + + + + + + + + + AARM 2 - 7 + 8 1 1 - @@ -800,7 +878,7 @@ General 3 - 17 + 20 1 0 - + + + ICCARM 2 - 21 + 26 1 0 - - + + + + + + + + + + + + AARM 2 - 7 + 8 1 0 - -- GitLab