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:cbe746b508b4, 2022-05-22 (annotated)
- Committer:
- hughbellinger
- Date:
- Sun May 22 20:17:54 2022 +0000
- Revision:
- 0:cbe746b508b4
1
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| hughbellinger | 0:cbe746b508b4 | 1 | #include "mbed.h" |
| hughbellinger | 0:cbe746b508b4 | 2 | DigitalOut T1(p5); |
| hughbellinger | 0:cbe746b508b4 | 3 | DigitalOut T2(p6); |
| hughbellinger | 0:cbe746b508b4 | 4 | DigitalOut T3(p7); |
| hughbellinger | 0:cbe746b508b4 | 5 | DigitalOut T4(p8); |
| hughbellinger | 0:cbe746b508b4 | 6 | |
| hughbellinger | 0:cbe746b508b4 | 7 | int main() { |
| hughbellinger | 0:cbe746b508b4 | 8 | while(1) { |
| hughbellinger | 0:cbe746b508b4 | 9 | T1=T3= 1; |
| hughbellinger | 0:cbe746b508b4 | 10 | T2=T4= 0; |
| hughbellinger | 0:cbe746b508b4 | 11 | wait(1); |
| hughbellinger | 0:cbe746b508b4 | 12 | T1=T3= 0; |
| hughbellinger | 0:cbe746b508b4 | 13 | T2=T4= 1; |
| hughbellinger | 0:cbe746b508b4 | 14 | wait(1); |
| hughbellinger | 0:cbe746b508b4 | 15 | } |
| hughbellinger | 0:cbe746b508b4 | 16 | } |