remesh kumaran
/
Nucleo_blink_led
new
Diff: main.cpp
- Revision:
- 0:1b2f31108312
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Thu Sep 28 09:29:40 2017 +0000 @@ -0,0 +1,22 @@ +#include "mbed.h" + +DigitalOut myled(LED1); +DigitalOut myled2(LED2); +DigitalOut myled3(LED3); + +int main() { + while(1) { + myled = 1; // LED is ON + wait(0.2); // 200 ms + myled = 0; // LED is OFF + wait(1.0); // 1 sec + myled2= 1; // LED is ON + wait(0.2); // 200 ms + myled2 = 0; // LED is OFF + wait(1.0); // 1 sec + myled3= 1; // LED is ON + wait(0.2); // 200 ms + myled3 = 0; // LED is OFF + wait(1.0); // 1 sec + } +}