From 249c3d471c0d9faf69422a4be012476d3d091502 Mon Sep 17 00:00:00 2001 From: tanek liang Date: Wed, 15 Nov 2017 19:55:16 +0800 Subject: [PATCH] [bsp] enable RT_USING_MODULE --- bsp/lpc54608-LPCXpresso/.config | 30 ++++++++---------- .../applications/application.c | 2 ++ bsp/lpc54608-LPCXpresso/rtconfig.h | 31 ++++++++----------- bsp/lpc54608-LPCXpresso/rtconfig.py | 2 +- 4 files changed, 29 insertions(+), 36 deletions(-) diff --git a/bsp/lpc54608-LPCXpresso/.config b/bsp/lpc54608-LPCXpresso/.config index 3a1873462f..32a3443c99 100644 --- a/bsp/lpc54608-LPCXpresso/.config +++ b/bsp/lpc54608-LPCXpresso/.config @@ -8,6 +8,9 @@ # CONFIG_RT_NAME_MAX=8 CONFIG_RT_ALIGN_SIZE=4 +# CONFIG_RT_THREAD_PRIORITY_8 is not set +CONFIG_RT_THREAD_PRIORITY_32=y +# CONFIG_RT_THREAD_PRIORITY_256 is not set CONFIG_RT_THREAD_PRIORITY_MAX=32 CONFIG_RT_TICK_PER_SECOND=1000 CONFIG_RT_DEBUG=y @@ -35,9 +38,11 @@ CONFIG_RT_USING_MESSAGEQUEUE=y # CONFIG_RT_USING_MEMPOOL=y CONFIG_RT_USING_MEMHEAP=y -CONFIG_RT_USING_HEAP=y +# CONFIG_RT_USING_NOHEAP is not set CONFIG_RT_USING_SMALL_MEM=y # CONFIG_RT_USING_SLAB is not set +# CONFIG_RT_USING_MEMHEAP_AS_HEAP is not set +CONFIG_RT_USING_HEAP=y # # Kernel Device Object @@ -47,7 +52,7 @@ CONFIG_RT_USING_DEVICE=y CONFIG_RT_USING_CONSOLE=y CONFIG_RT_CONSOLEBUF_SIZE=128 CONFIG_RT_CONSOLE_DEVICE_NAME="uart0" -# CONFIG_RT_USING_MODULE is not set +CONFIG_RT_USING_MODULE=y # # RT-Thread Components @@ -58,7 +63,7 @@ CONFIG_RT_USING_COMPONENTS_INIT=y # # C++ features # -# CONFIG_RT_USING_CPLUSPLUS is not set +CONFIG_RT_USING_CPLUSPLUS=y # # Command shell @@ -146,8 +151,8 @@ CONFIG_RT_USING_PTHREADS=y # light weight TCP/IP stack # CONFIG_RT_USING_LWIP=y -CONFIG_RT_USING_LWIP141=y -# CONFIG_RT_USING_LWIP202 is not set +# CONFIG_RT_USING_LWIP141 is not set +CONFIG_RT_USING_LWIP202=y # CONFIG_RT_LWIP_IGMP is not set CONFIG_RT_LWIP_ICMP=y # CONFIG_RT_LWIP_SNMP is not set @@ -218,22 +223,15 @@ CONFIG_LWIP_SO_RCVBUF=1 # # IoT - internet of things # +# CONFIG_PKG_USING_CJSON is not set # CONFIG_PKG_USING_PAHOMQTT is not set # CONFIG_PKG_USING_WEBCLIENT is not set # CONFIG_PKG_USING_MONGOOSE is not set -# CONFIG_PKG_USING_WEBTERMINAL is not set -# CONFIG_PKG_USING_CJSON is not set -# CONFIG_PKG_USING_EZXML is not set - -# -# Marvell WiFi -# -# CONFIG_PKG_USING_MARVELLWIFI is not set +# CONFIG_PKG_USING_WEB_TERMINAL is not set # # security packages # -# CONFIG_PKG_USING_MBEDTLS is not set # # language packages @@ -243,14 +241,12 @@ CONFIG_LWIP_SO_RCVBUF=1 # # multimedia packages # -# CONFIG_PKG_USING_FASTLZ is not set # # tools packages # # CONFIG_PKG_USING_CMBACKTRACE is not set -# CONFIG_PKG_USING_EASYLOGGER is not set -# CONFIG_PKG_USING_SYSTEMVIEW is not set +# CONFIG_PKG_USING_ELOG is not set # # miscellaneous packages diff --git a/bsp/lpc54608-LPCXpresso/applications/application.c b/bsp/lpc54608-LPCXpresso/applications/application.c index 84a475c6e3..c282a290e9 100644 --- a/bsp/lpc54608-LPCXpresso/applications/application.c +++ b/bsp/lpc54608-LPCXpresso/applications/application.c @@ -53,6 +53,7 @@ void build_dump(void) void link_dump(void) { +#ifdef __GNUC__ extern unsigned int _sdata; extern unsigned int _edata; extern unsigned int _sidata; @@ -68,6 +69,7 @@ void link_dump(void) DUMP_VAR(_sidata); DUMP_VAR(_sbss); DUMP_VAR(_ebss); +#endif } int rt_application_init(void) diff --git a/bsp/lpc54608-LPCXpresso/rtconfig.h b/bsp/lpc54608-LPCXpresso/rtconfig.h index a8e050891b..0be2c4e347 100644 --- a/bsp/lpc54608-LPCXpresso/rtconfig.h +++ b/bsp/lpc54608-LPCXpresso/rtconfig.h @@ -8,6 +8,9 @@ #define RT_NAME_MAX 8 #define RT_ALIGN_SIZE 4 +/* RT_THREAD_PRIORITY_8 is not set */ +#define RT_THREAD_PRIORITY_32 +/* RT_THREAD_PRIORITY_256 is not set */ #define RT_THREAD_PRIORITY_MAX 32 #define RT_TICK_PER_SECOND 1000 #define RT_DEBUG @@ -33,9 +36,11 @@ #define RT_USING_MEMPOOL #define RT_USING_MEMHEAP -#define RT_USING_HEAP +/* RT_USING_NOHEAP is not set */ #define RT_USING_SMALL_MEM /* RT_USING_SLAB is not set */ +/* RT_USING_MEMHEAP_AS_HEAP is not set */ +#define RT_USING_HEAP /* Kernel Device Object */ @@ -44,7 +49,7 @@ #define RT_USING_CONSOLE #define RT_CONSOLEBUF_SIZE 128 #define RT_CONSOLE_DEVICE_NAME "uart0" -/* RT_USING_MODULE is not set */ +#define RT_USING_MODULE /* RT-Thread Components */ @@ -53,7 +58,7 @@ /* C++ features */ -/* RT_USING_CPLUSPLUS is not set */ +#define RT_USING_CPLUSPLUS /* Command shell */ @@ -133,8 +138,8 @@ /* light weight TCP/IP stack */ #define RT_USING_LWIP -#define RT_USING_LWIP141 -/* RT_USING_LWIP202 is not set */ +/* RT_USING_LWIP141 is not set */ +#define RT_USING_LWIP202 /* RT_LWIP_IGMP is not set */ #define RT_LWIP_ICMP /* RT_LWIP_SNMP is not set */ @@ -197,34 +202,24 @@ /* IoT - internet of things */ +/* PKG_USING_CJSON is not set */ /* PKG_USING_PAHOMQTT is not set */ /* PKG_USING_WEBCLIENT is not set */ /* PKG_USING_MONGOOSE is not set */ -/* PKG_USING_WEBTERMINAL is not set */ -/* PKG_USING_CJSON is not set */ -/* PKG_USING_EZXML is not set */ - -/* Marvell WiFi */ - -/* PKG_USING_MARVELLWIFI is not set */ +/* PKG_USING_WEB_TERMINAL is not set */ /* security packages */ -/* PKG_USING_MBEDTLS is not set */ - /* language packages */ /* PKG_USING_JERRYSCRIPT is not set */ /* multimedia packages */ -/* PKG_USING_FASTLZ is not set */ - /* tools packages */ /* PKG_USING_CMBACKTRACE is not set */ -/* PKG_USING_EASYLOGGER is not set */ -/* PKG_USING_SYSTEMVIEW is not set */ +/* PKG_USING_ELOG is not set */ /* miscellaneous packages */ diff --git a/bsp/lpc54608-LPCXpresso/rtconfig.py b/bsp/lpc54608-LPCXpresso/rtconfig.py index 20b049babb..2a89817b84 100644 --- a/bsp/lpc54608-LPCXpresso/rtconfig.py +++ b/bsp/lpc54608-LPCXpresso/rtconfig.py @@ -40,7 +40,7 @@ if PLATFORM == 'gcc': OBJCPY = PREFIX + 'objcopy' DEVICE = ' -mcpu=cortex-m4 -mthumb -ffunction-sections -fdata-sections -mfpu=fpv4-sp-d16 -mfloat-abi=hard' - CFLAGS = DEVICE + ' -g -Wall -std=c99' + CFLAGS = DEVICE + ' -g -Wall' AFLAGS = ' -c' + DEVICE + ' -x assembler-with-cpp -Wa,-mimplicit-it=thumb ' LFLAGS = DEVICE + ' -lm -lgcc -lc' + ' -nostartfiles -Wl,--gc-sections,-Map=rtthread.map,-cref,-u,ResetISR -T link.lds' -- GitLab