8 years, 1 month ago.

From Prototyping to production

Hello I have been using mbed to do several programs using a STM32F091. They work great.

Now I am reading about "exporting " to offline toolchains. To my surprise, it seems that I can use mbed with offline tools too.

My first question :

1) Is this only for "mbed enabled" platforms?

I have been using the nucleo board so far. What if I want to create my own board using the corresponding microcontroller. Can I still use the mbed program for that?

Thanks a lot for any advice you can give me

1 Answer

8 years, 1 month ago.

Yes, there is very little stopping you from doing so. The code mbed makes is specific for the MCU (and similar MCUs, for example only with less flash, also work fine with the same code), not for the board. Only small details, like the LED1, LED2, etc definitions only work of course properly for boards which have LEDs connected to those pins.

So yes, both technically and legally it is perfectly fine to do that.

Thank you for your answer. My next question is how?? For example in my particular case, as I said I have been working with a Nucleo board (mbed enabled). Say I buy a STM32F091 microprocessor (the one in the nucleo) and somehow I have also a self designed board. Say that the LEDs and other stuff is in the right place (or pin). And I have the mbed program.

How can I flash that into my microprocessor and make it work? Doesn't it have to be "mbed enabled"? What does "mbed enabled" mean anyway?

This is very important for my future work so I will really appreciate some pointer or advice thanks a lot!

posted by Cristian Fuentes 08 Apr 2016

As a side note, does what I am trying to do (making a self made board work with mbed) fall into the category of "mbed SDK porting"???

posted by Cristian Fuentes 08 Apr 2016

Well I am not familiar myself with stand-alone programming of STMs, but you will need some kind of programmer. I believe you can use any Nucleo board as programmer for any STM32 MCU, but I am not 100% sure about that one. Generally they also have built-in bootloaders, but I don't know which ones the STM32 has. Just get one and get started ;).

The STM32 code is also made to automatically use correct clock, so that should work properly automatically. Only if you have a crystal, it is easiest to use same crystal (frequency wise) as what the Nucleo board has (otherwise you have to do some minor modifications in mbed files).

No one knows what mbed enabled means :P. In general it means that you can make proper binaries from the mbed online compiler, although there are also some targets that are not supported in the online compiler but you can use in an offline compiler with the mbed source code.

And nop, what you are trying to do is not mbed SDK porting, that would be if you need to modify the source code to make it work (for example if you want to make it work on an MCU that no support for exists yet).

posted by Erik - 08 Apr 2016

Here's some interesting work from Chris Styles on integrating an mbed microcontroller onto a custom designed board: https://developer.mbed.org/users/chris/notebook/prototype-to-hardware/.

posted by Jan Jongboom 11 Apr 2016