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.
Revision 0:7f5c273fe35a, committed 2019-10-09
- Comitter:
- contechno
- Date:
- Wed Oct 09 17:21:15 2019 +0000
- Commit message:
- UNAL_Procesadores; Actividad 1
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
mbed.bld | Show annotated file Show diff for this revision Revisions of this file |
diff -r 000000000000 -r 7f5c273fe35a main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Wed Oct 09 17:21:15 2019 +0000 @@ -0,0 +1,52 @@ +#include "mbed.h" + +DigitalOut red(LED1); //red +DigitalOut green(LED2); //Green +DigitalOut blue(LED3); //Blue + +int main() { + + // Reset all LEDs to off (LEDs are low-active) + red = 1; + green = 1; + blue = 1; + + while(1) { + + //light red LED 1s + red = 0; + wait(1); + red = 1; + + //light green LED 1s + green = 0; + wait(1); + green = 1; + + //light blue LED 1s + blue = 0; + wait(1); + blue = 1; + + //light red and green (=yellow) LEDs 1s + red = 0; + green = 0; + wait(1); + red = 1; + green = 1; + + //light red and blue (=magenta) LEDs 1s + red = 0; + blue = 0; + wait(1); + red = 1; + blue = 1; + + //light blue and green (=cyan) LEDs 1s + blue = 0; + green = 0; + wait(1); + blue = 1; + green = 1; + } +}
diff -r 000000000000 -r 7f5c273fe35a mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Wed Oct 09 17:21:15 2019 +0000 @@ -0,0 +1,1 @@ +https://os.mbed.com/users/mbed_official/code/mbed/builds/65be27845400 \ No newline at end of file