Page 99 - ARM Based Microcontroller Projects Using MBED
P. 99
7.4 PROJECT 1—FLASHING LED 85
7.4.5 Program Listing
The steps to create and compile the program are given in the following:
• Login to Mbed site
• Click Compiler
• Click New -> New Program. Make sure that the Platform is set to NUCLEO-F411RE. Click
at Template and select Blinky LED test for the ST Nucleo boards. Give a name to your
program, for example, Nucleo_blink_led as shown in Fig. 7.11.
• Expand the Nucleo_blink_led listing in the Program Workspace (at the left-hand side of
the screen). Click on main.cpp and then modify the template as shown in Fig. 7.12.
• Click Compile to compile the program. After a successful compilation you should see the
message Success! As shown in Fig. 7.13
• You should also see a pop-up window asking you to Open or Save the compiled code (see
Fig. 7.14). Click Save File to save the compiled binary file in the download area.
• We are now ready to upload the compiled binary file to the program memory for our
Nucleo board. Connect the Nucleo-F411RE board to the USB port of your PC. You should
see a new device called NODE_F411RE on your PC (see Fig. 7.15)
FIG. 7.13 Successful compilation.
FIG. 7.14 Save the compiled binary file.