From 62311440e856cf6538914f3d7115cabc170d6f81 Mon Sep 17 00:00:00 2001 From: Toni Arte Date: Tue, 7 Feb 2017 12:42:59 +0200 Subject: [PATCH] Add Domoticz 'Voltage' and 'Current' support for EMON --- code/espurna/emon.ino | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/espurna/emon.ino b/code/espurna/emon.ino index 7b9eabf0..62d1abf0 100644 --- a/code/espurna/emon.ino +++ b/code/espurna/emon.ino @@ -171,6 +171,10 @@ void powerMonitorLoop() { char buffer[20]; snprintf(buffer, 20, "%s;%s", power, e); domoticzSend("dczPowIdx", 0, buffer); + snprintf(buffer, 20, "%d", voltage); + domoticzSend("dczVoltIdx", 0, buffer); + snprintf(buffer, 20, "%s", String(current).c_str()); + domoticzSend("dczCurrentIdx", 0, buffer); } #endif