Skip to content

Commit ccdaabc

Browse files
authored
fix(pins_arduino): Fixes te mask for the Watchy Device pins
1 parent faa9388 commit ccdaabc

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

variants/watchy/pins_arduino.h

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -29,24 +29,22 @@ static const uint8_t RTC_INT_PIN = 27;
2929
#if defined(ARDUINO_WATCHY_V10)
3030
static const uint8_t UP_BTN_PIN = 32;
3131
static const uint8_t BATT_ADC_PIN = 33;
32-
#define UP_BTN_MASK GPIO_SEL_32
3332
#define RTC_TYPE 1 //DS3231
3433
#elif defined(ARDUINO_WATCHY_V15)
3534
static const uint8_t UP_BTN_PIN = 32;
3635
static const uint8_t BATT_ADC_PIN = 35;
37-
#define UP_BTN_MASK GPIO_SEL_32
3836
#define RTC_TYPE 2 //PCF8563
3937
#elif defined(ARDUINO_WATCHY_V20)
4038
static const uint8_t UP_BTN_PIN = 35;
4139
static const uint8_t BATT_ADC_PIN = 34;
42-
#define UP_BTN_MASK GPIO_SEL_35
4340
#define RTC_TYPE 2 //PCF8563
4441
#endif
4542

46-
#define MENU_BTN_MASK GPIO_SEL_26
47-
#define BACK_BTN_MASK GPIO_SEL_25
48-
#define DOWN_BTN_MASK GPIO_SEL_4
49-
#define ACC_INT_MASK GPIO_SEL_14
43+
#define UP_BTN_MASK (BIT64(UP_BTN_PIN))
44+
#define MENU_BTN_MASK (BIT64(MENU_BTN_PIN))
45+
#define BACK_BTN_MASK (BIT64(BACK_BTN_PIN))
46+
#define DOWN_BTN_MASK (BIT64(DOWN_BTN_PIN))
47+
#define ACC_INT_MASK (BIT64(ACC_INT_1_PIN))
5048
#define BTN_PIN_MASK MENU_BTN_MASK | BACK_BTN_MASK | UP_BTN_MASK | DOWN_BTN_MASK
5149

5250
#endif /* Pins_Arduino_h */

0 commit comments

Comments
 (0)