mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-10-07 00:59:00 +08:00
[update] stm32mp1 link
This commit is contained in:
@@ -119,6 +119,7 @@ env:
|
||||
- RTT_BSP='stm32/stm32l476-st-nucleo' RTT_TOOL_CHAIN='sourcery-arm'
|
||||
- RTT_BSP='stm32/stm32l496-ali-developer' RTT_TOOL_CHAIN='sourcery-arm'
|
||||
- RTT_BSP='stm32/stm32l496-st-nucleo' RTT_TOOL_CHAIN='sourcery-arm'
|
||||
- RTT_BSP='stm32/stm32mp157a-st-discovery' RTT_TOOL_CHAIN='sourcery-arm'
|
||||
- RTT_BSP='stm32f20x' RTT_TOOL_CHAIN='sourcery-arm'
|
||||
- RTT_BSP='swm320-lq100' RTT_TOOL_CHAIN='sourcery-arm'
|
||||
# - RTT_BSP='taihu' RTT_TOOL_CHAIN='sourcery-ppc'
|
||||
|
||||
@@ -18,8 +18,6 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/* DMA2 stream0 */
|
||||
#if defined(BSP_SPI1_RX_USING_DMA) && !defined(SPI1_RX_DMA_INSTANCE)
|
||||
#define SPI1_DMA_RX_IRQHandler DMA2_Stream0_IRQHandler
|
||||
|
||||
@@ -47,8 +47,7 @@ menu "On-chip Peripheral Drivers"
|
||||
bool "Enable UART5"
|
||||
default n
|
||||
endif
|
||||
|
||||
source "../libraries/HAL_Drivers/Kconfig"
|
||||
source "../libraries/HAL_Drivers/Kconfig"
|
||||
|
||||
endmenu
|
||||
|
||||
|
||||
@@ -13,12 +13,10 @@ CubeMX_Config/Common/System/system_stm32mp1xx.c
|
||||
CubeMX_Config/CM4/Src/stm32mp1xx_hal_msp.c
|
||||
''')
|
||||
|
||||
|
||||
path = [cwd]
|
||||
path += [cwd + '/CubeMX_Config/CM4/Inc']
|
||||
path += [cwd + '/ports']
|
||||
|
||||
|
||||
startup_path_prefix = SDK_LIB
|
||||
|
||||
if rtconfig.CROSS_TOOL == 'gcc':
|
||||
@@ -28,18 +26,7 @@ elif rtconfig.CROSS_TOOL == 'keil':
|
||||
elif rtconfig.CROSS_TOOL == 'iar':
|
||||
src += [startup_path_prefix + '/STM32MPxx_HAL/CMSIS/Device/ST/STM32MP1xx/Source/Templates/iar/startup_stm32mp15xx.s']
|
||||
|
||||
if rtconfig.CROSS_TOOL == 'keil':
|
||||
CPPDEFINES = ['CORE_CM4,NO_ATOMIC_64_SUPPORT,METAL_INTERNAL,METAL_MAX_DEVICE_REGIONS=2,VIRTIO_SLAVE_ONLY,STM32MP157Axx,__LOG_TRACE_IO_']
|
||||
elif rtconfig.CROSS_TOOL == 'gcc':
|
||||
CPPDEFINES = ['CORE_CM4,NO_ATOMIC_64_SUPPORT,METAL_INTERNAL,METAL_MAX_DEVICE_REGIONS=2,VIRTIO_SLAVE_ONLY,STM32MP157Axx,__LOG_TRACE_IO_']
|
||||
elif rtconfig.CROSS_TOOL == 'iar':
|
||||
CPPDEFINES = ['CORE_CM4']
|
||||
CPPDEFINES += ['NO_ATOMIC_64_SUPPORT']
|
||||
CPPDEFINES += ['METAL_INTERNAL']
|
||||
CPPDEFINES += ['METAL_MAX_DEVICE_REGIONS=2']
|
||||
CPPDEFINES += ['VIRTIO_SLAVE_ONLY']
|
||||
CPPDEFINES += ['STM32MP157Axx']
|
||||
CPPDEFINES += ['__LOG_TRACE_IO_']
|
||||
CPPDEFINES = ['CORE_CM4','NO_ATOMIC_64_SUPPORT','METAL_INTERNAL','METAL_MAX_DEVICE_REGIONS=2','VIRTIO_SLAVE_ONLY','STM32MP157Axx','__LOG_TRACE_IO_']
|
||||
|
||||
group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path, CPPDEFINES = CPPDEFINES)
|
||||
|
||||
|
||||
@@ -23,11 +23,11 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
#define STM32_FLASH_START_ADRESS ((uint32_t)0x10000000)
|
||||
#define STM32_FLASH_SIZE (128 * 1024)
|
||||
#define STM32_FLASH_SIZE (256 * 1024)
|
||||
#define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE))
|
||||
|
||||
#define STM32_SRAM_SIZE (128)
|
||||
#define STM32_SRAM_END ((uint32_t)0x10020000 + (STM32_SRAM_SIZE * 1024))
|
||||
#define STM32_SRAM_END ((uint32_t)0x10040000 + (STM32_SRAM_SIZE * 1024))
|
||||
|
||||
#if defined(__CC_ARM) || defined(__CLANG_ARM)
|
||||
extern int Image$$RW_IRAM1$$ZI$$Limit;
|
||||
@@ -37,8 +37,7 @@ extern int Image$$RW_IRAM1$$ZI$$Limit;
|
||||
#define HEAP_BEGIN (__segment_end("CSTACK"))
|
||||
#else
|
||||
extern int __bss_end__;
|
||||
//#define HEAP_BEGIN (&__bss_end__)
|
||||
#define HEAP_BEGIN (0x10020000 + 64 * 1024)
|
||||
#define HEAP_BEGIN (0x10040000 + 64 * 1024)
|
||||
#endif
|
||||
|
||||
#define HEAP_END STM32_SRAM_END
|
||||
|
||||
@@ -1,34 +1,28 @@
|
||||
/*###ICF### Section handled by ICF editor, don't touch! ****/
|
||||
/*-Editor annotation file-*/
|
||||
/* IcfEditorFile="$TOOLKIT_DIR$\config\ide\IcfEditor\a_v1_0.xml" */
|
||||
/* IcfEditorFile="$TOOLKIT_DIR$\config\ide\IcfEditor\cortex_v1_0.xml" */
|
||||
/*-Specials-*/
|
||||
define symbol __ICFEDIT_intvec_start__ = 0x00000000;
|
||||
/*-Memory Regions-*/
|
||||
define symbol __ICFEDIT_region_text_start__ = 0x10000000;
|
||||
define symbol __ICFEDIT_region_text_end__ = 0x1003FFFF;
|
||||
define symbol __ICFEDIT_region_data_start__ = 0x10040000;
|
||||
define symbol __ICFEDIT_region_data_end__ = 0x1005FFFF;
|
||||
define symbol __ICFEDIT_region_ROM_start__ = 0x10000000;
|
||||
define symbol __ICFEDIT_region_ROM_end__ = 0x1003FFFF;
|
||||
define symbol __ICFEDIT_region_RAM_start__ = 0x10040000;
|
||||
define symbol __ICFEDIT_region_RAM_end__ = 0x1005FFFF;
|
||||
/*-Sizes-*/
|
||||
define symbol __ICFEDIT_size_cstack__ = 0x400;
|
||||
define symbol __ICFEDIT_size_heap__ = 0x000;
|
||||
/**** End of ICF editor section. ###ICF###*/
|
||||
|
||||
|
||||
define memory mem with size = 4G;
|
||||
define region text_region = mem:[from __ICFEDIT_region_text_start__ to __ICFEDIT_region_text_end__];
|
||||
define region data_region = mem:[from __ICFEDIT_region_data_start__ to __ICFEDIT_region_data_end__];
|
||||
|
||||
keep { section .resource_table };
|
||||
".resource_table" : place in data_region {section .resource_table};
|
||||
|
||||
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 block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
|
||||
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
|
||||
|
||||
initialize by copy { readwrite };
|
||||
do not initialize { section .noinit};
|
||||
do not initialize { section .noinit };
|
||||
|
||||
place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec };
|
||||
place in text_region { readonly };
|
||||
place in data_region { readwrite,
|
||||
block CSTACK, block HEAP};
|
||||
|
||||
place in ROM_region { readonly };
|
||||
place in RAM_region { readwrite, last block CSTACK};
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -23,7 +23,7 @@ elif CROSS_TOOL == 'keil':
|
||||
EXEC_PATH = r'C:/Keil_v5'
|
||||
elif CROSS_TOOL == 'iar':
|
||||
PLATFORM = 'iar'
|
||||
EXEC_PATH = r'D:/1_software/Iar'
|
||||
EXEC_PATH = r'C:/Program Files (x86)/IAR Systems/Embedded Workbench 8.0'
|
||||
|
||||
if os.getenv('RTT_EXEC_PATH'):
|
||||
EXEC_PATH = os.getenv('RTT_EXEC_PATH')
|
||||
@@ -141,3 +141,10 @@ elif PLATFORM == 'iar':
|
||||
|
||||
EXEC_PATH = EXEC_PATH + '/arm/bin/'
|
||||
POST_ACTION = 'ielftool --bin $TARGET rtthread.bin'
|
||||
|
||||
def dist_handle(BSP_ROOT, dist_dir):
|
||||
import sys
|
||||
cwd_path = os.getcwd()
|
||||
sys.path.append(os.path.join(os.path.dirname(BSP_ROOT), 'tools'))
|
||||
from sdk_dist import dist_do_building
|
||||
dist_do_building(BSP_ROOT, dist_dir)
|
||||
|
||||
Reference in New Issue
Block a user