1
0

SConscript 996 B

1234567891011121314151617181920212223242526272829
  1. import rtconfig
  2. from building import *
  3. Import('SDK_LIB')
  4. cwd = GetCurrentDir()
  5. # add the general drivers.
  6. src = Glob('board.c')
  7. src += Glob('CubeMX_Config/CM7/Src/stm32h7xx_hal_msp.c')
  8. path = [cwd]
  9. path += [cwd + '/CubeMX_Config/CM7/Inc']
  10. startup_path_prefix = SDK_LIB
  11. if rtconfig.PLATFORM in ['gcc']:
  12. src += [startup_path_prefix + '/STM32H7xx_HAL/CMSIS/Device/ST/STM32H7xx/Source/Templates/gcc/startup_stm32h747xx.s']
  13. elif rtconfig.PLATFORM in ['armcc', 'armclang']:
  14. src += [startup_path_prefix + '/STM32H7xx_HAL/CMSIS/Device/ST/STM32H7xx/Source/Templates/arm/startup_stm32h747xx.s']
  15. elif rtconfig.PLATFORM in ['iccarm']:
  16. src += [startup_path_prefix + '/STM32H7xx_HAL/CMSIS/Device/ST/STM32H7xx/Source/Templates/iar/startup_stm32h747xx.s']
  17. # STM32H743xx || STM32H750xx || STM32F753xx
  18. # You can select chips from the list above
  19. CPPDEFINES = ['STM32H747xx', 'CORE_CM7']
  20. group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path, CPPDEFINES = CPPDEFINES)
  21. Return('group')