@@ -78,6 +78,11 @@ bool CVLCommandHandler::InitHandler(void)
78
78
79
79
int CVLCommandHandler::HandleDeviceVendorCommandWithId (const cec_command &command)
80
80
{
81
+ if (command.parameters [0 ] != 0x00 ||
82
+ command.parameters [1 ] != 0x80 ||
83
+ command.parameters [2 ] != 0x45 )
84
+ return CEC_ABORT_REASON_INVALID_OPERAND;
85
+
81
86
if (command.initiator == CECDEVICE_TV &&
82
87
command.destination == CECDEVICE_BROADCAST &&
83
88
command.parameters .At (3 ) == VL_POWER_CHANGE)
@@ -164,3 +169,25 @@ bool CVLCommandHandler::PowerUpEventReceived(void)
164
169
m_bPowerUpEventReceived = (powerStatus == CEC_POWER_STATUS_ON);
165
170
return m_bPowerUpEventReceived;
166
171
}
172
+
173
+ int CVLCommandHandler::HandleVendorCommand (const cec_command &command)
174
+ {
175
+ // some vendor command voodoo that will enable more buttons on the remote
176
+ if (command.parameters .size == 3 &&
177
+ command.parameters [0 ] == 0x10 &&
178
+ command.parameters [1 ] == 0x01 &&
179
+ command.parameters [2 ] == 0x05 )
180
+ {
181
+ cec_command response;
182
+ cec_command::Format (response, command.destination , command.initiator , CEC_OPCODE_VENDOR_COMMAND);
183
+ uint8_t iResponseData[] = {0x10 , 0x02 , 0xFF , 0xFF , 0x00 , 0x05 , 0x05 , 0x45 , 0x55 , 0x5c , 0x58 , 0x32 };
184
+ response.PushArray (12 , iResponseData);
185
+
186
+ Transmit (response, true );
187
+
188
+ return COMMAND_HANDLED;
189
+ }
190
+
191
+ return CEC_ABORT_REASON_INVALID_OPERAND;
192
+ }
193
+
0 commit comments