Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
main.cpp@1:13e6ce047a95, 2017-01-03 (annotated)
- Committer:
- fred.li@arm.com
- Date:
- Tue Jan 03 10:23:40 2017 +0800
- Revision:
- 1:13e6ce047a95
main.cpp
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| fred.li@arm.com | 1:13e6ce047a95 | 1 | #include "mbed.h" |
| fred.li@arm.com | 1:13e6ce047a95 | 2 | |
| fred.li@arm.com | 1:13e6ce047a95 | 3 | DigitalOut led1(LED1); |
| fred.li@arm.com | 1:13e6ce047a95 | 4 | |
| fred.li@arm.com | 1:13e6ce047a95 | 5 | #ifdef FRED_EST |
| fred.li@arm.com | 1:13e6ce047a95 | 6 | //this is just a testafaaffa |
| fred.li@arm.com | 1:13e6ce047a95 | 7 | #endif |
| fred.li@arm.com | 1:13e6ce047a95 | 8 | |
| fred.li@arm.com | 1:13e6ce047a95 | 9 | // main() runs in its own thread in the OS |
| fred.li@arm.com | 1:13e6ce047a95 | 10 | // (note the calls to Thread::wait below for delays) |
| fred.li@arm.com | 1:13e6ce047a95 | 11 | int main() { |
| fred.li@arm.com | 1:13e6ce047a95 | 12 | while (true) { |
| fred.li@arm.com | 1:13e6ce047a95 | 13 | led1 = !led1; |
| fred.li@arm.com | 1:13e6ce047a95 | 14 | Thread::wait(500); |
| fred.li@arm.com | 1:13e6ce047a95 | 15 | } |
| fred.li@arm.com | 1:13e6ce047a95 | 16 | } |
| fred.li@arm.com | 1:13e6ce047a95 | 17 |