Digital Output simple example for WIZwiki-W7500 academy

Dependencies:   mbed

Fork of DigitalOut_HelloWorld_WIZwiki-W7500 by Lawrence Lee

main.cpp

Committer:
joon874
Date:
2015-07-10
Revision:
3:feaf2432da5b
Parent:
2:a40176947d21
Child:
4:51a161fb600c

File content as of revision 3:feaf2432da5b:

/* Digital Output Example Program */

#include "mbed.h"

DigitalOut myled1(LED1);    // On-board LED_RED
DigitalOut myled2(LED2);
DigitalOut myled3(LED3);
int main()
{
    while(1) {
        myled1 = 1;       // Red LED Off
        myled2 = 0;
        myled3 = 0;
        wait(0.2);       // 0.2 sec delay
        myled1 = 0;       // Red LED Off
        myled2 = 1;
        myled3 = 0;
        wait(0.2);
        myled1 = 0;       // Red LED Off
        myled2 = 0;
        myled3 = 1;
        wait(0.2);
    }
}