HelloWorld

Dependencies:   mbed

Fork of HelloWorld by Simon Ford

Files at this revision

API Documentation at this revision

Comitter:
nvtien
Date:
Wed Sep 19 02:15:48 2018 +0000
Parent:
1:03c191369089
Commit message:
Public

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Sun Jan 01 20:57:57 2012 +0000
+++ b/main.cpp	Wed Sep 19 02:15:48 2018 +0000
@@ -1,12 +1,30 @@
 #include "mbed.h"
 
 DigitalOut myled(LED1);
+DigitalOut myled1(LED2);
+DigitalOut myled2(LED3);
+DigitalOut myled3(LED4);
 
 int main() {
     while(1) {
         myled = 1;
-        wait(0.2);
+        wait(0.5);
         myled = 0;
-        wait(0.2);
+        wait(0.5);
+        
+        myled1 = 1;
+        wait(0.3);
+        myled1 = 0;
+        wait(0.3);
+        
+        myled2 = 1;
+        wait(0.3);
+        myled2 = 0;
+        wait(0.3);
+        
+        myled3 = 1;
+        wait(0.3);
+        myled3 = 0;
+        wait(0.3);
     }
 }