File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ namespace Pinetime {
88 // Pinetime
99 static constexpr uint8_t Charging = 12 ;
1010 static constexpr uint8_t Cst816sReset = 10 ;
11- static constexpr uint8_t Button = 13 ;
11+ static constexpr uint8_t Button = 13 ;
1212 #elif defined(TARGET_DEVICE_P8)
1313 // COLMI P8 and variants
1414 static constexpr uint8_t Charging = 19 ;
@@ -18,6 +18,7 @@ namespace Pinetime {
1818 #error Invalid TARGET_DEVICE
1919 #endif
2020
21+ static constexpr uint8_t ButtonEnable = 15 ;
2122 static constexpr uint8_t Cst816sIrq = 28 ;
2223 static constexpr uint8_t PowerPresent = 19 ;
2324 static constexpr uint8_t Bma421Irq = 8 ;
Original file line number Diff line number Diff line change @@ -179,6 +179,8 @@ void SystemTask::Work() {
179179 pinConfig.is_watcher = false ;
180180
181181 // Button
182+ nrf_gpio_cfg_output (PinMap::ButtonEnable);
183+ nrf_gpio_pin_set (PinMap::ButtonEnable);
182184 pinConfig.sense = NRF_GPIOTE_POLARITY_TOGGLE;
183185 pinConfig.pull = NRF_GPIO_PIN_PULLDOWN;
184186 nrfx_gpiote_in_init (PinMap::Button, &pinConfig, nrfx_gpiote_evt_handler);
You can’t perform that action at this time.
0 commit comments