kopia lustrzana https://github.com/OpenRTX/OpenRTX
Radtel RT-890 build target
rodzic
d8e22e0b11
commit
6b9cf92d15
|
@ -0,0 +1,69 @@
|
|||
[binaries]
|
||||
c = 'arm-miosix-eabi-gcc'
|
||||
cpp = 'arm-miosix-eabi-g++'
|
||||
ld = 'arm-miosix-eabi-ld'
|
||||
ar = 'arm-miosix-eabi-ar'
|
||||
as = 'arm-miosix-eabi-as'
|
||||
size = 'arm-miosix-eabi-size'
|
||||
objdump = 'arm-miosix-eabi-objdump'
|
||||
objcopy = 'arm-miosix-eabi-objcopy'
|
||||
strip = 'arm-miosix-eabi-strip'
|
||||
gdb = 'arm-miosix-eabi-gdb'
|
||||
terminal= 'x-terminal-emulator'
|
||||
openocd = '/usr/local/bin/openocd'
|
||||
|
||||
[built-in options]
|
||||
c_args = [
|
||||
'-D_DEFAULT_SOURCE=1',
|
||||
'-ffunction-sections',
|
||||
'-fdata-sections',
|
||||
'-Wall',
|
||||
'-Werror=return-type',
|
||||
'-g',
|
||||
'-mcpu=cortex-m3', # Cortex-M3 CPU
|
||||
'-mthumb', # ARM Thumb2 ISA
|
||||
'-Os'
|
||||
]
|
||||
|
||||
cpp_args = [
|
||||
'-D_DEFAULT_SOURCE=1',
|
||||
'-ffunction-sections',
|
||||
'-fdata-sections',
|
||||
'-Wall',
|
||||
'-Werror=return-type',
|
||||
'-g',
|
||||
'-fno-exceptions',
|
||||
'-fno-rtti',
|
||||
'-D__NO_EXCEPTIONS',
|
||||
'-std=c++14',
|
||||
'-mcpu=cortex-m3', # Cortex-M3 CPU
|
||||
'-mthumb', # ARM Thumb2 ISA
|
||||
'-Os'
|
||||
]
|
||||
|
||||
c_link_args = [
|
||||
'-mcpu=cortex-m3',
|
||||
'-mthumb',
|
||||
'-ffunction-sections',
|
||||
'-fdata-sections',
|
||||
'-fno-exceptions',
|
||||
'-fno-rtti',
|
||||
'-Wl,-L../lib/miosix-kernel',
|
||||
'-Wl,--gc-sections',
|
||||
'-Wl,-Map,main.map',
|
||||
'-Wl,--warn-common',
|
||||
'-nostdlib',
|
||||
'-lstdc++',
|
||||
'-lc',
|
||||
'-lm',
|
||||
'-lgcc',
|
||||
'-latomic'
|
||||
]
|
||||
|
||||
cpp_link_args = c_link_args
|
||||
|
||||
[host_machine]
|
||||
system = 'none'
|
||||
cpu_family = 'arm'
|
||||
cpu = 'cortex-m4'
|
||||
endian = 'little'
|
|
@ -20,9 +20,17 @@ miosix_def = {'DONT_USE_CMSIS_INIT' : '',
|
|||
'_POSIX_PRIORITY_SCHEDULING': ''}
|
||||
|
||||
##
|
||||
## ARM Cortex M4
|
||||
## ARM Cortex M4 with FPU
|
||||
##
|
||||
miosix_cm4f_inc = miosix_inc + ['lib/miosix-kernel/miosix/arch/cortexM4F']
|
||||
miosix_cm4f_src = miosix_src + ['lib/miosix-kernel/miosix/arch/cortexM4F/portability.cpp',
|
||||
'lib/miosix-kernel/miosix/arch/common/core/interrupts_cortexMx.cpp']
|
||||
miosix_cm4f_def = miosix_def + {'_ARCH_CORTEXM4' : ''}
|
||||
|
||||
##
|
||||
## ARM Cortex M4 without FPU
|
||||
##
|
||||
miosix_cm4_inc = miosix_inc + ['lib/miosix-kernel/miosix/arch/cortexM4']
|
||||
miosix_cm4_src = miosix_src + ['lib/miosix-kernel/miosix/arch/cortexM4/portability.cpp',
|
||||
'lib/miosix-kernel/miosix/arch/common/core/interrupts_cortexMx.cpp']
|
||||
miosix_cm4_def = miosix_def + {'_ARCH_CORTEXM4' : ''}
|
||||
|
|
53
meson.build
53
meson.build
|
@ -252,6 +252,21 @@ mk22fn512_inc = ['platform/mcu/CMSIS/Include',
|
|||
|
||||
mk22fn512_def = {}
|
||||
|
||||
##
|
||||
## AT32F421
|
||||
##
|
||||
|
||||
at32f421_src = ['platform/mcu/AT32F421/boot/startup.cpp',
|
||||
'platform/mcu/AT32F421/boot/bsp.cpp',
|
||||
'platform/mcu/AT32F421/boot/libc_integration.cpp',
|
||||
'platform/mcu/CMSIS/Device/Artery/AT32F421/Source/system_at32f421.c']
|
||||
|
||||
at32f421_inc = ['platform/mcu/AT32F421',
|
||||
'platform/mcu/CMSIS/Include',
|
||||
'platform/mcu/CMSIS/Device/Artery/AT32F421/Include']
|
||||
|
||||
at32f421_def = {'AT32F421C8T7':''}
|
||||
|
||||
##
|
||||
## ----------------------- Platform specializations ----------------------------
|
||||
##
|
||||
|
@ -426,6 +441,18 @@ mod17_src += openrtx_src + stm32f405_src + miosix_cm4f_src + ui_src_module17
|
|||
mod17_inc += openrtx_inc + stm32f405_inc + miosix_cm4f_inc
|
||||
mod17_def += openrtx_def + stm32f405_def + miosix_cm4f_def
|
||||
|
||||
##
|
||||
## Radtel RT-890
|
||||
##
|
||||
|
||||
rt890_src = ['tests/platform/boot_test.c']
|
||||
rt890_inc = []
|
||||
rt890_def = {'PLATFORM_RT890': ''}
|
||||
|
||||
rt890_src += at32f421_src + miosix_cm4_src
|
||||
rt890_inc += openrtx_inc + at32f421_inc + miosix_cm4_inc
|
||||
rt890_def += openrtx_def + at32f421_def + miosix_cm4_def
|
||||
|
||||
##
|
||||
## -------------------------- Compilation arguments ----------------------------
|
||||
##
|
||||
|
@ -521,6 +548,15 @@ foreach k, v : mod17_def
|
|||
endif
|
||||
endforeach
|
||||
|
||||
rt890_args = []
|
||||
foreach k, v : rt890_def
|
||||
if v == ''
|
||||
rt890_args += '-D@0@'.format(k)
|
||||
else
|
||||
rt890_args += '-D@0@=@1@'.format(k, v)
|
||||
endif
|
||||
endforeach
|
||||
|
||||
linux_opts = {
|
||||
'sources' : linux_default_src,
|
||||
'include_directories': linux_inc,
|
||||
|
@ -608,6 +644,16 @@ mod17_opts = {
|
|||
'-Wl,--print-memory-usage'],
|
||||
}
|
||||
|
||||
rt890_opts = {
|
||||
'sources' : rt890_src,
|
||||
'include_directories': rt890_inc,
|
||||
'dependencies' : [],
|
||||
'c_args' : rt890_args,
|
||||
'cpp_args' : rt890_args,
|
||||
'link_args' : ['-Wl,-T../platform/mcu/AT32F421/linker_script.ld',
|
||||
'-Wl,--print-memory-usage'],
|
||||
}
|
||||
|
||||
ttwrplus_opts = {
|
||||
'sources' : ['CMakeLists.txt'],
|
||||
'include_directories': [],
|
||||
|
@ -679,6 +725,13 @@ targets = [
|
|||
'wrap' : ' ',
|
||||
'load_addr': ' '
|
||||
},
|
||||
{
|
||||
'name' : 'rt890',
|
||||
'opts' : rt890_opts,
|
||||
'flashable': true,
|
||||
'wrap' : ' ',
|
||||
'load_addr': ' '
|
||||
},
|
||||
{
|
||||
'name' : 'ttwrplus',
|
||||
'opts' : ttwrplus_opts,
|
||||
|
|
Ładowanie…
Reference in New Issue