1
0

SConscript 953 B

123456789101112131415161718192021222324252627282930313233
  1. import os
  2. import rtconfig
  3. from building import *
  4. Import('SDK_LIB')
  5. cwd = GetCurrentDir()
  6. # add general drivers
  7. src = Split('''
  8. board.c
  9. CubeMX_Config/Src/stm32wbxx_hal_msp.c
  10. ''')
  11. path = [cwd]
  12. path += [cwd + '/CubeMX_Config/Inc']
  13. path += [cwd + '/ports']
  14. startup_path_prefix = SDK_LIB
  15. if rtconfig.CROSS_TOOL == 'gcc':
  16. src += [startup_path_prefix + '/STM32WBxx_HAL/CMSIS/Device/ST/STM32WBxx/Source/Templates/gcc/startup_stm32wb55xx_cm4.s']
  17. elif rtconfig.CROSS_TOOL == 'keil':
  18. src += [startup_path_prefix + '/STM32WBxx_HAL/CMSIS/Device/ST/STM32WBxx/Source/Templates/arm/startup_stm32wb55xx_cm4.s']
  19. elif rtconfig.CROSS_TOOL == 'iar':
  20. src += [startup_path_prefix + '/STM32WBxx_HAL/CMSIS/Device/ST/STM32WBxx/Source/Templates/iar/startup_stm32wb55xx_cm4.s']
  21. # You can select chips from the list above
  22. CPPDEFINES = ['STM32WB55xx']
  23. group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path, CPPDEFINES = CPPDEFINES)
  24. Return('group')