diff options
Diffstat (limited to 'tmk_core/protocol/lufa')
-rw-r--r-- | tmk_core/protocol/lufa/adafruit_ble.cpp | 6 | ||||
-rw-r--r-- | tmk_core/protocol/lufa/lufa.c | 7 |
2 files changed, 5 insertions, 8 deletions
diff --git a/tmk_core/protocol/lufa/adafruit_ble.cpp b/tmk_core/protocol/lufa/adafruit_ble.cpp index 505794a80c..7b3ffdef7a 100644 --- a/tmk_core/protocol/lufa/adafruit_ble.cpp +++ b/tmk_core/protocol/lufa/adafruit_ble.cpp @@ -31,9 +31,9 @@ #define ConnectionUpdateInterval 1000 /* milliseconds */ #ifdef SAMPLE_BATTERY -#ifndef BATTERY_LEVEL_PIN -# define BATTERY_LEVEL_PIN 7 -#endif +# ifndef BATTERY_LEVEL_PIN +# define BATTERY_LEVEL_PIN 7 +# endif #endif static struct { diff --git a/tmk_core/protocol/lufa/lufa.c b/tmk_core/protocol/lufa/lufa.c index eb166c828e..8319b34e94 100644 --- a/tmk_core/protocol/lufa/lufa.c +++ b/tmk_core/protocol/lufa/lufa.c @@ -914,14 +914,11 @@ void virtser_send(const uint8_t byte) { */ static void setup_mcu(void) { /* Disable watchdog if enabled by bootloader/fuses */ - MCUSR &= ~(1 << WDRF); + MCUSR &= ~_BV(WDRF); wdt_disable(); /* Disable clock division */ - // clock_prescale_set(clock_div_1); - - CLKPR = (1 << CLKPCE); - CLKPR = (0 << CLKPS3) | (0 << CLKPS2) | (0 << CLKPS1) | (0 << CLKPS0); + clock_prescale_set(clock_div_1); } /** \brief Setup USB |