diff options
Diffstat (limited to 'quantum/mcu_selection.mk')
-rw-r--r-- | quantum/mcu_selection.mk | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/quantum/mcu_selection.mk b/quantum/mcu_selection.mk index 09e07a37f..81c467c65 100644 --- a/quantum/mcu_selection.mk +++ b/quantum/mcu_selection.mk | |||
@@ -279,6 +279,72 @@ ifneq ($(findstring STM32F411, $(MCU)),) | |||
279 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 279 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
280 | endif | 280 | endif |
281 | 281 | ||
282 | ifneq ($(findstring STM32G431, $(MCU)),) | ||
283 | # Cortex version | ||
284 | MCU = cortex-m4 | ||
285 | |||
286 | # ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7 | ||
287 | ARMV = 7 | ||
288 | |||
289 | ## chip/board settings | ||
290 | # - the next two should match the directories in | ||
291 | # <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES) | ||
292 | MCU_FAMILY = STM32 | ||
293 | MCU_SERIES = STM32G4xx | ||
294 | |||
295 | # Linker script to use | ||
296 | # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/ | ||
297 | # or <keyboard_dir>/ld/ | ||
298 | MCU_LDSCRIPT ?= STM32G431xB | ||
299 | |||
300 | # Startup code to use | ||
301 | # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/ | ||
302 | MCU_STARTUP ?= stm32g4xx | ||
303 | |||
304 | # Board: it should exist either in <chibios>/os/hal/boards/, | ||
305 | # <keyboard_dir>/boards/, or drivers/boards/ | ||
306 | BOARD ?= GENERIC_STM32_G431XB | ||
307 | |||
308 | USE_FPU ?= yes | ||
309 | |||
310 | # Options to pass to dfu-util when flashing | ||
311 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | ||
312 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | ||
313 | endif | ||
314 | |||
315 | ifneq ($(findstring STM32G474, $(MCU)),) | ||
316 | # Cortex version | ||
317 | MCU = cortex-m4 | ||
318 | |||
319 | # ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7 | ||
320 | ARMV = 7 | ||
321 | |||
322 | ## chip/board settings | ||
323 | # - the next two should match the directories in | ||
324 | # <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES) | ||
325 | MCU_FAMILY = STM32 | ||
326 | MCU_SERIES = STM32G4xx | ||
327 | |||
328 | # Linker script to use | ||
329 | # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/ | ||
330 | # or <keyboard_dir>/ld/ | ||
331 | MCU_LDSCRIPT ?= STM32G474xE | ||
332 | |||
333 | # Startup code to use | ||
334 | # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/ | ||
335 | MCU_STARTUP ?= stm32g4xx | ||
336 | |||
337 | # Board: it should exist either in <chibios>/os/hal/boards/, | ||
338 | # <keyboard_dir>/boards/, or drivers/boards/ | ||
339 | BOARD ?= GENERIC_STM32_G474XE | ||
340 | |||
341 | USE_FPU ?= yes | ||
342 | |||
343 | # Options to pass to dfu-util when flashing | ||
344 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | ||
345 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | ||
346 | endif | ||
347 | |||
282 | ifneq (,$(filter $(MCU),at90usb162 atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647 at90usb1286 at90usb1287)) | 348 | ifneq (,$(filter $(MCU),at90usb162 atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647 at90usb1286 at90usb1287)) |
283 | PROTOCOL = LUFA | 349 | PROTOCOL = LUFA |
284 | 350 | ||