diff --git a/platformio.ini b/platformio.ini index db985c9..c37c322 100644 --- a/platformio.ini +++ b/platformio.ini @@ -1,40 +1,36 @@ -; PlatformIO Project Configuration File -; -; Build options: build flags, source filter -; Upload options: custom upload port, speed and extra flags -; Library options: dependencies, extra library storages -; Advanced options: extra scripting -; -; Please visit documentation for the other options and examples -; https://docs.platformio.org/page/projectconf.html +; PlatformIO Project Configuration File https://docs.platformio.org/page/projectconf.html [env:genericSTM32F103C8] platform = ststm32 board = genericSTM32F103C8 -; board = bluepill_f103c8 board_build.mcu = stm32f103c8t6 board_build.core = maple framework = arduino -lib_ignore = USBComposite/, FreeRTOS701, FreeRTOS821, FreeRTOS900, Ethernet_STM, libmaple - lib_deps = greiman/SdFat @ ^2.0.4 upload_protocol = stlink +; Older gcc version produces much faster binaries than the latest. platform_packages = toolchain-gccarmnoneeabi@1.40804.0 build_unflags = + -Os + -DARDUINO_ARCH_STM32F1 build_flags = - -D PIO_FRAMEWORK_ARDUINO_STANDARD_LIB - -w -O3 - -std=gnu11 -std=gnu++11 -nostdlib -mthumb -march=armv7-m -D__STM32F1__ -DARDUINO_ARCH_STM32 -MMD - -ffunction-sections -fdata-sections - -funroll-loops - -D DEBUG_LEVEL=DEBUG_NONE + -w + -DDEBUG_LEVEL=DEBUG_NONE + -DARDUINO_GENERIC_STM32F103C + -DARDUINO_LIB_DISCOVERY_PHASE + -DARDUINO=10813 + -DARDUINO_ARCH_STM32 + ; --param max-inline-insns-single=500 ; PlatformIO doesnt like this? ; Possible work around for clones, untested. ; https://community.platformio.org/t/cannot-upload-to-stm32-bluepill-board-over-stlink-v2/3492/25 ; upload_flags = -c set CPUTAPID 0x2ba01477 +; Unsure if needed to ignore anymore or not. +; lib_ignore = USBComposite/, FreeRTOS701, FreeRTOS821, FreeRTOS900, Ethernet_STM, libmaple + ; [env:debug] ; build_type = debug ; debug_tool = stlink