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:
- gcarmonar
- Date:
- 2013-10-24
- Revision:
- 0:1b2cc5f10340
- Child:
- 1:4011df68bd01
File content as of revision 0:1b2cc5f10340:
#include "mbed.h" DigitalOut led1(LED1); DigitalOut led2(LED2); int reps = 100; //modifica este valor para hacer la secuencia mas rapida o lenta int main() { while(1) { led1 = 0; //enciendo led azul while(count < reps){ //equivalente a un wait de aprox 100 ms porque hago 100 veces pausa de 1 ms wait(0.001); } led1 = 1; //apago led1 led2 = 0; //enciendo led2 while(count < reps){ //equivalente a un wait de aprox 100 ms wait(0.001); } led2 = 1; //apago led2 } }