test33
main.cpp@0:870b78bb0e3d, 2014-03-29 (annotated)
- Committer:
- ManuelJoaquim
- Date:
- Sat Mar 29 17:11:41 2014 +0000
- Revision:
- 0:870b78bb0e3d
- Child:
- 1:b6a407375dcc
test33
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
ManuelJoaquim | 0:870b78bb0e3d | 1 | #include "mbed.h" |
ManuelJoaquim | 0:870b78bb0e3d | 2 | |
ManuelJoaquim | 0:870b78bb0e3d | 3 | DigitalOut myled(LED1); |
ManuelJoaquim | 0:870b78bb0e3d | 4 | |
ManuelJoaquim | 0:870b78bb0e3d | 5 | int main() |
ManuelJoaquim | 0:870b78bb0e3d | 6 | { |
ManuelJoaquim | 0:870b78bb0e3d | 7 | while(1) { |
ManuelJoaquim | 0:870b78bb0e3d | 8 | myled = 1; // LED is ON |
ManuelJoaquim | 0:870b78bb0e3d | 9 | wait(0.2); // 200ms |
ManuelJoaquim | 0:870b78bb0e3d | 10 | myled = 0; // LED is OFF |
ManuelJoaquim | 0:870b78bb0e3d | 11 | wait(1.0); // 1 sec |
ManuelJoaquim | 0:870b78bb0e3d | 12 | } |
ManuelJoaquim | 0:870b78bb0e3d | 13 | } |