platform-ststm32
platform-ststm32 copied to clipboard
Add SPL support for bluepill board
This PR
- activates the SPL framework for the
bluepill_f103c8target - adds a blink LED example with SysTick usage for accurate timing (thereby tests the HSE PLL)
This needed a new example project because the old example tried setting gpio.GPIO_OType = GPIO_OType_PP; and using GPIO_Mode_OUT which doesn't exist in the current SPL framework for STM32F1, version 3.5.0. Instead, we need to set gpio.GPIO_Mode = GPIO_Mode_Out_PP;.
Also needs the corresponding files in the framework-spl folder to enable support for the whole STM32F1 series.
Please tell me how to do a pull-request for the framework-spl package, since I didn't find it as a repository here, but only https://bintray.com/platformio/dl-packages/framework-spl.
I'd need to add new files for framework-spl\stm32\cmsis\variants\stm32f1 and framework-spl\stm32\spl\variants\stm32f1 from the SPL library (here). My framework-spl: https://drive.google.com/open?id=1HTh7bK_5nY7-EjgIgb7_S584TIrOQ_cj
Sorry, I didn't see this PR :(
Can you adapt this example https://github.com/platformio/platform-ststm32/tree/develop/examples/spl-blink with bluepill?
and using GPIO_Mode_OUT which doesn't exist in the current SPL framework for STM32F1, version 3.5.0
Can we update SPL to the latest version too?
@ivankravets I can definitely do an upgrade of all current SPL versions so that they're all up-to-date and then change and add examples. Will tackle this the next days.
Thanks! We will wait for your PR. We wanted to do the next release with mbed OS 5.12 but it is so buggy :(
@maxgerhardt . Excellent work. But, there is one problem. startup_stm32f10x_md.s must be renamed to startup_stm32f10x_md.S. Otherwise, we will get arm-none-eabi-as: unrecognized option `-x' error.
@maxgerhardt where do I find the pio framework-spl package with STM32F103 support pls? for now i used a SPL download from ST, and manually merged files in framework-spl, and that seems to work with your blinkie example. Thanks,Stefaan.
@maxgerhardt where do I find the pio framework-spl package with STM32F103 support pls?
Right now either from my link above, or from STM. The PlatformIO provided one (https://api.registry.platformio.org/v3/packages/platformio/tool/framework-spl) was lasted updated in 2018 and is long overdue for a complete update.
when is this going to be released?
This PR has conflicts and is a weird state, I'll reopen a new clean PR.
Replaced by #667.