![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
LED Hello World
Fork of HelloWorld by
main.cpp@2:86bd227d75d5, 2014-02-21 (annotated)
- Committer:
- henr22
- Date:
- Fri Feb 21 20:28:56 2014 +0000
- Revision:
- 2:86bd227d75d5
- Parent:
- 0:fb6bbc10ffa0
- Child:
- 3:4e35f0d99e64
added 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); |
henr22 | 2:86bd227d75d5 | 4 | DigitalOut myled2(LED2); |
simon | 0:fb6bbc10ffa0 | 5 | int main() { |
simon | 0:fb6bbc10ffa0 | 6 | while(1) { |
simon | 0:fb6bbc10ffa0 | 7 | myled = 1; |
henr22 | 2:86bd227d75d5 | 8 | myled2 = 0; |
simon | 0:fb6bbc10ffa0 | 9 | wait(0.2); |
simon | 0:fb6bbc10ffa0 | 10 | myled = 0; |
henr22 | 2:86bd227d75d5 | 11 | myled2 = 1; |
simon | 0:fb6bbc10ffa0 | 12 | wait(0.2); |
simon | 0:fb6bbc10ffa0 | 13 | } |
simon | 0:fb6bbc10ffa0 | 14 | } |