diff options
| author | Bernard Xiong <[email protected]> | 2018-12-04 19:18:02 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2018-12-04 19:18:02 +0800 |
| commit | da56076b510800db2a3cd3b02b24c691f6840870 (patch) | |
| tree | 12418d14395ce01971d2ad417f80dba3fc173dc4 | |
| parent | 96c0a42f51bb9cb4ea2d8813db52ead15a814d81 (diff) | |
| parent | a3b4e7852779892a5703fb494a2abf3ee2186e5e (diff) | |
Merge pull request #2028 from aozima/bsp_dev
修复一系列BSP编译错误
| -rw-r--r-- | bsp/CME_M7/rtconfig.h | 10 | ||||
| -rw-r--r-- | bsp/CME_M7/rtconfig.py | 15 | ||||
| -rw-r--r-- | bsp/apollo2/rtconfig.py | 12 | ||||
| -rw-r--r-- | bsp/frdm-k64f/MK64F.sct | 2 | ||||
| -rw-r--r-- | bsp/frdm-k64f/rtconfig.py | 9 | ||||
| -rw-r--r-- | bsp/lpc176x/SConstruct | 1 | ||||
| -rw-r--r-- | bsp/mb9bf500r/rtconfig.py | 6 | ||||
| -rw-r--r-- | bsp/mini4020/rtconfig.h | 1 | ||||
| -rw-r--r-- | bsp/nv32f100x/rtconfig.py | 8 | ||||
| -rw-r--r-- | bsp/rm48x50/rtconfig.py | 4 | ||||
| -rw-r--r-- | bsp/samd21/rtconfig.py | 4 | ||||
| -rw-r--r-- | bsp/samd21/sam_d2x_asflib/SConscript | 14 | ||||
| -rw-r--r-- | bsp/stm32f107/drivers/stm32_eth.c | 4 | ||||
| -rw-r--r-- | bsp/stm32f40x/drivers/stm32f4xx_eth.c | 4 | ||||
| -rw-r--r-- | bsp/stm32f429-disco/drivers/drv_lcd.c | 4 | ||||
| -rw-r--r-- | bsp/stm32f429-disco/drivers/drv_touch.c | 5 |
16 files changed, 64 insertions, 39 deletions
diff --git a/bsp/CME_M7/rtconfig.h b/bsp/CME_M7/rtconfig.h index d0e44c8d28..f981ad9a91 100644 --- a/bsp/CME_M7/rtconfig.h +++ b/bsp/CME_M7/rtconfig.h @@ -100,8 +100,14 @@ /* Enable DHCP */ // #define RT_LWIP_DHCP -/* the number of simulatenously active TCP connections*/ -#define RT_LWIP_TCP_PCB_NUM 3 +#define RT_MEMP_NUM_NETCONN 12 +#define RT_LWIP_PBUF_NUM 3 +#define RT_LWIP_RAW_PCB_NUM 2 +#define RT_LWIP_UDP_PCB_NUM 4 +#define RT_LWIP_TCP_PCB_NUM 8 +#define RT_LWIP_TCP_SEG_NUM 40 +#define RT_LWIP_TCP_SND_BUF 4380 +#define RT_LWIP_TCP_WND 4380 /* ip address of target */ #define RT_LWIP_IPADDR "192.168.1.30" diff --git a/bsp/CME_M7/rtconfig.py b/bsp/CME_M7/rtconfig.py index 134ef61559..650d4bb7f8 100644 --- a/bsp/CME_M7/rtconfig.py +++ b/bsp/CME_M7/rtconfig.py @@ -15,8 +15,10 @@ elif CROSS_TOOL == 'keil': PLATFORM = 'armcc' EXEC_PATH = 'C:/Keil' elif CROSS_TOOL == 'iar': - PLATFORM = 'iar' - EXEC_PATH = 'C:/Program Files/IAR Systems/Embedded Workbench 6.0 Evaluation' + print('================ERROR============================') + print('Not support iar yet!') + print('=================================================') + exit(0) if os.getenv('RTT_EXEC_PATH'): EXEC_PATH = os.getenv('RTT_EXEC_PATH') @@ -64,15 +66,14 @@ elif PLATFORM == 'armcc': LINK = 'armlink' TARGET_EXT = 'axf' - DEVICE = ' --cortex-m3' + DEVICE = ' --cpu Cortex-M3' CFLAGS = DEVICE + ' --c99 --apcs=interwork' AFLAGS = DEVICE - LFLAGS = DEVICE + ' --info sizes --info totals --info unused --info veneers --list rtthread.map --scatter nuc472_flash.sct' + LFLAGS = DEVICE + ' --info sizes --info totals --info unused --info veneers --list rtthread.map --scatter CME_M7.sct' - CFLAGS += ' -I' + EXEC_PATH + '/ARM/RV31/INC' - LFLAGS += ' --libpath ' + EXEC_PATH + '/ARM/RV31/LIB' + LFLAGS += ' --keep *.o(.rti_fn.*) --keep *.o(FSymTab) --keep *.o(VSymTab)' - EXEC_PATH += '/arm/bin40/' + EXEC_PATH += '/ARM/ARMCC/bin' if BUILD == 'debug': CFLAGS += ' -g -O0' diff --git a/bsp/apollo2/rtconfig.py b/bsp/apollo2/rtconfig.py index 506ee78eca..7998909109 100644 --- a/bsp/apollo2/rtconfig.py +++ b/bsp/apollo2/rtconfig.py @@ -64,16 +64,14 @@ elif PLATFORM == 'armcc': LINK = 'armlink' TARGET_EXT = 'axf' - DEVICE = ' --device DARMSTM' - CFLAGS = DEVICE + ' --apcs=interwork' + DEVICE = ' --cpu Cortex-M4' + CFLAGS = DEVICE + ' --c99 --apcs=interwork' AFLAGS = DEVICE - LFLAGS = DEVICE + ' --info sizes --info totals --info unused --info veneers --list rtthread-apollo2.map --scatter rtthread-apollo2.sct' + LFLAGS = DEVICE + ' --info sizes --info totals --info unused --info veneers --list rtthread-apollo2.map --scatter rtthread.sct' - CFLAGS += ' --c99' - CFLAGS += ' -I' + EXEC_PATH + '/ARM/RV31/INC' - LFLAGS += ' --libpath ' + EXEC_PATH + '/ARM/RV31/LIB' + LFLAGS += ' --keep *.o(.rti_fn.*) --keep *.o(FSymTab) --keep *.o(VSymTab)' - EXEC_PATH += '/arm/bin40/' + EXEC_PATH += '/ARM/ARMCC/bin' if BUILD == 'debug': CFLAGS += ' -g -O0' diff --git a/bsp/frdm-k64f/MK64F.sct b/bsp/frdm-k64f/MK64F.sct index 1aafaed200..4c91774b2d 100644 --- a/bsp/frdm-k64f/MK64F.sct +++ b/bsp/frdm-k64f/MK64F.sct @@ -7,7 +7,7 @@ LR_IROM1 0x00000000 0x100000 { ; load region size_region (1000k) } ; 8_byte_aligned(62 vect * 4 bytes) = 8_byte_aligned(0x194) = 0x198 ; 0x40000 - 0x198 = 0x3FE68 - RW_IRAM1 0x1FFF0198 0x3FE68 { + RW_IRAM2 0x20000000 0x30000 { .ANY (+RW +ZI) } } diff --git a/bsp/frdm-k64f/rtconfig.py b/bsp/frdm-k64f/rtconfig.py index 1f4d8d246e..e92c9b15e6 100644 --- a/bsp/frdm-k64f/rtconfig.py +++ b/bsp/frdm-k64f/rtconfig.py @@ -64,17 +64,16 @@ elif PLATFORM == 'armcc': TARGET_EXT = 'axf' DEVICE = ' --cpu Cortex-M4.fp ' - CFLAGS = DEVICE + ' --apcs=interwork' + CFLAGS = DEVICE + ' --c99 --apcs=interwork' AFLAGS = DEVICE LFLAGS = DEVICE + ' --info sizes --info totals --info unused --info veneers --list rtthread-k64f.map --scatter MK64F.sct' - CFLAGS += ' -I' + EXEC_PATH + '/ARM/RV31/INC' - LFLAGS += ' --libpath ' + EXEC_PATH + '/ARM/RV31/LIB' + LFLAGS += ' --keep *.o(.rti_fn.*) --keep *.o(FSymTab) --keep *.o(VSymTab)' - EXEC_PATH += '/arm/bin40/' + EXEC_PATH += '/ARM/ARMCC/bin' if BUILD == 'debug': - CFLAGS += ' --c99 -g -O0' + CFLAGS += ' -g -O0' AFLAGS += ' -g' else: CFLAGS += ' -O2' diff --git a/bsp/lpc176x/SConstruct b/bsp/lpc176x/SConstruct index 681e6469c4..4afcf96602 100644 --- a/bsp/lpc176x/SConstruct +++ b/bsp/lpc176x/SConstruct @@ -14,7 +14,6 @@ TARGET = 'rtthread-lpc17xx.' + rtconfig.TARGET_EXT env = Environment(tools = ['mingw'], AS = rtconfig.AS, ASFLAGS = rtconfig.AFLAGS, CC = rtconfig.CC, CCFLAGS = rtconfig.CFLAGS, - CXX = rtconfig.CXX, CXXFLAGS = rtconfig.CXXFLAGS, AR = rtconfig.AR, ARFLAGS = '-rc', LINK = rtconfig.LINK, LINKFLAGS = rtconfig.LFLAGS) diff --git a/bsp/mb9bf500r/rtconfig.py b/bsp/mb9bf500r/rtconfig.py index 8b325ab1fc..24ae26d0ab 100644 --- a/bsp/mb9bf500r/rtconfig.py +++ b/bsp/mb9bf500r/rtconfig.py @@ -18,8 +18,10 @@ elif CROSS_TOOL == 'keil': PLATFORM = 'armcc' EXEC_PATH = 'C:/Keil' elif CROSS_TOOL == 'iar': - PLATFORM = 'iar' - EXEC_PATH = 'C:/Program Files/IAR Systems/Embedded Workbench 6.0 Evaluation' + print('================ERROR============================') + print('Not support iar yet!') + print('=================================================') + exit(0) if os.getenv('RTT_EXEC_PATH'): EXEC_PATH = os.getenv('RTT_EXEC_PATH') diff --git a/bsp/mini4020/rtconfig.h b/bsp/mini4020/rtconfig.h index 9385fe0056..bef31bc1a7 100644 --- a/bsp/mini4020/rtconfig.h +++ b/bsp/mini4020/rtconfig.h @@ -63,6 +63,7 @@ /* SECTION: Device System */ /* Using Device System */ #define RT_USING_DEVICE +#define RT_USING_DEVICE_IPC /* SECTION: Console options */ /* the buffer size of console */ diff --git a/bsp/nv32f100x/rtconfig.py b/bsp/nv32f100x/rtconfig.py index b2c7d0fdc6..7e1e24facd 100644 --- a/bsp/nv32f100x/rtconfig.py +++ b/bsp/nv32f100x/rtconfig.py @@ -11,11 +11,13 @@ if os.getenv('RTT_CC'): # cross_tool provides the cross compiler # EXEC_PATH is the compiler execute path, for example, CodeSourcery, Keil MDK, IAR if CROSS_TOOL == 'gcc': - PLATFORM = 'gcc' - EXEC_PATH = 'G:/iot/camera_studio-win32-20160903/camera_studio/tools/arm-2014.05/bin' + print('================ERROR============================') + print('Not support gcc yet!') + print('=================================================') + exit(0) elif CROSS_TOOL == 'keil': print('================ERROR============================') - print('Not support iar yet!') + print('Not support keil yet!') print('=================================================') exit(0) elif CROSS_TOOL == 'iar': diff --git a/bsp/rm48x50/rtconfig.py b/bsp/rm48x50/rtconfig.py index e0899cf38e..0c11dc8d59 100644 --- a/bsp/rm48x50/rtconfig.py +++ b/bsp/rm48x50/rtconfig.py @@ -14,6 +14,10 @@ if CROSS_TOOL == 'gcc': elif CROSS_TOOL == 'keil': PLATFORM = 'armcc' EXEC_PATH = 'C:/Keil' + print('================ERROR============================') + print('Not support keil yet!') + print('=================================================') + exit(0) elif CROSS_TOOL == 'iar': print('================ERROR============================') print('Not support IAR yet!') diff --git a/bsp/samd21/rtconfig.py b/bsp/samd21/rtconfig.py index 2f2460e77b..ce47aec5f0 100644 --- a/bsp/samd21/rtconfig.py +++ b/bsp/samd21/rtconfig.py @@ -18,6 +18,10 @@ DEVICE_TYPE = '__SAMD21J18A__' if CROSS_TOOL == 'gcc': PLATFORM = 'gcc' EXEC_PATH = 'C:/Program Files/CodeSourcery/Sourcery_CodeBench_Lite_for_ARM_EABI/bin' + print('================ERROR============================') + print('Not support gcc yet!') + print('=================================================') + exit(0) elif CROSS_TOOL == 'keil': PLATFORM = 'armcc' EXEC_PATH = 'C:/Keil' diff --git a/bsp/samd21/sam_d2x_asflib/SConscript b/bsp/samd21/sam_d2x_asflib/SConscript index 7561fea0fe..d50a1213a9 100644 --- a/bsp/samd21/sam_d2x_asflib/SConscript +++ b/bsp/samd21/sam_d2x_asflib/SConscript @@ -31,13 +31,19 @@ if rtconfig.DEVICE_SERIES == 'SAMD20': path += [cwd + '/sam0/', cwd + '/sam0/utils/cmsis/samd20/include/'] path += [cwd + '/sam0/utils/cmsis/samd20/source/'] src += Glob('./sam0/utils/cmsis/samd20/source/*.c') - src += Glob('./sam0/utils/cmsis/samd20/source/arm/*.s') + if rtconfig.CROSS_TOOL == 'gcc': + src += Glob('./sam0/utils/cmsis/samd20/source/gcc/*.s') + elif rtconfig.CROSS_TOOL == 'keil': + src += Glob('./sam0/utils/cmsis/samd20/source/arm/*.s') elif rtconfig.DEVICE_SERIES == 'SAMD21': #D21 path += [cwd + '/sam0/utils/cmsis/samd21/include/'] path += [cwd + '/sam0/utils/cmsis/samd21/source/'] src += Glob('./sam0/utils/cmsis/samd21/source/*.c') - src += Glob('./sam0/utils/cmsis/samd21/source/arm/*.s') + if rtconfig.CROSS_TOOL == 'gcc': + src += Glob('./sam0/utils/cmsis/samd21/source/gcc/*.s') + elif rtconfig.CROSS_TOOL == 'keil': + src += Glob('./sam0/utils/cmsis/samd21/source/arm/*.s') #sam0/drivers/system path += [cwd + '/sam0/drivers/system/'] @@ -68,8 +74,8 @@ elif rtconfig.DEVICE_SERIES == 'SAMD21': path += [cwd + '/sam0/drivers/sercom', cwd + '/sam0/drivers/sercom/usart'] src += Glob('./sam0/drivers/sercom/*.c') src += Glob('./sam0/drivers/sercom/usart/*.c') -SrcRemove(src, 'sercom_interrupt.c') -SrcRemove(src, 'usart_interrupt.c') +SrcRemove(src, './sam0/drivers/sercom/sercom_interrupt.c') +SrcRemove(src, './sam0/drivers/sercom/usart/usart_interrupt.c') CPPDEFINES += ['USART_CALLBACK_MODE=false'] #sam0/drivers/port diff --git a/bsp/stm32f107/drivers/stm32_eth.c b/bsp/stm32f107/drivers/stm32_eth.c index bd7317090f..e4efba161b 100644 --- a/bsp/stm32f107/drivers/stm32_eth.c +++ b/bsp/stm32f107/drivers/stm32_eth.c @@ -3141,7 +3141,7 @@ static void register_multicast_address(struct rt_stm32_eth *stm32_eth, const uin #endif /* (LWIP_IPV4 && LWIP_IGMP) || (LWIP_IPV6 && LWIP_IPV6_MLD) */ #if LWIP_IPV4 && LWIP_IGMP -static err_t igmp_mac_filter( struct netif *netif, const ip4_addr_t *ip4_addr, u8_t action ) +static err_t igmp_mac_filter( struct netif *netif, const ip4_addr_t *ip4_addr, enum netif_mac_filter_action action ) { uint8_t mac[6]; const uint8_t *p = (const uint8_t *)ip4_addr; @@ -3167,7 +3167,7 @@ static err_t igmp_mac_filter( struct netif *netif, const ip4_addr_t *ip4_addr, u #endif /* LWIP_IPV4 && LWIP_IGMP */ #if LWIP_IPV6 && LWIP_IPV6_MLD -static err_t mld_mac_filter( struct netif *netif, const ip6_addr_t *ip6_addr, u8_t action ) +static err_t mld_mac_filter( struct netif *netif, const ip6_addr_t *ip6_addr, enum netif_mac_filter_action action ) { uint8_t mac[6]; const uint8_t *p = (const uint8_t *)&ip6_addr->addr[3]; diff --git a/bsp/stm32f40x/drivers/stm32f4xx_eth.c b/bsp/stm32f40x/drivers/stm32f4xx_eth.c index 0ae4c19b97..8db924875b 100644 --- a/bsp/stm32f40x/drivers/stm32f4xx_eth.c +++ b/bsp/stm32f40x/drivers/stm32f4xx_eth.c @@ -3467,7 +3467,7 @@ static void register_multicast_address(struct rt_stm32_eth *stm32_eth, const uin #endif /* (LWIP_IPV4 && LWIP_IGMP) || (LWIP_IPV6 && LWIP_IPV6_MLD) */ #if LWIP_IPV4 && LWIP_IGMP -static err_t igmp_mac_filter( struct netif *netif, const ip4_addr_t *ip4_addr, u8_t action ) +static err_t igmp_mac_filter( struct netif *netif, const ip4_addr_t *ip4_addr, enum netif_mac_filter_action action ) { uint8_t mac[6]; const uint8_t *p = (const uint8_t *)ip4_addr; @@ -3493,7 +3493,7 @@ static err_t igmp_mac_filter( struct netif *netif, const ip4_addr_t *ip4_addr, u #endif /* LWIP_IPV4 && LWIP_IGMP */ #if LWIP_IPV6 && LWIP_IPV6_MLD -static err_t mld_mac_filter( struct netif *netif, const ip6_addr_t *ip6_addr, u8_t action ) +static err_t mld_mac_filter( struct netif *netif, const ip6_addr_t *ip6_addr, enum netif_mac_filter_action action ) { uint8_t mac[6]; const uint8_t *p = (const uint8_t *)&ip6_addr->addr[3]; diff --git a/bsp/stm32f429-disco/drivers/drv_lcd.c b/bsp/stm32f429-disco/drivers/drv_lcd.c index 6612f60928..0b14234f8a 100644 --- a/bsp/stm32f429-disco/drivers/drv_lcd.c +++ b/bsp/stm32f429-disco/drivers/drv_lcd.c @@ -919,8 +919,6 @@ FINSH_FUNCTION_EXPORT(lcd_blit_line, draw blit line in lcd display); static int rt_hw_lcd_init(void) { - _lcd_low_level_init(); - static struct rt_device lcd_device; static struct rt_device_graphic_ops ili9341_ops = @@ -932,6 +930,8 @@ static int rt_hw_lcd_init(void) ili9341_lcd_blit_line }; + _lcd_low_level_init(); + /* register lcd device */ lcd_device.type = RT_Device_Class_Graphic; lcd_device.init = lcd_init; diff --git a/bsp/stm32f429-disco/drivers/drv_touch.c b/bsp/stm32f429-disco/drivers/drv_touch.c index ea60c858c5..8559b69f98 100644 --- a/bsp/stm32f429-disco/drivers/drv_touch.c +++ b/bsp/stm32f429-disco/drivers/drv_touch.c @@ -67,7 +67,10 @@ static int32_t touch_read (uint8_t reg, uint8_t *val) static int32_t touch_write(uint8_t reg, uint8_t val) { struct rt_i2c_msg msgs; - rt_uint8_t buf[2] = {reg, val}; + rt_uint8_t buf[2]; + + buf[0] = reg; + buf[1] = val; msgs.addr = TSC_I2C_ADDR; msgs.flags = RT_I2C_WR; |
