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:669dfa45a8c6, 2020-05-12 (annotated)
- Committer:
- tylerwganderson
- Date:
- Tue May 12 22:46:15 2020 +0000
- Revision:
- 0:669dfa45a8c6
first commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
tylerwganderson | 0:669dfa45a8c6 | 1 | #include "mbed.h" |
tylerwganderson | 0:669dfa45a8c6 | 2 | |
tylerwganderson | 0:669dfa45a8c6 | 3 | DigitalOut myled(LED1); |
tylerwganderson | 0:669dfa45a8c6 | 4 | |
tylerwganderson | 0:669dfa45a8c6 | 5 | int main() { |
tylerwganderson | 0:669dfa45a8c6 | 6 | while(1) { |
tylerwganderson | 0:669dfa45a8c6 | 7 | myled = 1; // LED is ON |
tylerwganderson | 0:669dfa45a8c6 | 8 | wait(0.2); // 200 ms |
tylerwganderson | 0:669dfa45a8c6 | 9 | myled = 0; // LED is OFF |
tylerwganderson | 0:669dfa45a8c6 | 10 | wait(1.0); // 1 sec |
tylerwganderson | 0:669dfa45a8c6 | 11 | } |
tylerwganderson | 0:669dfa45a8c6 | 12 | } |