this is simple digital in for ublox c027
Fork of DigitalIn_HelloWorld_Mbed by
Diff: main.cpp
- Revision:
- 4:a69bbacf287f
- Parent:
- 3:e2f865861a7a
--- a/main.cpp Sun Sep 21 19:20:53 2014 +0000 +++ b/main.cpp Wed Mar 18 03:53:02 2015 +0000 @@ -1,14 +1,11 @@ #include "mbed.h" - -DigitalIn enable(p5); -DigitalOut led(LED1); - -// blink LED when enable line is high + +DigitalOut d1(P0_0), d2(P0_1), d3(P0_24), d4(P0_25); +Serial pc(USBTX, USBRX); + int main() { while(1) { - if(enable) { - led = !led; + pc.printf("%d\t%d\t%d\t%d\r\n",Do1.read(), Do2.read(), Do3.read(), Do4.read()); + wait(0.5); } - wait(0.25); - } } \ No newline at end of file