Ivan Istuk
/
TVZ_MU2013_Zadatak8
V0.1
Fork of TVZ_MU2013_Zadatak8 by
Revision 1:aca0a1dbae28, committed 2014-02-04
- Comitter:
- iistuk
- Date:
- Tue Feb 04 17:21:06 2014 +0000
- Parent:
- 0:f30920c6bb40
- Child:
- 2:5893d8d2b248
- Commit message:
- !
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Tue Dec 17 15:18:14 2013 +0000 +++ b/main.cpp Tue Feb 04 17:21:06 2014 +0000 @@ -1,12 +1,29 @@ #include "mbed.h" +DigitalIn SenzorL(p15); +DigitalIn SenzorD(p16); +/*AnalogOut VentL(p11); +AnalogOut VentD(p10);*/ +DigitalOut led1(p5); +DigitalOut led2(p7); DigitalOut myled(LED1); + int main() { - while(1) { - myled = 1; - wait(0.2); - myled = 0; - wait(0.2); + enum poz {lijevo, sredina, desno}; + /*poz pozicija; + VentL=1; + wait(5); + VentL=0; + pozicija=desno;*/ + while(1) { + if(SenzorL==1) { + led1=1; + } + if(SenzorD==1) { + led2=2; + } + + } }