cec: added more audio control commands
[deb_libcec.git] / src / lib / devices / CECBusDevice.cpp
index 665d7fdc893bccc5591887908c80c8d909be3b77..77e646174ba5975df4748429d02ad832885881bf 100644 (file)
@@ -340,7 +340,7 @@ void CCECBusDevice::SetVendorId(uint64_t iVendorId, uint8_t iVendorClass /* = 0
 bool CCECBusDevice::TransmitActiveSource(void)
 {
   CStdString strLog;
-  strLog.Format("<< %x -> broadcast: active source", m_iLogicalAddress);
+  strLog.Format("<< %x -> broadcast: active source (%4x)", m_iLogicalAddress, m_iPhysicalAddress);
   AddLog(CEC_LOG_NOTICE, strLog);
 
   cec_command command;
@@ -354,7 +354,7 @@ bool CCECBusDevice::TransmitActiveSource(void)
 bool CCECBusDevice::TransmitActiveView(void)
 {
   CStdString strLog;
-  strLog.Format("<< %x -> broadcast: active view", m_iLogicalAddress);
+  strLog.Format("<< %x -> broadcast: active view (%4x)", m_iLogicalAddress, m_iPhysicalAddress);
   AddLog(CEC_LOG_NOTICE, strLog);
 
   cec_command command;
@@ -403,7 +403,7 @@ bool CCECBusDevice::TransmitDeckStatus(cec_logical_address dest)
   strLog.Format("<< %x -> %x: deck status feature abort", m_iLogicalAddress, dest);
   AddLog(CEC_LOG_NOTICE, strLog);
 
-  m_processor->TransmitAbort(dest, CEC_OPCODE_GIVE_DEVICE_VENDOR_ID);
+  m_processor->TransmitAbort(dest, CEC_OPCODE_GIVE_DECK_STATUS);
   return false;
 }
 
@@ -481,7 +481,7 @@ bool CCECBusDevice::TransmitPhysicalAddress(void)
   cec_command::format(command, m_iLogicalAddress, CECDEVICE_BROADCAST, CEC_OPCODE_REPORT_PHYSICAL_ADDRESS);
   command.parameters.push_back((uint8_t) ((m_iPhysicalAddress >> 8) & 0xFF));
   command.parameters.push_back((uint8_t) (m_iPhysicalAddress & 0xFF));
-  command.parameters.push_back((uint8_t) (CEC_DEVICE_TYPE_PLAYBACK_DEVICE));
+  command.parameters.push_back((uint8_t) (m_type));
 
   return m_processor->Transmit(command);
 }