DahuaVTO2MQTT icon indicating copy to clipboard operation
DahuaVTO2MQTT copied to clipboard

Cancel Call - MQTT-Command

Open bazidibavaria opened this issue 3 years ago • 0 comments

Hi,

to stop a call, a new function can be integrated

DAHUA_CONSOLE_RUN_CMD = "console.runCmd"

def console_run_cmd_cancel_call(self):
    _LOGGER.debug("Cancel call")

    def handle_console_run_cmd_cancel_call(message):
        _LOGGER.info(f"Cancel call msg: {message}")

    request_data = {
        "command": "hc"
    }

    self.send(DAHUA_CONSOLE_RUN_CMD, handle_console_run_cmd_cancel_call, request_data)

Additionally a mqtt subscription to an command event should be integrated.

bazidibavaria avatar Oct 15 '21 17:10 bazidibavaria