n
Dependencies: QEI TextLCD mbed
Revision 1:7b43d1823567, committed 2013-11-08
- Comitter:
- fvelasquezv
- Date:
- Fri Nov 08 15:58:41 2013 +0000
- Parent:
- 0:23ecb0de1978
- Commit message:
- nada;
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r 23ecb0de1978 -r 7b43d1823567 main.cpp --- a/main.cpp Fri Nov 01 16:11:59 2013 +0000 +++ b/main.cpp Fri Nov 08 15:58:41 2013 +0000 @@ -1,17 +1,24 @@ -#include "mbed.h" + #include "QEI.h" #include "TextLCD.h" TextLCD lcd(PTC10, PTC11, PTC12, PTC13, PTC16, PTC17); // rs, e, d4-d7TextLCD lcd(PTC10, PTC11, PTC12, PTC13, PTC16, PTC17); // rs, e, d4-d7 -QEI wheel(PTE4, PTE3, NC, 624); +QEI leftQei(PTD6, PTD7, NC, 624); int main() { - - while(1){ + lcd.locate(0,0); + lcd.printf("pulsos: "); - lcd.printf("Pulses is: %i\n", wheel.getPulses()); - wait(0.11); + while(1){ + lcd.locate(8,0); + lcd.printf(" "); + + lcd.locate(8,0); + lcd.printf("%i",leftQei.getPulses()); + wait(0.2); } } + +