From e16e703663613e5246bb65a4337b04e443cb665b Mon Sep 17 00:00:00 2001 From: Ruben Tacq Date: Mon, 8 Feb 2021 15:02:12 +0100 Subject: [PATCH] parse Packet restore --- lib/parsePacket.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/parsePacket.js b/lib/parsePacket.js index 346e4a2..83f8dbc 100644 --- a/lib/parsePacket.js +++ b/lib/parsePacket.js @@ -139,6 +139,7 @@ function parsePacket(packet) { switch (line.obisCode) { case "1-3:0.2.8": + case "0-0:96.1.4": parsedPacket.version = line.value; break; @@ -320,6 +321,7 @@ function parsePacket(packet) { case "0-2:96.1.0": case "0-3:96.1.0": case "0-4:96.1.0": + case "0-1:96.1.1": parsedPacket.gas.equipmentId = line.value; break; @@ -334,6 +336,14 @@ function parsePacket(packet) { parsedPacket.gas.unit = hourlyReading.unit; break; + case "0-1:24.2.3": + + const instantValue = line.value.substr(15,9); + const instantUnit = line.value.substr(25,2); + parsedPacket.gas.reading = parseFloat(instantValue); + parsedPacket.gas.unit = instantUnit; + break; + case "0-1:24.4.0": case "0-2:24.4.0": case "0-3:24.4.0":