MCPcopy Create free account
hub / github.com/Pulse-Eight/libcec / ProcessCommandON

Function ProcessCommandON

src/cec-client/cec-client.cpp:448–466  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

446}
447
448bool ProcessCommandON(ICECAdapter *parser, const std::string &command, std::string &arguments)
449{
450 if (command == "on")
451 {
452 std::string strValue;
453 uint8_t iValue = 0;
454 if (GetWord(arguments, strValue) && HexStrToInt(strValue, iValue) && iValue <= 0xF)
455 {
456 parser->PowerOnDevices((cec_logical_address) iValue);
457 return true;
458 }
459 else
460 {
461 PrintToStdOut("invalid destination");
462 }
463 }
464
465 return false;
466}
467
468bool ProcessCommandSTANDBY(ICECAdapter *parser, const std::string &command, std::string &arguments)
469{

Callers 1

ProcessConsoleCommandFunction · 0.85

Calls 4

GetWordFunction · 0.85
PrintToStdOutFunction · 0.85
HexStrToIntFunction · 0.70
PowerOnDevicesMethod · 0.45

Tested by

no test coverage detected