You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
2.7 KiB

  1. ifneq ($(findstring STM32F303, $(MCU)),)
  2. ## chip/board settings
  3. # - the next two should match the directories in
  4. # <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
  5. MCU_FAMILY ?= STM32
  6. MCU_SERIES ?= STM32F3xx
  7. # Linker script to use
  8. # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
  9. # or <this_dir>/ld/
  10. MCU_LDSCRIPT ?= STM32F303xC
  11. # Startup code to use
  12. # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/
  13. MCU_STARTUP ?= stm32f3xx
  14. # Board: it should exist either in <chibios>/os/hal/boards/
  15. # or <this_dir>/boards
  16. BOARD ?= GENERIC_STM32_F303XC
  17. # Cortex version
  18. MCU = cortex-m4
  19. # ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
  20. ARMV ?= 7
  21. USE_FPU = yes
  22. # Vector table for application
  23. # 0x00000000-0x00001000 area is occupied by bootlaoder.*/
  24. # The CORTEX_VTOR... is needed only for MCHCK/Infinity KB
  25. # OPT_DEFS = -DCORTEX_VTOR_INIT=0x08005000
  26. # Options to pass to dfu-util when flashing
  27. DFU_ARGS ?= -d 0483:df11 -a 0 -s 0x08000000:leave
  28. DFU_SUFFIX_ARGS = -p DF11 -v 0483
  29. endif
  30. ifneq (,$(filter $(MCU),atmega32u4 at90usb1286))
  31. # Processor frequency.
  32. # This will define a symbol, F_CPU, in all source code files equal to the
  33. # processor frequency in Hz. You can then use this symbol in your source code to
  34. # calculate timings. Do NOT tack on a 'UL' at the end, this will be done
  35. # automatically to create a 32-bit value in your source code.
  36. #
  37. # This will be an integer division of F_USB below, as it is sourced by
  38. # F_USB after it has run through any CPU prescalers. Note that this value
  39. # does not *change* the processor frequency - it should merely be updated to
  40. # reflect the processor speed set externally so that the code can use accurate
  41. # software delays.
  42. F_CPU ?= 16000000
  43. # LUFA specific
  44. #
  45. # Target architecture (see library "Board Types" documentation).
  46. ARCH ?= AVR8
  47. # Input clock frequency.
  48. # This will define a symbol, F_USB, in all source code files equal to the
  49. # input clock frequency (before any prescaling is performed) in Hz. This value may
  50. # differ from F_CPU if prescaling is used on the latter, and is required as the
  51. # raw input clock is fed directly to the PLL sections of the AVR for high speed
  52. # clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
  53. # at the end, this will be done automatically to create a 32-bit value in your
  54. # source code.
  55. #
  56. # If no clock division is performed on the input clock inside the AVR (via the
  57. # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
  58. F_USB ?= $(F_CPU)
  59. endif