RadiantRVA
/
rbVectorIQ
share for RS
Fork of rbVectorIQ by
Diff: main.cpp
- Revision:
- 10:eb100af346bf
- Parent:
- 8:e275405a431d
- Child:
- 11:45f76d2b5b8c
--- a/main.cpp Fri Dec 16 00:13:52 2016 +0000 +++ b/main.cpp Fri Dec 16 17:02:34 2016 +0000 @@ -32,7 +32,7 @@ #define DIGITAL_OUT_PIN P0_17 //D7 #define BOARD_LED P0_19 // -#define DIGITAL_IN_PIN P0_5 //A4 +#define DIGITAL_IN_PIN P0_9 //P0_5 //A4 #define PWM_PIN P0_16 //D6 #define SERVO_PIN P0_14 //D10 #define ANALOG_IN_PIN P0_6 //A5 @@ -180,7 +180,11 @@ // If digital in changes, report the state if (BUTTON != old_state) { old_state = BUTTON; - + if (LEDS_ON_FLAG) + LEDS_ON_FLAG = 0; + else + LEDS_ON_FLAG = 1; + if (BUTTON == 1) { buf[0] = (0x0A); buf[1] = (0x01);