Blinks_onBoard_LEDs

Dependencies:   mbed

Committer:
Eduvance
Date:
Tue May 27 07:12:40 2014 +0000
Revision:
1:b390181d55a5
Parent:
0:33a805c5265b
A

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Eduvance 0:33a805c5265b 1 #include "mbed.h"
Eduvance 0:33a805c5265b 2
Eduvance 1:b390181d55a5 3 DigitalOut myled1(LED1);
Eduvance 1:b390181d55a5 4 DigitalOut myled2(LED2);
Eduvance 1:b390181d55a5 5 DigitalOut myled3(LED3);
Eduvance 1:b390181d55a5 6 DigitalOut myled4(LED4);
Eduvance 0:33a805c5265b 7 int main() {
Eduvance 1:b390181d55a5 8 while(1)
Eduvance 1:b390181d55a5 9 {
Eduvance 1:b390181d55a5 10 myled1 = 1;
Eduvance 1:b390181d55a5 11 myled2 = 0;
Eduvance 1:b390181d55a5 12 myled3 = 0;
Eduvance 1:b390181d55a5 13 myled4 = 0;
Eduvance 1:b390181d55a5 14 wait(0.4);
Eduvance 1:b390181d55a5 15
Eduvance 1:b390181d55a5 16 myled1 = 0;
Eduvance 1:b390181d55a5 17 myled2 = 1;
Eduvance 1:b390181d55a5 18 myled3 = 0;
Eduvance 1:b390181d55a5 19 myled4 = 0;
Eduvance 1:b390181d55a5 20 wait(0.4);
Eduvance 1:b390181d55a5 21
Eduvance 1:b390181d55a5 22 myled1 = 0;
Eduvance 1:b390181d55a5 23 myled2 = 0;
Eduvance 1:b390181d55a5 24 myled3 = 1;
Eduvance 1:b390181d55a5 25 myled4 = 0;
Eduvance 1:b390181d55a5 26 wait(0.4);
Eduvance 1:b390181d55a5 27
Eduvance 1:b390181d55a5 28 myled1 = 0;
Eduvance 1:b390181d55a5 29 myled2 = 0;
Eduvance 1:b390181d55a5 30 myled3 = 0;
Eduvance 1:b390181d55a5 31 myled4 = 1;
Eduvance 1:b390181d55a5 32 wait(0.4);
Eduvance 1:b390181d55a5 33
Eduvance 1:b390181d55a5 34
Eduvance 0:33a805c5265b 35 }
Eduvance 0:33a805c5265b 36 }