Takumi Okamoto
/
my_mbed_cli_pg
my cli test
main.cpp@0:be7062dba746, 2016-09-16 (annotated)
- Committer:
- MrBearing
- Date:
- Fri Sep 16 23:07:20 2016 +0000
- Revision:
- 0:be7062dba746
- Child:
- 1:db8a88f5182b
ini commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
MrBearing | 0:be7062dba746 | 1 | #include "mbed.h" |
MrBearing | 0:be7062dba746 | 2 | |
MrBearing | 0:be7062dba746 | 3 | DigitalOut led1(LED1); |
MrBearing | 0:be7062dba746 | 4 | |
MrBearing | 0:be7062dba746 | 5 | // main() runs in its own thread in the OS |
MrBearing | 0:be7062dba746 | 6 | // (note the calls to Thread::wait below for delays) |
MrBearing | 0:be7062dba746 | 7 | int main() { |
MrBearing | 0:be7062dba746 | 8 | while (true) { |
MrBearing | 0:be7062dba746 | 9 | led1 = !led1; |
MrBearing | 0:be7062dba746 | 10 | Thread::wait(500); |
MrBearing | 0:be7062dba746 | 11 | } |
MrBearing | 0:be7062dba746 | 12 | } |
MrBearing | 0:be7062dba746 | 13 |