case CEC_OPCODE_GIVE_AUDIO_STATUS:
HandleGiveAudioStatus(command);
break;
+ case CEC_OPCODE_GIVE_SYSTEM_AUDIO_MODE_STATUS:
+ HandleGiveSystemAudioModeStatus(command);
+ break;
+ case CEC_OPCODE_SYSTEM_AUDIO_MODE_REQUEST:
+ HandleSetSystemAudioModeRequest(command);
+ break;
default:
UnhandledCommand(command);
m_busDevice->GetProcessor()->AddCommand(command);
CCECBusDevice *device = GetDevice(command.initiator);
if (device)
- device->SetPhysicalAddress(iNewAddress, iOldAddress);
+ device->SetStreamPath(iNewAddress, iOldAddress);
}
return true;
}
return true;
}
+bool CCECCommandHandler::HandleSetSystemAudioModeRequest(const cec_command &command)
+{
+ if (command.parameters.size >= 1)
+ {
+ CCECBusDevice *device = GetDevice(command.destination);
+ if (device&& device->GetType() == CEC_DEVICE_TYPE_AUDIO_SYSTEM)
+ return ((CCECAudioSystem *) device)->SetSystemAudioMode(command);
+ }
+ return true;
+}
+
+bool CCECCommandHandler::HandleGiveSystemAudioModeStatus(const cec_command &command)
+{
+ CCECBusDevice *device = GetDevice(command.destination);
+ if (device && device->GetType() == CEC_DEVICE_TYPE_AUDIO_SYSTEM)
+ return ((CCECAudioSystem *) device)->TransmitSystemAudioModeStatus(command.initiator);
+
+ return false;
+}
+
bool CCECCommandHandler::HandleUserControlPressed(const cec_command &command)
{
if (command.parameters.size > 0)