#define CEC_POWER_STATE_REFRESH_TIME 30000
#define CEC_FW_VERSION_UNKNOWN 0xFFFF
#define CEC_CONNECT_TRIES 3
+#define CEC_PHYSICAL_ADDRESS_TV 0
+#define CEC_MAX_PHYSICAL_ADDRESS 0xFFFE
+#define CEC_INVALID_PHYSICAL_ADDRESS 0xFFFF
#define CEC_DEFAULT_SETTING_USE_TV_MENU_LANGUAGE 1
#define CEC_DEFAULT_SETTING_ACTIVATE_SOURCE 1
#define CEC_DEFAULT_TRANSMIT_WAIT 2000
#define CEC_DEFAULT_TRANSMIT_RETRIES 1
+#define CEC_DEFAULT_CONNECT_TIMEOUT 10000
+#define CEC_DEFAULT_CONNECT_RETRY_WAIT 1000
+#define CEC_SERIAL_DEFAULT_BAUDRATE 38400
+#define CEC_CLEAR_INPUT_DEFAULT_WAIT 1000
+
#define CEC_MIN_LIB_VERSION 1
#define CEC_LIB_VERSION_MAJOR 1
#define CEC_LIB_VERSION_MINOR 6
libcec_configuration(void) { Clear(); }
~libcec_configuration(void) { Clear(); }
+ bool operator==(const libcec_configuration &other) const
+ {
+ return ( clientVersion == other.clientVersion &&
+ !strncmp(strDeviceName, other.strDeviceName, 13) &&
+ deviceTypes == other.deviceTypes &&
+ bAutodetectAddress == other.bAutodetectAddress &&
+ iPhysicalAddress == other.iPhysicalAddress &&
+ baseDevice == other.baseDevice &&
+ iHDMIPort == other.iHDMIPort &&
+ tvVendor == other.tvVendor &&
+ wakeDevices == other.wakeDevices &&
+ powerOffDevices == other.powerOffDevices &&
+ serverVersion == other.serverVersion &&
+ bGetSettingsFromROM == other.bGetSettingsFromROM &&
+ bUseTVMenuLanguage == other.bUseTVMenuLanguage &&
+ bActivateSource == other.bActivateSource &&
+ bPowerOffScreensaver == other.bPowerOffScreensaver &&
+ bPowerOffOnStandby == other.bPowerOffOnStandby &&
+ bSendInactiveSource == other.bSendInactiveSource &&
+ /* libcec 1.5.3+ */
+ (other.serverVersion < CEC_SERVER_VERSION_1_5_3 || logicalAddresses == other.logicalAddresses) &&
+ /* libcec 1.6.0+ */
+ (other.serverVersion < CEC_SERVER_VERSION_1_6_0 || iFirmwareVersion == other.iFirmwareVersion) &&
+ (other.serverVersion < CEC_SERVER_VERSION_1_6_0 || bPowerOffDevicesOnStandby == other.bPowerOffDevicesOnStandby) &&
+ (other.serverVersion < CEC_SERVER_VERSION_1_6_0 || bShutdownOnStandby == other.bShutdownOnStandby) &&
+ /* libcec 1.6.2+ */
+ (other.serverVersion < CEC_SERVER_VERSION_1_6_2 || !strncmp(strDeviceLanguage, other.strDeviceLanguage, 3)) &&
+ (other.serverVersion < CEC_SERVER_VERSION_1_6_2 || iFirmwareBuildDate == other.iFirmwareBuildDate));
+ }
+
+ bool operator!=(const libcec_configuration &other) const
+ {
+ return !(*this == other);
+ }
+
/*!
* @brief Reset this configution struct to the default values.
*/