4 years, 3 months ago.

Getting started with NUCLEO-F412ZG and Mbed Compiler OR another compiler

Hi, I bought a NUCLEO-F412ZG just for fun and get familiar with firmware (I have played with Arduino before). I'm having trouble just getting started with a "Hello, World" program or in this case, "Blinky". I've looked all over, but right now, I'm trying to follow the directions at https://os.mbed.com/teams/mbed-os-examples/code/mbed-os-example-blinky/

I've somehow managed to stumble my way through adding the board to the compiler (it appears in upper right) and importing code (see below) and have compiled. How do I get it to the board? Once compiled, it just asks if I want to save it. Somewhere I read that you can just copy the file to the board and hit reset. But the board does not appear as a folder on my Windows Explorer.

I suspect there is a getting started tutorial somewhere OR there are step I need to do before following the directions at https://os.mbed.com/teams/mbed-os-examples/code/mbed-os-example-blinky/ .

Can someone provide me with tutorial(s)/instructions(s) for the whole process of compile a simple program and pushing it to the board? Also, I'm not sure I should be using the online Mbed Compiler. I just found it first. Other options (especially free) would be most welcome.


1 Answer

4 years, 3 months ago.

Hi Andrew,

I apologize for the delayed response. Once you have compiled your program, you'll want to save it somewhere on your computer. Then, you'll drag and drop that file onto your board in Windows Explorer.

Since you aren't seeing the board when you have it plugged into your computer, you may need to do a couple of things:

  1. Make sure you have the Mbed windows serial drivers installed: https://os.mbed.com/docs/latest/tutorials/windows-serial-driver.html
  2. Upgrade your board's firmware by following the instructions here: https://os.mbed.com/teams/ST/wiki/ST-Link-Driver

Once you've completed those steps you should be able to drag and drop the .bin file to your board!

Please let me know if you have any questions! -Jenny, team Mbed

Hi Jenny and thanks for the answer. For future learners, I'll state that the problem was the USB cable (and bad luck). I did try two different USB cables but I now believe that both of them were "power only" cables. That explains the board getting power but my PC not being able to see it. Perhaps you should consider shipping the board with a cable?

posted by Andrew Walker 22 Mar 2018