a
Dependencies: mbed
Revision 0:8c3a031d8104, committed 2015-01-28
- Comitter:
- bulmenwt
- Date:
- Wed Jan 28 07:51:25 2015 +0000
- Commit message:
- a
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
mbed.bld | Show annotated file Show diff for this revision Revisions of this file |
diff -r 000000000000 -r 8c3a031d8104 main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Wed Jan 28 07:51:25 2015 +0000 @@ -0,0 +1,34 @@ +#include "mbed.h" + +DigitalOut Led1(LED1); +DigitalOut Led2(LED2); +DigitalOut Led3(LED3); +DigitalOut Led4(LED4); + +Serial pc(USBTX, USBRX); // tx, rx +char ch; + + + +int main() { + pc.printf("LED schalten mittels Raspberry PI!\r\n"); + pc.printf("DI Franz Wolf (WF)\r\n"); + pc.printf("Drücken Sie 1, 2, 3 oder 4 (LED) <n>\r\n"); + while (1) { + ch = pc.getc(); + + + switch (ch) { + case '1': //Wave-Drive-Betrieb (Wellenschritt-Modus)rechts + Led2 = !Led2; + break; + + case '2': //Wave-Drive-Betrieb (Wellenschritt-Modus)links + Led2 = !Led2; + break; + + default: pc.printf("nichts ist irgendwas\n"); break; + + } + } +}
diff -r 000000000000 -r 8c3a031d8104 mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Wed Jan 28 07:51:25 2015 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/552587b429a1 \ No newline at end of file