From 77e388ed2dbbe262e61ddf514f7554e236a1c1a1 Mon Sep 17 00:00:00 2001 From: Szczepan Zalega Date: Fri, 29 Jul 2016 14:26:37 +0200 Subject: Let device identify itself by model Signed-off-by: Szczepan Zalega --- include/device.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/device.h b/include/device.h index 1c95c56..1f6d486 100644 --- a/include/device.h +++ b/include/device.h @@ -19,6 +19,11 @@ enum class CommError { ERR_STATUS_NOT_OK = -4 }; +enum class DeviceModel{ + PRO, + STORAGE +}; + class Device { public: Device(); @@ -45,13 +50,14 @@ class Device { int get_last_command_status() const; void set_last_command_status(uint8_t _err) { last_command_status = _err;} ; bool last_command_sucessfull() const {return last_command_status == 0;}; - + DeviceModel get_device_model() const {return m_model;} private: uint8_t last_command_status; protected: uint16_t m_vid; uint16_t m_pid; + DeviceModel m_model; /* * While the project uses Signal11 portable HIDAPI -- cgit v1.2.3