This is a very simple guide, reviewing the steps required to get Blinky working on an Mbed OS platform.

Mbed OS Blinky

This example shows the use of a DigitalOut object to represent an LED and use of the nonblocking Thread::wait() call. Using nonblocking calls is good practice because Mbed OS can schedule and run other threads while the first thread is waiting.

Building this example

Building with Arm Mbed CLI

To use Mbed CLI to build this example, follow the instructions in the documentation. The instructions here relate to using the Arm Online Compiler.

To use the Online Compiler, import this code into the Online Compiler, and select your platform from the top right. Compile the code using the compile button, load it onto your board and press the reset button on the board. The code will run on the board, and you will see the LED blink.

You can find more instructions for using the Mbed Online Compiler in the documentation.

Revision:
83:7b0fac4e7fd2
Parent:
82:abf1b1785bd7
Child:
89:448e37ce650a
--- a/stats_report.h	Thu Nov 29 00:00:02 2018 +0000
+++ b/stats_report.h	Fri Nov 30 23:45:02 2018 +0000
@@ -41,17 +41,6 @@
         printf("CPU ID: 0x%lx \r\n", sys_stats.cpu_id);
         printf("Compiler ID: %d \r\n", sys_stats.compiler_id);
         printf("Compiler Version: %ld \r\n", sys_stats.compiler_version);
-
-        for (int i = 0; i < MBED_MAX_MEM_REGIONS; i++) {
-            if (sys_stats.ram_size[i] != 0) {
-                printf("RAM%d: Start 0x%lx Size: 0x%lx \r\n", i, sys_stats.ram_start[i], sys_stats.ram_size[i]);
-            }
-        }
-        for (int i = 0; i < MBED_MAX_MEM_REGIONS; i++) {
-            if (sys_stats.rom_size[i] != 0) {
-                printf("ROM%d: Start 0x%lx Size: 0x%lx \r\n", i, sys_stats.rom_start[i], sys_stats.rom_size[i]);
-            }
-        }
     }
 
     ~SystemReport(void)