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@0:b01f392d7a29, 2018-04-19 (annotated)
- Committer:
- DomCer
- Date:
- Thu Apr 19 12:21:23 2018 +0000
- Revision:
- 0:b01f392d7a29
epudee2018
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
DomCer | 0:b01f392d7a29 | 1 | #include "mbed.h" |
DomCer | 0:b01f392d7a29 | 2 | |
DomCer | 0:b01f392d7a29 | 3 | DigitalOut myled(LED1); |
DomCer | 0:b01f392d7a29 | 4 | int main() { |
DomCer | 0:b01f392d7a29 | 5 | while(1) { |
DomCer | 0:b01f392d7a29 | 6 | myled = 1; // LED is ON |
DomCer | 0:b01f392d7a29 | 7 | wait(0.2); // 200 ms |
DomCer | 0:b01f392d7a29 | 8 | myled = 0; // LED is OFF |
DomCer | 0:b01f392d7a29 | 9 | wait(1.0); // 1 sec |
DomCer | 0:b01f392d7a29 | 10 | } |
DomCer | 0:b01f392d7a29 | 11 | } |