Sure thing, here is the relevant sections that I use:
For build flags, most of those are just things I use in my own code, the only one you would really need is HAL_OPAMP_MODULE_ENABLED
.
[power]
supply=24
[common]
lib_archive = false
monitor_speed = 115200
lib_deps =
askuric/Simple FOC@^2.3.3
build_flags =
-D POWER_SUPPLY=${power.supply}
-D MONITOR_SPEED=115200
[disco_b_g431b_esc1]
platform = ststm32
framework = arduino
board = disco_b_g431b_esc1
debug_tool = stlink
upload_protocol = stlink
lib_archive = ${common.lib_archive}
monitor_speed = ${common.monitor_speed}
lib_deps =
${common.lib_deps}
[env:b_g431b_esc1_gbm5]
extends = disco_b_g431b_esc1
build_flags =
${common.build_flags}
-D GBM520875T
-D MOTOR='GBM520875T'
-D POLE_PAIRS=11
-D VOLTAGE_LIMIT=6
-D HAL_OPAMP_MODULE_ENABLED