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.
Dependencies: ThingerWIZnetClient mbed
main.cpp@0:50fda55083cb, 2022-09-26 (annotated)
- Committer:
- devdori
- Date:
- Mon Sep 26 07:40:03 2022 +0000
- Revision:
- 0:50fda55083cb
1commit;
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| devdori | 0:50fda55083cb | 1 | #include "mbed.h" |
| devdori | 0:50fda55083cb | 2 | |
| devdori | 0:50fda55083cb | 3 | DigitalOut myled(LED1); |
| devdori | 0:50fda55083cb | 4 | Serial pc(SERIAL_TX, SERIAL_RX); |
| devdori | 0:50fda55083cb | 5 | |
| devdori | 0:50fda55083cb | 6 | int count_blink = 0; |
| devdori | 0:50fda55083cb | 7 | |
| devdori | 0:50fda55083cb | 8 | int main() { |
| devdori | 0:50fda55083cb | 9 | while(1) { |
| devdori | 0:50fda55083cb | 10 | myled = 1; |
| devdori | 0:50fda55083cb | 11 | //pc.printf("myled = 1\n"); |
| devdori | 0:50fda55083cb | 12 | wait(0.2); |
| devdori | 0:50fda55083cb | 13 | myled = 0; |
| devdori | 0:50fda55083cb | 14 | //pc.printf("myled = 0\n"); |
| devdori | 0:50fda55083cb | 15 | wait(0.2); |
| devdori | 0:50fda55083cb | 16 | count_blink++; |
| devdori | 0:50fda55083cb | 17 | pc.printf("The number of blink = %d\n", count_blink); |
| devdori | 0:50fda55083cb | 18 | } |
| devdori | 0:50fda55083cb | 19 | } |