This is just a small program to check what possible led effects could be done - ofcourse the knight rider is the coolest one :)

Dependencies:   mbed

main.cpp

Committer:
Flanker
Date:
2010-08-01
Revision:
0:7ac23aec3248

File content as of revision 0:7ac23aec3248:

#include "mbed.h"
//This is just a small testing program what LED effects can be done (knight rider style :))

DigitalOut myled1(LED1);
DigitalOut myled2(LED2);
DigitalOut myled3(LED3);
DigitalOut myled4(LED4);

int main() {
    while(1) {
        //This part will turn on the leds
        myled1 = 1;
        wait(0.1);
        myled2 = 1;
        wait(0.1);
        myled3 = 1;
        wait(0.1);
        myled4 = 1;
        wait(0.1);
        //This part will turn off the leds
        myled1 = 0;
        wait(0.1);
        myled2 = 0;
        wait(0.1);
        myled3 = 0;
        wait(0.1);
        myled4 = 0;
        wait(0.1);
    }
}