diff options
| author | JF <jf@codingfield.com> | 2021-11-15 19:50:22 (GMT) |
|---|---|---|
| committer | Gitea <gitea@fake.local> | 2021-11-15 19:50:22 (GMT) |
| commit | cfef0131b7b1bb83c81db417c43d6d499594125f (patch) | |
| tree | f198b2a0fd99f00278316496bf263e85e5338a28 | |
| parent | f6d0ec49e6f2669c64729b081eb3342f02151f4a (diff) | |
| parent | 624429b54c1819d58b69a2f74f5c852e1ecb0ed3 (diff) | |
Merge branch 'develop' of JF/PineTime into master
| -rw-r--r-- | CMakeLists.txt | 2 | ||||
| -rw-r--r-- | src/drivers/Cst816s.cpp | 16 |
2 files changed, 6 insertions, 12 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 63257ff..b588066 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.1 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 4aac19f..bf51a8b 100644 --- a/src/drivers/Cst816s.cpp +++ b/src/drivers/Cst816s.cpp @@ -32,17 +32,11 @@ bool Cst816S::Init() { twiMaster.Read(twiAddress, 0xa7, &dummy, 1); vTaskDelay(5); - static constexpr uint8_t maxRetries = 3; - bool isDeviceOk; - uint8_t retries = 0; - do { - isDeviceOk = CheckDeviceIds(); - retries++; - } while (!isDeviceOk && retries < maxRetries); - - if (!isDeviceOk) { - return false; - } + // TODO This function check that the device IDs from the controller are equal to the ones + // we expect. However, it seems to return false positive (probably in case of communication issue). + // Also, it seems that some users have pinetimes that works correctly but that report different device IDs + // Until we know more about this, we'll just read the IDs but not take any action in case they are not 'valid' + CheckDeviceIds(); /* [2] EnConLR - Continuous operation can slide around |
