Masa 3
/
HelloWorld
Test program for Interface
Fork of HelloWorld by
main.cpp@2:7d2909f45e92, 2014-07-01 (annotated)
- Committer:
- Masa3
- Date:
- Tue Jul 01 04:43:44 2014 +0000
- Revision:
- 2:7d2909f45e92
- Parent:
- 0:fb6bbc10ffa0
Added myled2(LED2)
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
simon | 0:fb6bbc10ffa0 | 1 | #include "mbed.h" |
simon | 0:fb6bbc10ffa0 | 2 | |
simon | 0:fb6bbc10ffa0 | 3 | DigitalOut myled(LED1); |
Masa3 | 2:7d2909f45e92 | 4 | DigitalOut myled2(LED2); |
simon | 0:fb6bbc10ffa0 | 5 | |
simon | 0:fb6bbc10ffa0 | 6 | int main() { |
simon | 0:fb6bbc10ffa0 | 7 | while(1) { |
simon | 0:fb6bbc10ffa0 | 8 | myled = 1; |
Masa3 | 2:7d2909f45e92 | 9 | myled2 = 0; |
simon | 0:fb6bbc10ffa0 | 10 | wait(0.2); |
simon | 0:fb6bbc10ffa0 | 11 | myled = 0; |
Masa3 | 2:7d2909f45e92 | 12 | myled2 = 1; |
simon | 0:fb6bbc10ffa0 | 13 | wait(0.2); |
simon | 0:fb6bbc10ffa0 | 14 | } |
simon | 0:fb6bbc10ffa0 | 15 | } |