Hello World for DigitalOut
Dependencies: mbed
Fork of DigitalOut_HelloWorld by
main.cpp@1:b66c5cfa5d8f, 2013-02-21 (annotated)
- Committer:
- mbed_official
- Date:
- Thu Feb 21 17:06:56 2013 +0000
- Revision:
- 1:b66c5cfa5d8f
- Parent:
- 0:b5a9e0614efd
use latest version of mbed libraries
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mbed_official | 0:b5a9e0614efd | 1 | #include "mbed.h" |
mbed_official | 0:b5a9e0614efd | 2 | |
mbed_official | 0:b5a9e0614efd | 3 | DigitalOut myled(LED1); |
mbed_official | 0:b5a9e0614efd | 4 | |
mbed_official | 0:b5a9e0614efd | 5 | int main() { |
mbed_official | 0:b5a9e0614efd | 6 | while(1) { |
mbed_official | 0:b5a9e0614efd | 7 | myled = 1; |
mbed_official | 0:b5a9e0614efd | 8 | wait(0.2); |
mbed_official | 0:b5a9e0614efd | 9 | myled = 0; |
mbed_official | 0:b5a9e0614efd | 10 | wait(0.2); |
mbed_official | 0:b5a9e0614efd | 11 | } |
mbed_official | 0:b5a9e0614efd | 12 | } |