0

How can I add the STM32duino core as a custom platform to PlatformIO?

1

1 Answer 1

1

Creating custom board support for PlatformIO

PlatformIO provides a very comprehensive documentation on how to use PlatformIO for programming STM32 with various platforms. You can find "Custom Platform & Boards" on the side menu, which will lead you to this section of the document, which again is well documented.

It basically involves creating a JSON file that describes your custom platform or custom board. The easier way is to copy one of the family MCUs JSON configuration file that's already supported by the PlatformIO or STM32duino framework, and make modifications from there. For example, if your custom board is STM32G070xx, which is not supported by PlatformIO yet, you can find the board description JSON from platform-stm32 github repository for Nucleo_G070RB board and use it as a template to create your own custom board JSON structure.

Creating custom board support for Arduino IDE

The official STM32duino wiki provides a description on how to create a custom board variant on Arduino IDE for the framework. I also have an example of a custom variant for supporting my two custom boards in my github that you could take a look at in case you are interested to create custom board support under Arduino IDE.

2
  • the question is not about custom board
    – Juraj
    Commented Dec 28, 2023 at 5:53
  • 2
    @juraj, One of the links that I provided including the information for creating custom platform manifest file under PlatformIO. OP mentioned STMduino which means a platform and a specific framework (arduino) has been defined, so I assumed what he means for "custom platform" actually means for "custom board". This is also why I at the beginning only provide a broader link instead of a specific link. I will let the OP to decide what he is looking for. If this is not what he is looking for, I'm sure OP will speak out.
    – hcheung
    Commented Dec 28, 2023 at 6:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.