2010-11-20 20:31:00 +08:00
|
|
|
import rtconfig
|
2010-04-19 06:16:50 +08:00
|
|
|
Import('RTT_ROOT')
|
2010-11-20 20:31:00 +08:00
|
|
|
from building import *
|
2010-04-19 06:16:50 +08:00
|
|
|
|
2011-06-15 23:21:44 +08:00
|
|
|
src_bsp = ['application.c', 'startup.c', 'board.c', 'stm32f10x_it.c']
|
|
|
|
src_drv = ['rtc.c', 'usart.c', 'serial.c', 'led.c']
|
2010-04-19 06:16:50 +08:00
|
|
|
|
2010-11-20 20:31:00 +08:00
|
|
|
if GetDepend('RT_USING_DFS'):
|
2010-04-19 06:16:50 +08:00
|
|
|
if rtconfig.STM32_TYPE == 'STM32F10X_HD':
|
|
|
|
src_drv += ['sdcard.c']
|
|
|
|
else:
|
|
|
|
src_drv += ['msd.c']
|
|
|
|
|
2010-11-20 20:31:00 +08:00
|
|
|
if GetDepend('RT_USING_LWIP'):
|
2010-04-19 06:16:50 +08:00
|
|
|
if rtconfig.STM32_TYPE == 'STM32F10X_CL':
|
|
|
|
src_drv += ['stm32_eth.c']
|
|
|
|
else:
|
2011-06-23 23:24:10 +08:00
|
|
|
src_drv += ['enc28j60.c'] + ['dm9000a.c']
|
2010-04-19 06:16:50 +08:00
|
|
|
|
2010-11-20 20:31:00 +08:00
|
|
|
src = src_bsp + src_drv
|
2011-06-15 23:21:44 +08:00
|
|
|
CPPPATH = [RTT_ROOT + '/bsp/stm32f10x']
|
|
|
|
CPPDEFINES = []
|
2010-11-20 20:31:00 +08:00
|
|
|
group = DefineGroup('Startup', src, depend = [''], CPPPATH = CPPPATH, CPPDEFINES = CPPDEFINES)
|
2010-04-19 06:16:50 +08:00
|
|
|
|
2010-11-20 20:31:00 +08:00
|
|
|
Return('group')
|