Skip to content

chore(system): define USE_HAL_DRIVER on command line #2380

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions CI/update/templates/system_stm32yyxx.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#define USE_HAL_DRIVER

{% for system in system_list %}
{% if loop.first %}
#ifdef {{system.serie}}
Expand Down
1 change: 1 addition & 0 deletions cmake/set_base_arduino_config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ target_link_libraries(base_config INTERFACE
gcc
)
target_compile_definitions(base_config INTERFACE
USE_HAL_DRIVER
USE_FULL_LL_DRIVER
ARDUINO_ARCH_STM32
)
Expand Down
2 changes: 0 additions & 2 deletions cores/arduino/stm32/stm32_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
|(STM32_CORE_VERSION_PATCH << 8U )\
|(STM32_CORE_VERSION_EXTRA))

#define USE_HAL_DRIVER

#if defined(STM32C0xx)
#include "stm32c0xx.h"
#elif defined(STM32F0xx)
Expand Down
2 changes: 0 additions & 2 deletions libraries/SrcWrapper/src/stm32/system_stm32yyxx.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#define USE_HAL_DRIVER

#ifdef STM32C0xx
#include "system_stm32c0xx.c"
#elif STM32F0xx
Expand Down
2 changes: 1 addition & 1 deletion platform.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ compiler.objcopy.cmd=arm-none-eabi-objcopy
compiler.elf2hex.cmd=arm-none-eabi-objcopy
compiler.libraries.ldflags=

compiler.extra_flags=-mcpu={build.mcu} {build.fpu} {build.float-abi} -DVECT_TAB_OFFSET={build.flash_offset} -DUSE_FULL_LL_DRIVER -mthumb "@{build.opt.path}"
compiler.extra_flags=-mcpu={build.mcu} {build.fpu} {build.float-abi} -DVECT_TAB_OFFSET={build.flash_offset} -DUSE_HAL_DRIVER -DUSE_FULL_LL_DRIVER -mthumb "@{build.opt.path}"

compiler.S.flags={compiler.extra_flags} -c -x assembler-with-cpp {compiler.stm.extra_include}

Expand Down
1 change: 1 addition & 0 deletions tools/platformio/platformio-build.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ def get_arduino_board_id(board_config, mcu):
"ARDUINO_%s" % board_id,
("BOARD_NAME", '\\"%s\\"' % board_id),
"HAL_UART_MODULE_ENABLED",
"USE_HAL_DRIVER",
"USE_FULL_LL_DRIVER",
(
"VARIANT_H",
Expand Down
Loading