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: mbed
Fork of DigitalInOut_HelloWorld_Mbed by
main.cpp@0:0d0417932681, 2013-02-13 (annotated)
- Committer:
- mbed_official
- Date:
- Wed Feb 13 16:11:53 2013 +0000
- Revision:
- 0:0d0417932681
DigitalInOut Hello World
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mbed_official | 0:0d0417932681 | 1 | #include "mbed.h" |
mbed_official | 0:0d0417932681 | 2 | |
mbed_official | 0:0d0417932681 | 3 | DigitalInOut pin(p5); |
mbed_official | 0:0d0417932681 | 4 | |
mbed_official | 0:0d0417932681 | 5 | int main() { |
mbed_official | 0:0d0417932681 | 6 | pin.output(); |
mbed_official | 0:0d0417932681 | 7 | pin = 0; |
mbed_official | 0:0d0417932681 | 8 | wait_us(500); |
mbed_official | 0:0d0417932681 | 9 | pin.input(); |
mbed_official | 0:0d0417932681 | 10 | wait_us(500); |
mbed_official | 0:0d0417932681 | 11 | } |