From 4b627acee6cd9d3c027a27da5b52be74670dd1ca Mon Sep 17 00:00:00 2001 From: jacqueline Date: Fri, 8 Sep 2023 10:24:18 +1000 Subject: [PATCH] Reset the touchwheel during boot --- src/drivers/touchwheel.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/drivers/touchwheel.cpp b/src/drivers/touchwheel.cpp index c617e5df..77b78c23 100644 --- a/src/drivers/touchwheel.cpp +++ b/src/drivers/touchwheel.cpp @@ -38,7 +38,10 @@ TouchWheel::TouchWheel() { }; gpio_config(&int_config); - WriteRegister(LOW_POWER, 1); + WriteRegister(RESET, 1); + while (gpio_get_level(kIntPin)) { + vTaskDelay(pdMS_TO_TICKS(10)); + } // Configure keys 0, 1, and 2 as a wheel. WriteRegister(SLIDER_OPTIONS, 0b11000000);