cec: add GetDeviceCecVersion()/cec_get_device_cec_version() to the interface. mostly...
[deb_libcec.git] / include / cectypes.h
index c08c64d4d4bdcb2d462a1083f4fc13b86e866856..6bad7692c803ff9dd3d7482736b68b55be783147 100644 (file)
@@ -97,13 +97,14 @@ typedef enum
   CEC_TRUE = 1
 } ECecBoolean;
 
-typedef enum
+typedef enum cec_version
 {
-  CEC_VERSION_1_2 = 0x01,
-  CEC_VERSION_1_2A = 0x02,
-  CEC_VERSION_1_3 = 0x03,
-  CEC_VERSION_1_3A = 0x04
-} ECecVersion;
+  CEC_VERSION_UNKNOWN = 0x00,
+  CEC_VERSION_1_2     = 0x01,
+  CEC_VERSION_1_2A    = 0x02,
+  CEC_VERSION_1_3     = 0x03,
+  CEC_VERSION_1_3A    = 0x04
+} cec_version;
 
 typedef enum
 {
@@ -634,6 +635,7 @@ typedef struct cec_command
   cec_opcode          opcode;
   cec_datapacket      parameters;
   int8_t              opcode_set;
+  int32_t             ack_timeout;
 
 #ifdef __cplusplus
   static void format(cec_command &command, cec_logical_address initiator, cec_logical_address destination, cec_opcode opcode)
@@ -643,6 +645,7 @@ typedef struct cec_command
     command.destination = destination;
     command.opcode      = opcode;
     command.opcode_set  = 1;
+    command.ack_timeout = 1000;
   }
 
   void push_back(uint8_t data)
@@ -669,6 +672,7 @@ typedef struct cec_command
     eom         = 0;
     opcode_set  = 0;
     opcode      = CEC_OPCODE_FEATURE_ABORT;
+    ack_timeout = 1000;
     parameters.clear();
   };
 #endif