diff options
Diffstat (limited to 'src/drivers/Cst816s.h')
| -rw-r--r-- | src/drivers/Cst816s.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/drivers/Cst816s.h b/src/drivers/Cst816s.h index d4c17bb8..a1c1214e 100644 --- a/src/drivers/Cst816s.h +++ b/src/drivers/Cst816s.h @@ -30,11 +30,20 @@ namespace Pinetime { Cst816S(Cst816S&&) = delete; Cst816S& operator=(Cst816S&&) = delete; - void Init(); + bool Init(); TouchInfos GetTouchInfo(); void Sleep(); void Wakeup(); + uint8_t GetChipId() const { + return chipId; + } + uint8_t GetVendorId() const { + return vendorId; + } + uint8_t GetFwVersion() const { + return fwVersion; + } private: static constexpr uint8_t pinIrq = 28; static constexpr uint8_t pinReset = 10; @@ -55,6 +64,10 @@ namespace Pinetime { uint8_t touchData[7]; TwiMaster& twiMaster; uint8_t twiAddress; + + uint8_t chipId; + uint8_t vendorId; + uint8_t fwVersion; }; } |
