Marvin Villamizar
/
Nucleo_blink_led
adfasdfsaf
Revision 0:2aec92a50cc0, committed 2017-06-09
- Comitter:
- dimmu8410
- Date:
- Fri Jun 09 23:13:32 2017 +0000
- Commit message:
- edfasdfasdf
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 2aec92a50cc0 main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Fri Jun 09 23:13:32 2017 +0000 @@ -0,0 +1,49 @@ +#include "mbed.h" +//#define jess PB_6 +//#define jess2 PB_7 +//#define jess3 PB_8 +/* +DigitalOut myled(jess); +DigitalOut myled2(jess2); +DigitalOut myled3(jess3); +DigitalIn boton(PC_13); +*/ +DigitalOut myled(PD_13); +DigitalOut myled2(PD_14); +DigitalOut myled3(PD_15); +PwmOut mypwm(PD_12); +BusOut leds(PD_13,PD_14,PD_15); +float var; +int main() { + while(1) + { + for(int i=0;i<8;i++) + { + leds=i; + //myled=!myled; + wait(0.2); + } + for(float i=0;i<1;i+=0.01) + { + mypwm=i; + wait(0.2); + } + /* + if(boton==0) + { + myled = 1; // LED is ON + wait(1); // 200 ms + myled = 0; // LED is OFF + wait(0.5); // 1 sec + myled2 = 1; // LED is ON + wait(2); // 200 ms + myled2= 0; // LED is OFF + wait(1); // 1 sec + myled3= 1; // LED is ON + wait(3); // 200 ms + myled3= 0; // LED is OFF + wait(1.5); // 1 sec + } + */ + } +}
diff -r 000000000000 -r 2aec92a50cc0 mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Fri Jun 09 23:13:32 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/6c34061e7c34 \ No newline at end of file