aboutsummaryrefslogtreecommitdiff
path: root/rmidevice/hiddevice.h
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2022-12-13 20:32:55 +0000
committerElliott Hughes <enh@google.com>2022-12-13 20:36:51 +0000
commit32dc02960117bb47f77713c199f0be3722fd6c48 (patch)
tree22ee0f94f63824c3789dc88130daf46a7cb9a778 /rmidevice/hiddevice.h
parent300225f3e9561e02d6abe8050fb341ee8b4891a3 (diff)
parentf1387312b45de0e3524dc27ccaf806366506f7bb (diff)
downloadrmi4utils-32dc02960117bb47f77713c199f0be3722fd6c48.tar.gz
Upgrade to v1.3.12
This project was upgraded with external_updater. Usage: tools/external_updater/updater.sh update rmi4utils For more info, check https://cs.android.com/android/platform/superproject/+/master:tools/external_updater/README.md Test: TreeHugger Change-Id: I5241a32d6ab4ab3e4b87aebd83ddf3ba7f5a9022
Diffstat (limited to 'rmidevice/hiddevice.h')
-rwxr-xr-xrmidevice/hiddevice.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/rmidevice/hiddevice.h b/rmidevice/hiddevice.h
index b947f62..93b1ed8 100755
--- a/rmidevice/hiddevice.h
+++ b/rmidevice/hiddevice.h
@@ -20,6 +20,7 @@
#include <linux/hidraw.h>
#include <string>
+#include <fstream>
#include <stdint.h>
#include "rmidevice.h"
@@ -41,7 +42,8 @@ public:
m_mode(HID_RMI4_MODE_ATTN_REPORTS),
m_initialMode(HID_RMI4_MODE_MOUSE),
m_transportDeviceName(""),
- m_driverPath("")
+ m_driverPath(""),
+ hasVendorDefineLIDMode(false)
{}
virtual int Open(const char * filename);
virtual int Read(unsigned short addr, unsigned char *buf,
@@ -49,6 +51,7 @@ public:
virtual int Write(unsigned short addr, const unsigned char *buf,
unsigned short len);
virtual int SetMode(int mode);
+ virtual int ToggleInterruptMask(bool enable);
virtual int WaitForAttention(struct timeval * timeout = NULL,
unsigned int source_mask = RMI_INTERUPT_SOURCES_ALL_MASK);
virtual int GetAttentionReport(struct timeval * timeout, unsigned int source_mask,
@@ -87,6 +90,8 @@ private:
std::string m_transportDeviceName;
std::string m_driverPath;
+ bool hasVendorDefineLIDMode;
+
int GetReport(int *reportId, struct timeval * timeout = NULL);
void PrintReport(const unsigned char *report);
void ParseReportDescriptor();