From cbcae2ec5414aa9ec8f67b623bc338c73891a640 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-Fran=C3=A7ois=20Milants?= Date: Sun, 14 Nov 2021 14:11:19 +0100 Subject: [PATCH] Revert new data validity check in CST816S that were added in 1.7.0. --- CMakeLists.txt | 2 +- src/drivers/Cst816s.cpp | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 63257ff9..fc1ce2fe 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.10) -project(pinetime VERSION 1.7.0 LANGUAGES C CXX ASM) +project(pinetime VERSION 1.7.99 LANGUAGES C CXX ASM) set(CMAKE_C_STANDARD 99) set(CMAKE_CXX_STANDARD 14) diff --git a/src/drivers/Cst816s.cpp b/src/drivers/Cst816s.cpp index 4aac19f9..3e5389d0 100644 --- a/src/drivers/Cst816s.cpp +++ b/src/drivers/Cst816s.cpp @@ -32,6 +32,7 @@ bool Cst816S::Init() { twiMaster.Read(twiAddress, 0xa7, &dummy, 1); vTaskDelay(5); + /* static constexpr uint8_t maxRetries = 3; bool isDeviceOk; uint8_t retries = 0; @@ -43,6 +44,7 @@ bool Cst816S::Init() { if (!isDeviceOk) { return false; } + */ /* [2] EnConLR - Continuous operation can slide around @@ -86,6 +88,7 @@ Cst816S::TouchInfos Cst816S::GetTouchInfo() { Gestures gesture = static_cast(touchData[gestureIndex]); // Validity check + /* if(x >= maxX || y >= maxY || (gesture != Gestures::None && gesture != Gestures::SlideDown && @@ -98,6 +101,7 @@ Cst816S::TouchInfos Cst816S::GetTouchInfo() { info.isValid = false; return info; } + */ info.x = x; info.y = y;