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
- Committer:
- hirobe0913
- Date:
- 2015-11-14
- Revision:
- 0:d37007237832
File content as of revision 0:d37007237832:
#include "mbed.h"
/*
DigitalOut myled(dp18);
int main() {
while(1) {
myled = 1;
wait(0.2);
myled = 0;
wait(0.2);
}
}
*/
// Fade a led on.
#include "mbed.h"
PwmOut led(dp18);
int main() {
while(1) {
led = led + 0.01;
wait(0.2);
if(led == 1.0) {
led = 0;
}
}
}