int64_t iActiveSourcePending /* = 0 */) :
CCECCommandHandler(busDevice, iTransmitTimeout, iTransmitWait, iTransmitRetries, iActiveSourcePending),
m_iPowerUpEventReceived(0),
- m_bCapabilitiesSent(false)
+ m_bCapabilitiesSent(false),
+ m_bPowerStatusRequested(false)
{
m_vendorId = CEC_VENDOR_PANASONIC;
}
return CEC_ABORT_REASON_INVALID_OPERAND;
}
+bool CVLCommandHandler::TransmitRequestPowerStatus(const cec_logical_address iInitiator, const cec_logical_address iDestination, bool bWaitForResponse /* = true */)
+{
+ m_bPowerStatusRequested = true;
+ return CCECCommandHandler::TransmitRequestPowerStatus(iInitiator, iDestination, bWaitForResponse);
+}
+
bool CVLCommandHandler::SourceSwitchAllowed(void)
{
+ if (!PowerUpEventReceived() && !m_bPowerStatusRequested)
+ TransmitRequestPowerStatus(m_processor->GetPrimaryDevice()->GetLogicalAddress(), CECDEVICE_TV, false);
+
return PowerUpEventReceived();
}
bool PowerUpEventReceived(void);
bool SupportsDeviceType(const cec_device_type type) const { return type != CEC_DEVICE_TYPE_RECORDING_DEVICE; };
cec_device_type GetReplacementDeviceType(const cec_device_type type) const { return type == CEC_DEVICE_TYPE_RECORDING_DEVICE ? CEC_DEVICE_TYPE_PLAYBACK_DEVICE : type; }
+ bool TransmitRequestPowerStatus(const cec_logical_address iInitiator, const cec_logical_address iDestination, bool bWaitForResponse = true);
bool SourceSwitchAllowed(void);
PLATFORM::CMutex m_mutex;
uint64_t m_iPowerUpEventReceived;
bool m_bCapabilitiesSent;
+ bool m_bPowerStatusRequested;
};
};