8 years, 3 months ago.

about mbed/cube/compiler

Hi all, I got the nucleoF446RE board today. After reading the manual for a while, I install the JLink driver and firmware. For compiler, I choose SW4STM32. It seems working all right to compile the example. But I still have few questions. First, what is STM32CubeF4? On the back of the package, it said STM32CubeF4 embeeded software solution featuring drivers, RTOS, file system, USB, TCP/IP and graphics. So is it an OS that must be installed to the STM32 before we upload the binary code to run our application? Is Cube the mbed's back frame? or mbed is different thing? The pack said it is mbed enabled, so do I have to install anything before I can use it?

I ask a question regarding how the code upload to STM32. I was told that the code will be uploaded via the jlink and the code will be gone when the power off. With SW4STM32, I need to compile the src to binary code run debug to make it run on the board. But in future, is it any way I can have the compiled binary run automatically every time when the board is power up?

3 Answers

8 years, 3 months ago.

Take a look at the platform page:

https://developer.mbed.org/platforms/ST-Nucleo-F446RE/

Make sure you have this added to your platforms. Click add to your compiler if you have not done this yet.

As you scroll down you will see instructions to update the ST-Link firmware.

Do that first. Then on the right hand side of the page you will see many examples to try. First import and try the 'Nucleo_blink_led' program, compile that and load (save) it to your board. Very simple but will confirm your set up is working.

Once you have downloaded a program to your board, it will remain there until you program it subsequently with another program. Remove the power (USB) cable and plug back in, the program will start running again.

The CUBE facility is not need for Mbed, this can be used if you working on an offline compiler and need to generate system files. That's already built into Mbed.

Thanks Paul. Following the instruction, I get it works now. I am reading some material on mbed, it has some module like mbed client, mbed OS and other stuff. I wonder do we need those installed to make it work? I am trying to download and install mbed clients to windows, but I only see the source and header, I don't know how to get it installed.

For the mbed OS, I use the windows installer, it install everything but it fails to install the windows serial module for it said 'the STM board is not plugged in' I have no idea why since it is connected and I can program it with Jlink.

Anyway, my question, does mbed OS really need?

posted by kim jone 23 Jan 2016
8 years, 3 months ago.

STM Cube is just a planning tool from ST to help select pins/functions for the device. Cube will build a template with initialization if you need it. It is not needed to run code on the device.

If you used Mbed instead you would not have to worry about all that you could have just assigned your functions and been up and running. The mbed framework takes care of all the needed initialization for the device and peripherals for you.

And you can run mbed locally if you have GCC / IAR / Keil as your base development. Other platforms that are GCC based can be used to build mbed as well.

8 years, 3 months ago.

Guys, The last time I looked, MBED did not have all the peripherals ported, so STM32Cube can be used to generate the templates for those that are missing, they can then be copied to your program and compiled using mbed, this works very well. The STM32Cube is a useful tool, when used with mbed or on its own.

This sounds interesting - I don't suppose you have a simple example if this you could share?

posted by Nicholas Outram 25 Jul 2017