![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Blinky
Diff: main.cpp
- Revision:
- 0:8af8e4ec230d
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Tue Feb 09 20:55:14 2021 +0000 @@ -0,0 +1,24 @@ +/* mbed Microcontroller Library + * Copyright (c) 2019 ARM Limited + * SPDX-License-Identifier: Apache-2.0 + */ + +#include "mbed.h" +#include "platform/mbed_thread.h" + + +// Blinking rate in milliseconds +#define BLINKING_RATE_MS 5000 + + +int main() +{ + // Initialise the digital pin LED1 as an output + DigitalOut led(LED1); + + printf("Starting web program... \r\n"); + while (true) { + led = !led; + thread_sleep_for(2000); + } +}