From 94a658cecd5016decfbf269dcb4b80ee162b78cb Mon Sep 17 00:00:00 2001 From: foxthefox <16841643+foxthefox@users.noreply.github.com> Date: Thu, 2 Jan 2025 15:28:03 +0100 Subject: [PATCH 1/3] 1.1.0 --- LICENSE | 2 +- README.md | 10 +- admin/jsonConfig.json | 241 ++++- doc/devices/alternator.md | 48 + doc/devices/delta.md | 2 +- doc/devices/delta2.md | 10 +- doc/devices/delta2max.md | 10 +- doc/devices/deltamax.md | 2 +- doc/devices/deltamini.md | 2 +- doc/devices/deltapro.md | 2 +- doc/devices/deltaproultra.md | 12 +- doc/devices/generator.md | 2 +- doc/devices/glacier.md | 2 +- doc/devices/panel.md | 2 +- doc/devices/panel2.md | 60 +- doc/devices/plug.md | 2 +- doc/devices/powerkit.md | 2 +- doc/devices/powerocean.md | 2 +- doc/devices/pstream600.md | 2 +- doc/devices/river2max.md | 10 +- doc/devices/river2pro.md | 10 +- doc/devices/rivermax.md | 10 +- doc/devices/riverpro.md | 10 +- doc/devices/shelly3em.md | 2 +- doc/devices/wave2.md | 2 +- io-package.json | 608 +++++------ lib/ecoflow_data.js | 1971 ++++------------------------------ lib/ecoflow_utils.js | 186 +++- lib/ef_alternator_data.js | 279 +++++ lib/ef_dpu_data.js | 1708 +++++++++++++++++++++++++++++ lib/ef_shp2_data.js | 339 +++++- lib/gen_docs.js | 17 +- main.js | 144 ++- package.json | 2 +- 34 files changed, 3528 insertions(+), 2185 deletions(-) create mode 100644 doc/devices/alternator.md create mode 100644 lib/ef_alternator_data.js create mode 100644 lib/ef_dpu_data.js diff --git a/LICENSE b/LICENSE index ff41d47..10c1661 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2023-2024 foxthefox +Copyright (c) 2023-2025 foxthefox Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 81c1a83..37e00bf 100644 --- a/README.md +++ b/README.md @@ -303,6 +303,13 @@ Wave is not available, could be implemented, if data is available. ## Changelog +### 1.1.0 (npm) +* (foxthefox) #168 changed SHP2 masterIncreInfo.gridSta '0': 'Grid volt. not detected', '1': 'Grid OK' +* (foxthefox) #173 DPU added additional battery selection +* (foxthefox) #174 SHP2 added in ProtoTime the wattInfoChWatt, wattInfoAllHallWatt +* (foxthefox) #174 SHP2 added channel values of power and current in loadPower/loadCurrent including the sum of the values +* (foxthefox) #167 DELTA2/2Max pd.dsgPowerAC and pd.dsgPowerDC (type from 'power' to 'energy') + ### 1.0.5 (npm) * (foxthefox) mppt.outWatts 500 -> 600; inverter_heartbeat.invOutputWatts 800 -> 810 * (foxthefox) update of Readme (adapter now in stable) @@ -318,7 +325,6 @@ Wave is not available, could be implemented, if data is available. * (foxthefox) 'Backup reserve' option added for D2M #137 * (foxthefox) preparations for DeltaPro3 decode - ### 1.0.2 (npm) * (foxthefox) correction of SHP commands (#130) @@ -566,7 +572,7 @@ Wave is not available, could be implemented, if data is available. ## License MIT License -Copyright (c) 2023-2024 foxthefox +Copyright (c) 2023-2025 foxthefox Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/admin/jsonConfig.json b/admin/jsonConfig.json index e56c7e6..cb2aa35 100644 --- a/admin/jsonConfig.json +++ b/admin/jsonConfig.json @@ -23,13 +23,23 @@ "userName": { "type": "text", "label": "ecoflow account name / email ", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "userPassword": { "type": "password", "visible": true, "label": "user password", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "_create": { "type": "sendTo", @@ -37,7 +47,12 @@ "command": "create", "variant": "outlined", "jsonData": "{\"user\": \"${data.userName}\", \"pass\": \"${data.userPassword}\"}", - "useNative": true + "useNative": true, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "_connection": { "newLine": true, @@ -53,12 +68,22 @@ "mqttUrl": { "type": "text", "label": "mqtt broker", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "mqttPort": { "type": "text", "label": "mqtt port", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "_auth": { "newLine": true, @@ -128,7 +153,12 @@ "label": "Test connection", "command": "test", "variant": "contained", - "jsonData": "{\"user\": \"${data.mqttUserName}\", \"pass\": \"${data.mqttPwd}\", \"url\": \"${data.mqttUrl}\", \"port\": ${data.mqttPort}, \"clientId\": \"${data.mqttClientId}\"}" + "jsonData": "{\"user\": \"${data.mqttUserName}\", \"pass\": \"${data.mqttPwd}\", \"url\": \"${data.mqttUrl}\", \"port\": ${data.mqttPort}, \"clientId\": \"${data.mqttClientId}\"}", + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "_debugcommon": { "newLine": true, @@ -156,7 +186,12 @@ "label": "Debug Quotas (JSON)", "command": "quotajson", "variant": "contained", - "jsonData": "{\"quota\": \"now\"}" + "jsonData": "{\"quota\": \"now\"}", + "xs": 12, + "sm": 12, + "md": 6, + "lg": 4, + "xl": 4 }, "getQuota2": { "type": "sendTo", @@ -164,7 +199,12 @@ "label": "Debug Quotas (buffer)", "command": "quotabuf", "variant": "contained", - "jsonData": "{\"quota\": \"now\"}" + "jsonData": "{\"quota\": \"now\"}", + "xs": 12, + "sm": 12, + "md": 6, + "lg": 4, + "xl": 4 }, "_debugoptions": { "newLine": true, @@ -180,7 +220,12 @@ "_introDebug": { "type": "staticText", "text": "If you are unsure, tick all checkboxes for all debug messages. (it is only effective when the adapter is in debug mode (see header of this admin page and the far right setting))", - "newLine": true + "newLine": true, + "xs": 12, + "sm": 12, + "md": 12, + "lg": 12, + "xl": 12 }, "msgUpdate": { "newLine": true, @@ -242,7 +287,11 @@ "newLine": true }, "pstreams": { + "xs": 12, "sm": 12, + "md": 12, + "lg": 12, + "xl": 12, "newLine": true, "type": "table", "items": [ @@ -315,7 +364,11 @@ "newLine": true }, "pstations": { + "xs": 12, "sm": 12, + "md": 12, + "lg": 12, + "xl": 12, "newLine": true, "type": "table", "items": [ @@ -383,7 +436,7 @@ "type": "checkbox", "title": "Slave 1", "width": "5%", - "hidden": "data.devType !== 'deltapro' && data.devType !== 'deltamax' && data.devType !== 'delta2max' && data.devType !== 'delta' && data.devType !== 'delta2'", + "hidden": "data.devType !== 'deltapro' && data.devType !== 'deltamax' && data.devType !== 'delta2max' && data.devType !== 'delta' && data.devType !== 'delta2' && data.devType !== 'deltaproultra'", "attr": "pstationsSlave1", "filter": false, "sort": false, @@ -393,7 +446,7 @@ "type": "checkbox", "title": "Slave 2", "width": "5%", - "hidden": "data.devType !== 'deltapro' && data.devType !== 'deltamax' && data.devType !== 'delta2max' ", + "hidden": "data.devType !== 'deltapro' && data.devType !== 'deltamax' && data.devType !== 'delta2max' && data.devType !== 'deltaproultra'", "attr": "pstationsSlave2", "filter": false, "sort": false, @@ -418,7 +471,11 @@ "newLine": true }, "plugs": { + "xs": 12, "sm": 12, + "md": 12, + "lg": 12, + "xl": 12, "newLine": true, "type": "table", "items": [ @@ -940,7 +997,11 @@ "newLine": true }, "poweroceans": { + "xs": 12, "sm": 12, + "md": 12, + "lg": 12, + "xl": 12, "newLine": true, "type": "table", "items": [ @@ -1012,6 +1073,134 @@ "default": false } ] + }, + "_alternatorHeader": { + "newLine": true, + "type": "header", + "text": "Alternator Configuration", + "xs": 12, + "sm": 12, + "md": 12, + "lg": 12, + "xl": 12, + "size": 3 + }, + "_alternatorTable1Txt1": { + "type": "staticText", + "text": "Please add (+) a device and configure it with its name, Serial Number (id) and it's type. If you have no device, delete the added line item", + "newLine": true + }, + "alternators": { + "sm": 12, + "newLine": true, + "type": "table", + "items": [ + { + "type": "text", + "width": "15%", + "title": "name", + "attr": "devName", + "filter": false, + "sort": false, + "default": "My Alternator1" + }, + { + "type": "text", + "width": "15%", + "title": "id", + "attr": "devId", + "filter": false, + "sort": false, + "default": "F37.." + }, + { + "type": "select", + "width": "10%", + "options": [ + { "value": "none", "label": "none" }, + { "value": "alternator", "label": "Alternator 800W" } + ], + "title": "Alternator Type", + "attr": "devType", + "filter": false, + "sort": false, + "default": "none" + }, + { + "type": "checkbox", + "title": "debug enable", + "width": "5%", + "attr": "debugEnable", + "filter": false, + "sort": false, + "default": false + } + ] + }, + "_unknownHeader": { + "newLine": true, + "type": "header", + "text": "Configuration for not yet supported devices for debugging", + "xs": 12, + "sm": 12, + "md": 12, + "lg": 12, + "xl": 12, + "size": 3 + }, + "_unknownTable1Txt1": { + "type": "staticText", + "text": "Please add (+) a device and configure it with its name, Serial Number (id) and it's type. If you have no device, delete the added line item", + "newLine": true + }, + "unknowns": { + "sm": 12, + "newLine": true, + "type": "table", + "items": [ + { + "type": "text", + "width": "15%", + "title": "name", + "attr": "devName", + "filter": false, + "sort": false, + "default": "Device 1" + }, + { + "type": "text", + "width": "15%", + "title": "id", + "attr": "devId", + "filter": false, + "sort": false, + "default": "MR51.." + }, + { + "type": "select", + "width": "10%", + "options": [ + { "value": "none", "label": "none" }, + { "value": "deltapro3", "label": "Delta Pro 3" }, + { "value": "delta3", "label": "Delta 3" }, + { "value": "delta3plus", "label": "Delta 3 Plus" } + ], + "title": "Alternator Type", + "attr": "devType", + "filter": false, + "sort": false, + "default": "none" + }, + { + "type": "checkbox", + "title": "debug enable", + "width": "5%", + "attr": "debugEnable", + "filter": false, + "sort": false, + "default": true + } + ] } } }, @@ -1037,28 +1226,48 @@ "xs": 12, "sm": 12, "md": 6, - "lg": 4, + "lg": 6, "xl": 4 }, "haMqttProtocol": { "type": "text", "label": "HA mqtt protocol", - "newLine": true + "newLine": true, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "haMqttUrl": { "type": "text", "label": "HA mqtt Url", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "haMqttPort": { "type": "text", "label": "HA mqtt port", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "haTopic": { "type": "text", "label": "HA topic prefix", - "newLine": false + "newLine": false, + "xs": 12, + "sm": 12, + "md": 6, + "lg": 6, + "xl": 4 }, "_auth": { "newLine": true, diff --git a/doc/devices/alternator.md b/doc/devices/alternator.md new file mode 100644 index 0000000..394e83f --- /dev/null +++ b/doc/devices/alternator.md @@ -0,0 +1,48 @@ +# States for ALTERNATOR +### version: 1.1.0 + +[alternatorHeartbeat](#alternatorHeartbeat) + + + +## alternatorHeartbeat + +### string + +| State | Name | +|----------|------| +|status1| X_status1 | +|unknown130| X_unknown130 | +|unknown427| X_unknown427 | +|unknown428| X_unknown428 | +|unknown608| X_unknown608 | +|unknown609| X_unknown609 | + +### number +| State | Min | Max | Unit | Mult | Name | +|----------|:-------------:|:-------------:|:------:|:-----:|-----| +|temp|0 | 80 | °C | 1 | Temperature | +|actPower|0 | 800 | W | 1 | Alternator actual power | +|carBatVolt|10 | 30 | V | 1 | Car battery voltage | +|batSoc|0 | 100 | % | 1 | Powerstation battery state of charge | +|unknown268|0 | 144000 | min | 1 | Battery Charging Time | +|unknown269|0 | 144000 | min | 1 | Battery Discharging Time | +|current425|0 | 30 | A | 0.001 | current | +|wifiRssi|-90 | 10 | dBm | 1 | Wifi RSSI | +|ratedPower|0 | 800 | W | 1 | Alternator rated power | + + +### level + +| State | Min | Max | Unit | Mult | Name | cmd | +|----------|:-------------:|:-------------:|:------:|:-----:|-----|------| +|startVoltage| 11 | 30 | V | 0.1 | Start voltage | {dest:20,cmdFunc:2,cmdId:17,dataLen:6} | +|operationMode| 1 | 3 | | 1 | Operation mode | {dest:20,cmdFunc:2,cmdId:17,dataLen:6} | +|permanentWatts| 0 | 800 | W | 1 | Permanent Power Limit | {dest:20,cmdFunc:2,cmdId:17,dataLen:6} | + +### switch + +| State | off | on | Name | cmd | +|----------|:-------------:|:------:|------|------| +|startStop| off | on | Start/Stop cmd | {dest:20,cmdFunc:2,cmdId:17,dataLen:6} | + diff --git a/doc/devices/delta.md b/doc/devices/delta.md index 2fe4d57..ea61caf 100644 --- a/doc/devices/delta.md +++ b/doc/devices/delta.md @@ -1,5 +1,5 @@ # States for DELTA -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) diff --git a/doc/devices/delta2.md b/doc/devices/delta2.md index 56f962c..aed7b4b 100644 --- a/doc/devices/delta2.md +++ b/doc/devices/delta2.md @@ -1,5 +1,5 @@ # States for DELTA2 -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) @@ -262,10 +262,10 @@ |wattsInSum|0 | 4000 | W | 1 | Total input power | |wattsOutSum|0 | 4000 | W | 1 | Total output power | |acAutoOutPause|0 | 255 | s (0-255?) | 1 | AC Auto out Pause | -|chgPowerAC|0 | 65000 | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | -|chgPowerDC|0 | 65000 | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | -|dsgPowerAC|0 | 4000 | W | 0.1 | Discharge Power AC | -|dsgPowerDC|0 | 4000 | W | 0.1 | Discharge Power DC | +|chgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | +|chgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | +|dsgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power discharged | +|dsgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC discharge capacity | |inWatts|0 | 500 | W | 0.1 | PD? input power | |inputWatts|0 | 4000 | W | 0.1 | Input power | |outWatts|0 | 500 | W | 0.1 | PD? output power | diff --git a/doc/devices/delta2max.md b/doc/devices/delta2max.md index 601ae30..e323a28 100644 --- a/doc/devices/delta2max.md +++ b/doc/devices/delta2max.md @@ -1,5 +1,5 @@ # States for DELTA2MAX -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) @@ -285,12 +285,12 @@ |carTemp|0 | 80 | °C | 1 | CAR temperature | |carUsedTime|0 | 9999999 | min | 0.0166 | Car use time | |carWatts|0 | 500 | W | 0.1 | CAR output power | -|chgPowerAC|0 | 65000 | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | -|chgPowerDC|0 | 65000 | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | +|chgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | +|chgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | |chgSunPower|0 | 65000 | kWh | 0.001 | Cumulative solar power charged | |dcInUsedTime|0 | 9999999 | min | 0.0166 | DC charging time | -|dsgPowerAC|0 | 4000 | W | 0.001 | Discharge Power AC | -|dsgPowerDC|0 | 4000 | W | 0.1 | Discharge Power DC | +|dsgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power discharged | +|dsgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC discharge capacity | |invUsedTime|0 | 9999999 | min | 0.0166 | Inverter use time | |mpptUsedTime|0 | 9999999 | min | 0.0166 | MPPT use time | |qcUsb1Watts|0 | 500 | W | 1 | Quick charge usb1 output power | diff --git a/doc/devices/deltamax.md b/doc/devices/deltamax.md index 1d485b2..2c5636b 100644 --- a/doc/devices/deltamax.md +++ b/doc/devices/deltamax.md @@ -1,5 +1,5 @@ # States for DELTAMAX -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) diff --git a/doc/devices/deltamini.md b/doc/devices/deltamini.md index d1174cd..8a71a9a 100644 --- a/doc/devices/deltamini.md +++ b/doc/devices/deltamini.md @@ -1,5 +1,5 @@ # States for DELTAMINI -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) diff --git a/doc/devices/deltapro.md b/doc/devices/deltapro.md index 653f683..7607bac 100644 --- a/doc/devices/deltapro.md +++ b/doc/devices/deltapro.md @@ -1,5 +1,5 @@ # States for DELTAPRO -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) diff --git a/doc/devices/deltaproultra.md b/doc/devices/deltaproultra.md index f89bafe..7fddb33 100644 --- a/doc/devices/deltaproultra.md +++ b/doc/devices/deltaproultra.md @@ -1,5 +1,5 @@ # States for DELTAPROULTRA -### version: 1.0.5 +### version: 1.1.0 [AppParaHeartbeatReport](#AppParaHeartbeatReport) @@ -80,7 +80,7 @@ |----------|:-------------:|:-------------:|:------:|:-----:|-----| |showFlag|0 | n/a | | 1 | show flag | |soc|0 | 100 | % | 1 | SOC | -|bpNum|0 | 5 | | 1 | Baiiery pack count | +|bpNum|0 | 5 | | 1 | Battery pack count | |c20ChgMaxWatts|0 | 7200 | W | 1 | Max charging power AC IN | |paraChgMaxWatts|0 | 7200 | W | 1 | Max parallel charging power | |remainTime|0 | n/a | min | 1 | Remaining time | @@ -100,7 +100,7 @@ |outAcTtPwr|0 | 3600 | W | 1 | Output power UPS TT-30 | |outAcL14Pwr|0 | 4800 | W | 1 | Output power Backup L-14 | |outAc_5p8Pwr|0 | 3600 | W | 1 | Output power Power I/O | -|inAc_5p8Pwr|0 | 3600 | W | 1 | Input power Power I/O | +|inAc_5p8Pwr|0 | 7200 | W | 1 | Input power Power I/O | |inAcC20Pwr|0 | 2800 | W | 1 | Input power AC IN | |inLvMpptPwr|0 | 1600 | W | 1 | LV solar power input | |inHvMpptPwr|0 | 4000 | W | 1 | HV solar power input | @@ -166,7 +166,7 @@ |emsMaxAvailNum|0 | 5 | pcs | 1 | EMS max avail. number | |emsParaVolMin|0 | 120 | V | 0.001 | Minimum parallel voltage | |emsParaVolMax|0 | 120 | V | 0.001 | Maximum parallel voltage | -|acOutFreq|50 | 60 | Hz | 1 | AC output frequency | +|acOutFreq|0 | 60 | Hz | 1 | AC output frequency | |batVol|0 | 120 | V | 1 | Battery voltage | |batAmp|0 | 60 | A | 1 | Battery current | |bmsInputWatts|0 | 7200 | W | 1 | BMS input power | @@ -195,8 +195,8 @@ |outAcL14Amp|0 | 20 | A | 1 | Output current Backup L-14 | |outAc_5p8Vol|0 | 250 | V | 1 | Output voltage PowerI/O | |outAc_5p8Amp|0 | 30 | A | 1 | Output current PowerI/O | -|inAc_5p8Vol|0 | 250 | V | 1 | Input voltage PowerI/O | -|inAc_5p8Amp|0 | 30 | V | 1 | Input current PowerI/O | +|inAc_5p8Vol|0 | 260 | V | 1 | Input voltage PowerI/O | +|inAc_5p8Amp|0 | 31 | A | 1 | Input current PowerI/O | |inAcC20Vol|0 | 250 | V | 1 | Input voltage AC IN | |inAcC20Amp|0 | 20 | A | 1 | Input current AC IN | |inLvMpptVol|0 | 150 | V | 1 | LV solar input voltage | diff --git a/doc/devices/generator.md b/doc/devices/generator.md index 1fa812d..bcd05ef 100644 --- a/doc/devices/generator.md +++ b/doc/devices/generator.md @@ -1,5 +1,5 @@ # States for GENERATOR -### version: 1.0.5 +### version: 1.1.0 [oil](#oil) diff --git a/doc/devices/glacier.md b/doc/devices/glacier.md index 3add7a3..b421f7e 100644 --- a/doc/devices/glacier.md +++ b/doc/devices/glacier.md @@ -1,5 +1,5 @@ # States for GLACIER -### version: 1.0.5 +### version: 1.1.0 [pd](#pd) diff --git a/doc/devices/panel.md b/doc/devices/panel.md index 71f85d4..45f7cb9 100644 --- a/doc/devices/panel.md +++ b/doc/devices/panel.md @@ -1,5 +1,5 @@ # States for PANEL -### version: 1.0.5 +### version: 1.1.0 [heartbeat](#heartbeat) diff --git a/doc/devices/panel2.md b/doc/devices/panel2.md index 7580eec..cd54ce3 100644 --- a/doc/devices/panel2.md +++ b/doc/devices/panel2.md @@ -1,5 +1,5 @@ # States for PANEL2 -### version: 1.0.5 +### version: 1.1.0 [ProtoTime](#ProtoTime) @@ -29,6 +29,10 @@ [LoadStrategyCfg](#LoadStrategyCfg) +[loadCurrent](#loadCurrent) + +[loadPower](#loadPower) + ## ProtoTime @@ -36,14 +40,16 @@ ### number | State | Min | Max | Unit | Mult | Name | |----------|:-------------:|:-------------:|:------:|:-----:|-----| -|master_gridWatt|0 | 12000 | W | 1 | Backup charge power | +|master_gridWatt|0 | 12000 | W | 1 | Master grid power | |bkpChWatt|0 | 7200 | W | 1 | Backup charge power | |backupDischargeTime|0 | 30000 | min | 1 | Backup discharge time | |bkpEnerg1ChargeTime|0 | 30000 | min | 1 | Backup Energy#1 charge time | |bkpEnerg1DischargeTime|0 | 30000 | min | 1 | Backup Energy#1 discharge time | -|bkpEnerg2ChargeTime|0 | 30000 | min | 1 | Backup Energy#1 charge time | -|bkpEnerg2DischargeTime|0 | 30000 | min | 1 | Backup Energy#1 discharge time | -|wattInfoGridWatt|0 | 12000 | W | 1 | Power info | +|bkpEnerg2ChargeTime|0 | 30000 | min | 1 | Backup Energy#2 charge time | +|bkpEnerg2DischargeTime|0 | 30000 | min | 1 | Backup Energy#2 discharge time | +|wattInfoGridWatt|0 | 12000 | W | 1 | Power info grid | +|wattInfoChWatt|0 | 12000 | W | 1 | Power info channel | +|wattInfoAllHallWatt|0 | 12000 | W | 1 | Power info all hall | ### string @@ -88,7 +94,7 @@ | State | Name | values | |----------|:-------------:|------| |productType| Product type | {1:SHP2?} | -|powerSta| Power Status | {0:feeding loads?,1:standby?,2:charging?,3:error?} | +|powerSta| Power Status | {0:LOAD_CH_EG_POWER,1:LOAD_CH_ES_POWER,2:LOAD_CH_OIL_POWER,3:LOAD_CH_STOP_EM,4:LOAD_CH_OFF_POWER} | |isSetOilEngine| isSetOilEngine | {0:no generator?,1:generator?} | |isAreaErr| Area error | {0:OK?,1:Error?} | |ch1ForceCharge| Ch1 force charging | {0:normal?,1:forced?} | @@ -507,7 +513,7 @@ | State | Name | values | |----------|:-------------:|------| -|gridSta| Grid status | {0:Grid OK?,1:Grid overvolt./overfreq?,2:Grid volt. not detected?} | +|gridSta| Grid status | {0:Grid volt. not detected,1:Grid OK,2:Grid overvolt./overfreq} | |masterRlyErrFlg| Master Relay Error Flag | {0:OK?,1:Error?} | ### number @@ -567,3 +573,43 @@ |loadPriority12|0 | n/a | | 1 | Channel #12 load priority | +## loadCurrent + +### number +| State | Min | Max | Unit | Mult | Name | +|----------|:-------------:|:-------------:|:------:|:-----:|-----| +|cur_0|0 | 30 | A | 1 | Channel #1 current | +|cur_1|0 | 30 | A | 1 | Channel #2 current | +|cur_2|0 | 30 | A | 1 | Channel #3 current | +|cur_3|0 | 30 | A | 1 | Channel #4 current | +|cur_4|0 | 30 | A | 1 | Channel #5 current | +|cur_5|0 | 30 | A | 1 | Channel #6 current | +|cur_6|0 | 30 | A | 1 | Channel #7 current | +|cur_7|0 | 30 | A | 1 | Channel #8 current | +|cur_8|0 | 30 | A | 1 | Channel #9 current | +|cur_9|0 | 30 | A | 1 | Channel #10 current | +|cur_10|0 | 30 | A | 1 | Channel #11 current | +|cur_11|0 | 30 | A | 1 | Channel #12 current | +|sumCur|0 | 30 | A | 1 | Total Load Current | + + +## loadPower + +### number +| State | Min | Max | Unit | Mult | Name | +|----------|:-------------:|:-------------:|:------:|:-----:|-----| +|chWatt_0|0 | 3600 | W | 1 | Power channel #1 | +|chWatt_1|0 | 3600 | W | 1 | Power channel #2 | +|chWatt_2|0 | 3600 | W | 1 | Power channel #3 | +|chWatt_3|0 | 3600 | W | 1 | Power channel #4 | +|chWatt_4|0 | 3600 | W | 1 | Power channel #5 | +|chWatt_5|0 | 3600 | W | 1 | Power channel #6 | +|chWatt_6|0 | 3600 | W | 1 | Power channel #7 | +|chWatt_7|0 | 3600 | W | 1 | Power channel #8 | +|chWatt_8|0 | 3600 | W | 1 | Power channel #9 | +|chWatt_9|0 | 3600 | W | 1 | Power channel #10 | +|chWatt_10|0 | 3600 | W | 1 | Power channel #11 | +|chWatt_11|0 | 3600 | W | 1 | Power channel #12 | +|sumWatt|0 | 10000 | W | 1 | Total Load Power | + + diff --git a/doc/devices/plug.md b/doc/devices/plug.md index ef93070..52ae3aa 100644 --- a/doc/devices/plug.md +++ b/doc/devices/plug.md @@ -1,5 +1,5 @@ # States for PLUG -### version: 1.0.5 +### version: 1.1.0 [plug_heartbeat](#plug_heartbeat) diff --git a/doc/devices/powerkit.md b/doc/devices/powerkit.md index 2df2310..709b4b0 100644 --- a/doc/devices/powerkit.md +++ b/doc/devices/powerkit.md @@ -1,5 +1,5 @@ # States for POWERKIT -### version: 1.0.5 +### version: 1.1.0 [bp1](#bp1) diff --git a/doc/devices/powerocean.md b/doc/devices/powerocean.md index 6f7ec5f..cb74050 100644 --- a/doc/devices/powerocean.md +++ b/doc/devices/powerocean.md @@ -1,5 +1,5 @@ # States for POWEROCEAN -### version: 1.0.5 +### version: 1.1.0 [statusReportBattery1](#statusReportBattery1) diff --git a/doc/devices/pstream600.md b/doc/devices/pstream600.md index 3841509..ac44849 100644 --- a/doc/devices/pstream600.md +++ b/doc/devices/pstream600.md @@ -1,5 +1,5 @@ # States for PSTREAM -### version: 1.0.5 +### version: 1.1.0 [inverter_heartbeat](#inverter_heartbeat) diff --git a/doc/devices/river2max.md b/doc/devices/river2max.md index 3ee60b3..db11699 100644 --- a/doc/devices/river2max.md +++ b/doc/devices/river2max.md @@ -1,5 +1,5 @@ # States for RIVER2MAX -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) @@ -233,12 +233,12 @@ |carTemp|0 | 80 | °C | 1 | CAR temperature | |carUsedTime|0 | 9999999 | min | 0.0166 | Car use time | |carWatts|0 | 500 | W | 0.1 | CAR output power | -|chgPowerAC|0 | 65000 | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | -|chgPowerDC|0 | 65000 | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | +|chgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | +|chgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | |chgSunPower|0 | 65000 | kWh | 0.001 | Cumulative solar power charged | |dcInUsedTime|0 | 9999999 | min | 0.0166 | DC charging time | -|dsgPowerAC|0 | 4000 | W | 0.001 | Discharge Power AC | -|dsgPowerDC|0 | 4000 | W | 0.1 | Discharge Power DC | +|dsgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power discharged | +|dsgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC discharge capacity | |invUsedTime|0 | 9999999 | min | 0.0166 | Inverter use time | |minAcoutSoc|0 | 255 | % (0-255?) | 1 | minimum AC out SOC | |mpptUsedTime|0 | 9999999 | min | 0.0166 | MPPT use time | diff --git a/doc/devices/river2pro.md b/doc/devices/river2pro.md index 6f6449b..9d1ceaa 100644 --- a/doc/devices/river2pro.md +++ b/doc/devices/river2pro.md @@ -1,5 +1,5 @@ # States for RIVER2PRO -### version: 1.0.5 +### version: 1.1.0 [pd](#pd) @@ -22,8 +22,8 @@ |qcUsb1Watts|0 | 500 | W | 1 | Quick charge usb1 output power | |wattsInSum|0 | 660 | W | 1 | Total input power | |dcInUsedTime|0 | 9999999 | min | 0.0166 | DC charging time | -|dsgPowerDC|0 | 4000 | W | 0.1 | Discharge Power DC | -|chgPowerDC|0 | 65000 | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | +|dsgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC discharge capacity | +|chgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | |remainTime|0 | 143999 | min | 1 | Time remaining (min) > 0: remaining charging time; time remaining (min) < 0: remaining discharging time | |typecUsedTime|0 | 9999999 | min | 0.0166 | Type-C use time | |typec2Watts|0 | 500 | W | 1 | Typec2 output power | @@ -34,9 +34,9 @@ |usbUsedTime|0 | 9999999 | min | 0.0166 | USB use time | |mpptUsedTime|0 | 9999999 | min | 0.0166 | MPPT use time | |usb1Watts|0 | 500 | W | 1 | Common usb1 output power | -|dsgPowerAC|0 | 4000 | W | 0.001 | Discharge Power AC | +|dsgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power discharged | |qcUsb2Watts|0 | 500 | W | 0.1 | Quick charge usb2 output power | -|chgPowerAC|0 | 65000 | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | +|chgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | |carWatts|0 | 500 | W | 0.1 | CAR output power | |typec2Temp|0 | 80 | °C | 1 | Type-C 2 temperature | |carUsedTime|0 | 9999999 | min | 0.0166 | Car use time | diff --git a/doc/devices/rivermax.md b/doc/devices/rivermax.md index 0815002..32d4a49 100644 --- a/doc/devices/rivermax.md +++ b/doc/devices/rivermax.md @@ -1,5 +1,5 @@ # States for RIVERMAX -### version: 1.0.5 +### version: 1.1.0 [inv](#inv) @@ -101,8 +101,8 @@ |----------|:-------------:|:-------------:|:------:|:-----:|-----| |wattsInSum|0 | 500 | W | 1 | Total input power | |dcInUsedTime|0 | 9999999 | min | 0.0166 | DC charging time | -|chgPowerDC|0 | 65000 | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | -|dsgPowerDC|0 | 4000 | W | 0.1 | Discharge Power DC | +|chgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | +|dsgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC discharge capacity | |remainTime|0 | 143999 | min | 1 | Time remaining (min) > 0: remaining charging time; time remaining (min) < 0: remaining discharging time | |usb3Watts|0 | 500 | W | 0.1 | Common usb3 output power | |typecUsedTime|0 | 9999999 | min | 0.0166 | Type-C use time | @@ -115,8 +115,8 @@ |mpptUsedTime|0 | 9999999 | min | 0.0166 | MPPT use time | |ledWatts|0 | 100 | W | 0.1 | LED output power | |usb1Watts|0 | 500 | W | 1 | Common usb1 output power | -|dsgPowerAC|0 | 4000 | W | 0.001 | Discharge Power AC | -|chgPowerAC|0 | 65000 | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | +|dsgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power discharged | +|chgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | |carWatts|0 | 500 | W | 0.1 | CAR output power | |carUsedTime|0 | 9999999 | min | 0.0166 | Car use time | |usb2Watts|0 | 500 | W | 1 | Common usb2 output power | diff --git a/doc/devices/riverpro.md b/doc/devices/riverpro.md index 873a28c..01ddee0 100644 --- a/doc/devices/riverpro.md +++ b/doc/devices/riverpro.md @@ -1,5 +1,5 @@ # States for RIVERPRO -### version: 1.0.5 +### version: 1.1.0 [bmsMaster](#bmsMaster) @@ -118,12 +118,12 @@ |carTemp|0 | 80 | °C | 1 | CAR temperature | |carUsedTime|0 | 9999999 | min | 0.0166 | Car use time | |carWatts|0 | 500 | W | 0.1 | CAR output power | -|chgPowerAC|0 | 65000 | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | -|chgPowerDC|0 | 65000 | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | +|chgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power charged for PD (wall socket) | +|chgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC power charged for PD (adapter) | |chgSunPower|0 | 65000 | kWh | 0.001 | Cumulative solar power charged | |dcInUsedTime|0 | 9999999 | min | 0.0166 | DC charging time | -|dsgPowerAC|0 | 4000 | W | 0.001 | Discharge Power AC | -|dsgPowerDC|0 | 4000 | W | 0.1 | Discharge Power DC | +|dsgPowerAC|0 | n/a | kWh | 0.001 | Cumulative AC power discharged | +|dsgPowerDC|0 | n/a | kWh | 0.001 | Cumulative DC discharge capacity | |invUsedTime|0 | 9999999 | min | 0.0166 | Inverter use time | |mpptUsedTime|0 | 9999999 | min | 0.0166 | MPPT use time | |remainTime|0 | 143999 | min | 1 | Time remaining (min) > 0: remaining charging time; time remaining (min) < 0: remaining discharging time | diff --git a/doc/devices/shelly3em.md b/doc/devices/shelly3em.md index 9a9600d..8c690a1 100644 --- a/doc/devices/shelly3em.md +++ b/doc/devices/shelly3em.md @@ -1,5 +1,5 @@ # States for SHELLY3EM -### version: 1.0.5 +### version: 1.1.0 [emeters](#emeters) diff --git a/doc/devices/wave2.md b/doc/devices/wave2.md index a2ce69e..e91f5e2 100644 --- a/doc/devices/wave2.md +++ b/doc/devices/wave2.md @@ -1,5 +1,5 @@ # States for WAVE2 -### version: 1.0.5 +### version: 1.1.0 [pd](#pd) diff --git a/io-package.json b/io-package.json index 472f6d8..5b4e8d5 100644 --- a/io-package.json +++ b/io-package.json @@ -1,317 +1,295 @@ { - "common": { - "name": "ecoflow-mqtt", - "version": "1.0.5", - "news": { - "1.0.5": { - "en": "new max settings D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsive design", - "de": "neue maximale Einstellungen D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsives Design", - "ru": "новые максимальные настройки D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; адаптивный дизайн", - "pt": "novas configurações máximas D2M: mppt.outWatts; PS: inversor_heartbeat.invOutputWatts; design responsivo", - "nl": "nieuwe maximale instellingen D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsief ontwerp", - "fr": "nouveaux paramètres maximum D2M : mppt.outWatts ; PS : inverter_heartbeat.invOutputWatts ; conception réactive", - "it": "nuove impostazioni massime D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; progettazione reattiva", - "es": "nueva configuración máxima D2M: mppt.outWatts; PD:inverter_heartbeat.invOutputWatts; diseño responsivo", - "pl": "nowe ustawienia maksymalne D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsywny projekt", - "uk": "нові максимальні налаштування D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; адаптивний дизайн", - "zh-cn": "新的最大设置 D2M:mppt.outWatts; PS:inverter_heartbeat.invOutputWatts;响应式设计" - }, - "1.0.4": { - "en": "correction for powerkit telegram reception #99", - "de": "Korrektur für Powerkit-Telegrammempfang #99", - "ru": "исправление приема телеграммы powerkit #99", - "pt": "correção para recepção de telegrama do powerkit #99", - "nl": "correctie voor powerkit-telegramontvangst #99", - "fr": "correction pour la réception des télégrammes powerkit #99", - "it": "correzione ricezione telegramma powerkit #99", - "es": "corrección para recepción de telegramas powerkit #99", - "pl": "poprawka odbioru telegramu Powerkit #99", - "uk": "виправлення для отримання телеграми powerkit №99", - "zh-cn": "powerkit 电报接收修正 #99" - }, - "1.0.3": { - "en": "watth16/17/18 upper range 10kWh, 'Backup reserve' option added for D2M", - "de": "Watt 16/17/18 oberer Bereich 10 kWh, Option „Backup-Reserve“ für D2M hinzugefügt", - "ru": "wath16/17/18 верхний диапазон 10 кВтч, для D2M добавлена ​​опция «Резервный резерв»", - "pt": "watth16/17/18 faixa superior 10kWh, opção 'Reserva de backup' adicionada para D2M", - "nl": "watth16/17/18 bovenbereik 10kWh, optie 'Backup reserve' toegevoegd voor D2M", - "fr": "watth16/17/18 plage supérieure 10 kWh, option « Réserve de secours » ajoutée pour D2M", - "it": "watth16/17/18 gamma superiore 10kWh, opzione 'Riserva di riserva' aggiunta per D2M", - "es": "wath16/17/18 rango superior 10kWh, opción 'reserva de respaldo' agregada para D2M", - "pl": "watth16/17/18 górny zakres 10kWh, dodano opcję „Rezerwa rezerwowa” dla D2M", - "uk": "watth16/17/18 верхній діапазон 10 кВт·год, опція «Резервний резерв» додана для D2M", - "zh-cn": "watth16/17/18 上限 10kWh,为 D2M 添加“备用储备”选项" - }, - "1.0.2": { - "en": "correction of SHP commands", - "de": "Korrektur der SHP-Befehle", - "ru": "исправление команд ШП", - "pt": "correção de comandos SHP", - "nl": "correctie van SHP-opdrachten", - "fr": "correction des commandes SHP", - "it": "correzione dei comandi SHP", - "es": "corrección de comandos SHP", - "pl": "korekta poleceń SHP", - "uk": "корекція команд SHP", - "zh-cn": "SHP命令的修正" - }, - "1.0.1": { - "en": "corrections for level commands, other corrections", - "de": "Korrekturen für Levelbefehle, sonstige Korrekturen", - "ru": "исправления команд уровня, другие исправления", - "pt": "correções para comandos de nível, outras correções", - "nl": "correcties voor niveaucommando's, andere correcties", - "fr": "corrections pour les commandes de niveau, autres corrections", - "it": "correzioni per comandi di livello, altre correzioni", - "es": "correcciones para comandos de nivel, otras correcciones", - "pl": "poprawki dla poleceń poziomu, inne poprawki", - "uk": "виправлення для команд рівня, інші виправлення", - "zh-cn": "级别命令的更正,其他更正" - }, - "1.0.0": { - "en": "correction of state roles (requires deletion of ecoflow objecttree!); ATTENTION! cancelation of 'InverterHeartbeat2' data from 'power stream'", - "de": "Korrektur der Statusrollen (erfordert Löschung des Ecoflow-Objektbaums!); AUFMERKSAMKEIT! Löschung der „InverterHeartbeat2“-Daten aus „Power Stream“", - "ru": "исправление государственных ролей (требуется удаление дерева объектов экопотока!); ВНИМАНИЕ! отмена данных «InverterHeartbeat2» из «потока энергии»", - "pt": "correção de funções de estado (requer exclusão do ecoflow objecttree!); ATENÇÃO! cancelamento de dados 'InverterHeartbeat2' de 'power stream'", - "nl": "correctie van statusrollen (vereist verwijdering van ecoflow objectboom!); AANDACHT! annulering van 'InverterHeartbeat2'-gegevens uit 'powerstream'", - "fr": "correction des rôles d'état (nécessite la suppression de l'arbre d'objets ecoflow !) ; ATTENTION! annulation des données 'InverterHeartbeat2' du 'Power Stream'", - "it": "correzione dei ruoli statali (richiede la cancellazione dell'oggetto ecoflow!); ATTENZIONE! cancellazione dei dati 'InverterHeartbeat2' da 'power stream'", - "es": "corrección de roles estatales (¡requiere la eliminación del árbol de objetos de ecoflow!); ¡ATENCIÓN! cancelación de datos 'InverterHeartbeat2' de 'power stream'", - "pl": "korekta ról stanowych (wymaga usunięcia drzewa obiektów ecoflow!); UWAGA! anulowanie danych „InverterHeartbeat2” ze „strumienia mocy”", - "uk": "виправлення ролей стану (вимагає видалення дерева об'єктів ecoflow!); УВАГА! скасування даних \"InverterHeartbeat2\" з \"power stream\"", - "zh-cn": "修正状态角色(需要删除 Ecoflow 对象树!);注意力!从“电力流”中取消“InverterHeartbeat2”数据" - } - }, - "messages": [ - { - "condition": { - "operand": "and", - "rules": [ - "oldVersion<0.0.8", - "newVersion>=0.0.9" - ] - }, - "title": { - "en": "Important notice!", - "de": "Wichtiger Hinweis!", - "ru": "Важное замечание!", - "pt": "Notícia importante!", - "nl": "Belangrijke mededeling!", - "fr": "Avis important!", - "it": "Avviso IMPORTANTE!", - "es": "Noticia importante!", - "pl": "Ważna uwaga!", - "uk": "Погода!", - "zh-cn": "重要通知!" - }, - "text": { - "en": "In order to work properly the adapter requires ioBroker.admin >=6.12.3. Please ensure this boundary condition. You can do this by enabling expert settings and installation from npm as source. ", - "de": "Damit der Adapter ordnungsgemäß funktioniert, ist ioBroker.admin >=6.12.3 erforderlich. Bitte achten Sie auf diese Randbedingung. Sie können dies tun, indem Sie Experteneinstellungen und die Installation von npm als Quelle aktivieren.", - "ru": "Для правильной работы адаптера требуется ioBroker.admin >=6.12.3. Пожалуйста, обеспечьте это граничное условие. Это можно сделать, включив экспертные настройки и установив их из npm в качестве источника.", - "pt": "Para funcionar corretamente, o adaptador requer ioBroker.admin >=6.12.3. Por favor, garanta esta condição de limite. Você pode fazer isso habilitando configurações avançadas e instalação do npm como fonte.", - "nl": "Om goed te kunnen werken heeft de adapter ioBroker.admin >=6.12.3 nodig. Zorg ervoor dat deze randvoorwaarde aanwezig is. Dit kunt u doen door expertinstellingen en installatie vanuit npm als bron in te schakelen.", - "fr": "Pour fonctionner correctement, l'adaptateur nécessite ioBroker.admin >=6.12.3. Veuillez vous assurer de cette condition aux limites. Vous pouvez le faire en activant les paramètres experts et l'installation à partir de npm comme source.", - "it": "Per funzionare correttamente l'adattatore richiede ioBroker.admin >=6.12.3. Si prega di garantire questa condizione al contorno. Puoi farlo abilitando le impostazioni avanzate e l'installazione da npm come sorgente.", - "es": "Para funcionar correctamente, el adaptador requiere ioBroker.admin >=6.12.3. Asegúrese de que se cumpla esta condición límite. Puede hacerlo habilitando la configuración experta y la instalación desde npm como fuente.", - "pl": "Do poprawnego działania adapter wymaga ioBroker.admin >=6.12.3. Proszę zapewnić ten warunek brzegowy. Możesz to zrobić, włączając ustawienia eksperckie i instalację z npm jako źródła.", - "uk": "Для належної роботи адаптеру потрібен ioBroker.admin >=6.12.3. Будь ласка, переконайтеся в цій граничній умові. Ви можете зробити це, увімкнувши експертні налаштування та інсталяцію з npm як джерела.", - "zh-cn": "为了正常工作,适配器需要 ioBroker.admin >=6.12.3。请确保这个边界条件。您可以通过启用专家设置并从 npm 作为源进行安装来实现此目的。" - }, - "level": "warn", - "buttons": [ - "ok", - "cancel" - ] - }, - { - "condition": { - "operand": "and", - "rules": [ - "oldVersion<1.0.0", - "newVersion>=1.0.0" - ] - }, - "title": { - "en": "Important notice!", - "de": "Wichtiger Hinweis!", - "ru": "Важное замечание!", - "pt": "Notícia importante!", - "nl": "Belangrijke mededeling!", - "fr": "Avis important!", - "it": "Avviso IMPORTANTE!", - "es": "Noticia importante!", - "pl": "Ważna uwaga!", - "uk": "Погода!", - "zh-cn": "重要通知!" - }, - "text": { - "en": "State roles of the datapoints are corrected, please stop the adapter, delete all objects of the ecoflow-mqtt instance and restart adapter. Datapoints are recreated.", - "de": "Statusrollen der Datenpunkte wurden korrigiert, bitte stoppen Sie den Adapter, löschen Sie alle Objekte der ecoflow-mqtt-Instanz und starten Sie den Adapter neu. Datenpunkte werden neu erstellt.", - "ru": "Роли состояния точек данных исправлены. Остановите адаптер, удалите все объекты экземпляра ecoflow-mqtt и перезапустите адаптер. Точки данных воссоздаются.", - "pt": "As funções de estado dos pontos de dados foram corrigidas. Pare o adaptador, exclua todos os objetos da instância ecoflow-mqtt e reinicie o adaptador. Os pontos de dados são recriados.", - "nl": "De statusrollen van de datapunten zijn gecorrigeerd. Stop de adapter, verwijder alle objecten van de ecoflow-mqtt-instantie en start de adapter opnieuw. Datapunten worden opnieuw gemaakt.", - "fr": "Les rôles d'état des points de données sont corrigés, veuillez arrêter l'adaptateur, supprimer tous les objets de l'instance ecoflow-mqtt et redémarrer l'adaptateur. Les points de données sont recréés.", - "it": "I ruoli di stato dei datapoint sono corretti, arresta l'adattatore, elimina tutti gli oggetti dell'istanza ecoflow-mqtt e riavvia l'adattatore. I punti dati vengono ricreati.", - "es": "Se corrigen las funciones de estado de los puntos de datos. Detenga el adaptador, elimine todos los objetos de la instancia ecoflow-mqtt y reinicie el adaptador. Se recrean los puntos de datos.", - "pl": "Role stanowe punktów danych zostały poprawione. Zatrzymaj adapter, usuń wszystkie obiekty instancji ecoflow-mqtt i zrestartuj adapter. Punkty danych są odtwarzane.", - "uk": "Ролі станів точок даних виправлено. Зупиніть адаптер, видаліть усі об’єкти екземпляра ecoflow-mqtt і перезапустіть адаптер. Точки даних створюються заново.", - "zh-cn": "数据点的状态角色已更正,请停止适配器,删除ecoflow-mqtt实例的所有对象并重新启动适配器。数据点被重新创建。" - }, - "level": "warn", - "buttons": [ - "ok", - "cancel" - ] - } - ], - "titleLang": { - "en": "ecoflow", - "de": "Ecoflow", - "ru": "экопоток", - "pt": "ecofluxo", - "nl": "ecostroom", - "fr": "écoflux", - "it": "ecoflusso", - "es": "ecoflujo", - "pl": "ekoprzepływ", - "uk": "екопотік", - "zh-cn": "生态流" - }, - "desc": { - "en": "connects to ecoflow products", - "de": "verbindet sich mit Ecoflow-Produkten", - "ru": "подключается к продуктам Ecoflow", - "pt": "conecta-se a produtos ecoflow", - "nl": "koppelt aan ecoflow-producten", - "fr": "se connecte aux produits ecoflow", - "it": "si collega ai prodotti ecoflow", - "es": "se conecta a productos ecoflow", - "pl": "łączy się z produktami ecoflow", - "uk": "підключається до продуктів ecoflow", - "zh-cn": "连接至 Ecoflow 产品" - }, - "authors": [ - "foxthefox " - ], - "keywords": [ - "ecoflow", - "powerstream", - "powerstation", - "delta", - "river", - "powerkit", - "powerocaen", - "shp" - ], - "platform": "Javascript/Node.js", - "icon": "ecoflow-mqtt.png", - "enabled": true, - "extIcon": "https://raw.githubusercontent.com/foxthefox/ioBroker.ecoflow-mqtt/main/admin/ecoflow-mqtt.png", - "readme": "https://github.com/foxthefox/ioBroker.ecoflow-mqtt/blob/main/README.md", - "loglevel": "debug", - "mode": "daemon", - "type": "iot-systems", - "compact": true, - "messagebox": true, - "connectionType": "cloud", - "dataSource": "push", - "tier": 3, - "licenseInformation": { - "license": "MIT", - "link": "https://opensource.org/license/mit/", - "type": "free" - }, - "adminUI": { - "config": "json" - }, - "dependencies": [ - { - "js-controller": ">=5.0.12" - } - ], - "globalDependencies": [ - { - "admin": ">=6.12.3" - } - ] - }, - "protectedNative": [ - "userName", - "userPassword", - "mqttUserId", - "mqttPwd", - "mqttClientId", - "haMqttUserId", - "haMqttUserPWd" - ], - "encryptedNative": [ - "userPassword", - "mqttPwd", - "haMqttUserPWd" - ], - "native": { - "userName": "userEmail", - "userPassword": "pw", - "mqttUserId": "1xxxx", - "mqttUserName": "app-....", - "mqttPwd": "xxxx", - "mqttClientId": "ANDRIOD-...", - "mqttUrl": "mqtts://mqtt-e.ecoflow.com", - "mqttPort": 8883, - "enableMqttReconnect": false, - "pstreams": [], - "pstations": [], - "plugs": [], - "waves": [], - "glaciers": [], - "generators": [], - "panels": [], - "shellies": [], - "powerkits": [], - "poweroceans": [], - "haMqttUserId": "hamqttuser", - "haMqttUserPWd": "hamqttusePWd", - "haMqttUrl": "192.x.x.x", - "haMqttPort": 1883, - "haMqttEnable": false, - "haMqttProtocol": "mqtt://", - "haDiscoveryRetain": false, - "msgHaAutoDiscovery": false, - "msgHaIncomming": false, - "msgHaOutgoing": false, - "msgHaStatusInitial": false, - "showDiscoveryObject": false, - "haTopic": "iob_ef", - "msgStateCreation": false, - "msgUpdate": false, - "msgUpdateValue": false, - "msgSetGet": false, - "msgCmd": false, - "msgUnknownMsg": false, - "showHex": false - }, - "objects": [], - "instanceObjects": [ - { - "_id": "info", - "type": "channel", - "common": { - "name": "Information" - }, - "native": {} - }, - { - "_id": "info.connection", - "type": "state", - "common": { - "role": "indicator.connected", - "name": "Device or service connected", - "type": "boolean", - "read": true, - "write": false, - "def": false - }, - "native": {} - } - ] + "common": { + "name": "ecoflow-mqtt", + "version": "1.1.0", + "news": { + "1.1.0": { + "en": "SHP new data points for the scheduled tasks" + }, + "1.0.5": { + "en": "new max settings D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsive design", + "de": "neue maximale Einstellungen D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsives Design", + "ru": "новые максимальные настройки D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; адаптивный дизайн", + "pt": "novas configurações máximas D2M: mppt.outWatts; PS: inversor_heartbeat.invOutputWatts; design responsivo", + "nl": "nieuwe maximale instellingen D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsief ontwerp", + "fr": "nouveaux paramètres maximum D2M : mppt.outWatts ; PS : inverter_heartbeat.invOutputWatts ; conception réactive", + "it": "nuove impostazioni massime D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; progettazione reattiva", + "es": "nueva configuración máxima D2M: mppt.outWatts; PD:inverter_heartbeat.invOutputWatts; diseño responsivo", + "pl": "nowe ustawienia maksymalne D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; responsywny projekt", + "uk": "нові максимальні налаштування D2M: mppt.outWatts; PS:inverter_heartbeat.invOutputWatts; адаптивний дизайн", + "zh-cn": "新的最大设置 D2M:mppt.outWatts; PS:inverter_heartbeat.invOutputWatts;响应式设计" + }, + "1.0.4": { + "en": "correction for powerkit telegram reception #99", + "de": "Korrektur für Powerkit-Telegrammempfang #99", + "ru": "исправление приема телеграммы powerkit #99", + "pt": "correção para recepção de telegrama do powerkit #99", + "nl": "correctie voor powerkit-telegramontvangst #99", + "fr": "correction pour la réception des télégrammes powerkit #99", + "it": "correzione ricezione telegramma powerkit #99", + "es": "corrección para recepción de telegramas powerkit #99", + "pl": "poprawka odbioru telegramu Powerkit #99", + "uk": "виправлення для отримання телеграми powerkit №99", + "zh-cn": "powerkit 电报接收修正 #99" + }, + "1.0.3": { + "en": "watth16/17/18 upper range 10kWh, 'Backup reserve' option added for D2M", + "de": "Watt 16/17/18 oberer Bereich 10 kWh, Option „Backup-Reserve“ für D2M hinzugefügt", + "ru": "wath16/17/18 верхний диапазон 10 кВтч, для D2M добавлена ​​опция «Резервный резерв»", + "pt": "watth16/17/18 faixa superior 10kWh, opção 'Reserva de backup' adicionada para D2M", + "nl": "watth16/17/18 bovenbereik 10kWh, optie 'Backup reserve' toegevoegd voor D2M", + "fr": "watth16/17/18 plage supérieure 10 kWh, option « Réserve de secours » ajoutée pour D2M", + "it": "watth16/17/18 gamma superiore 10kWh, opzione 'Riserva di riserva' aggiunta per D2M", + "es": "wath16/17/18 rango superior 10kWh, opción 'reserva de respaldo' agregada para D2M", + "pl": "watth16/17/18 górny zakres 10kWh, dodano opcję „Rezerwa rezerwowa” dla D2M", + "uk": "watth16/17/18 верхній діапазон 10 кВт·год, опція «Резервний резерв» додана для D2M", + "zh-cn": "watth16/17/18 上限 10kWh,为 D2M 添加“备用储备”选项" + }, + "1.0.2": { + "en": "correction of SHP commands", + "de": "Korrektur der SHP-Befehle", + "ru": "исправление команд ШП", + "pt": "correção de comandos SHP", + "nl": "correctie van SHP-opdrachten", + "fr": "correction des commandes SHP", + "it": "correzione dei comandi SHP", + "es": "corrección de comandos SHP", + "pl": "korekta poleceń SHP", + "uk": "корекція команд SHP", + "zh-cn": "SHP命令的修正" + }, + "1.0.1": { + "en": "corrections for level commands, other corrections", + "de": "Korrekturen für Levelbefehle, sonstige Korrekturen", + "ru": "исправления команд уровня, другие исправления", + "pt": "correções para comandos de nível, outras correções", + "nl": "correcties voor niveaucommando's, andere correcties", + "fr": "corrections pour les commandes de niveau, autres corrections", + "it": "correzioni per comandi di livello, altre correzioni", + "es": "correcciones para comandos de nivel, otras correcciones", + "pl": "poprawki dla poleceń poziomu, inne poprawki", + "uk": "виправлення для команд рівня, інші виправлення", + "zh-cn": "级别命令的更正,其他更正" + }, + "1.0.0": { + "en": "correction of state roles (requires deletion of ecoflow objecttree!); ATTENTION! cancelation of 'InverterHeartbeat2' data from 'power stream'", + "de": "Korrektur der Statusrollen (erfordert Löschung des Ecoflow-Objektbaums!); AUFMERKSAMKEIT! Löschung der „InverterHeartbeat2“-Daten aus „Power Stream“", + "ru": "исправление государственных ролей (требуется удаление дерева объектов экопотока!); ВНИМАНИЕ! отмена данных «InverterHeartbeat2» из «потока энергии»", + "pt": "correção de funções de estado (requer exclusão do ecoflow objecttree!); ATENÇÃO! cancelamento de dados 'InverterHeartbeat2' de 'power stream'", + "nl": "correctie van statusrollen (vereist verwijdering van ecoflow objectboom!); AANDACHT! annulering van 'InverterHeartbeat2'-gegevens uit 'powerstream'", + "fr": "correction des rôles d'état (nécessite la suppression de l'arbre d'objets ecoflow !) ; ATTENTION! annulation des données 'InverterHeartbeat2' du 'Power Stream'", + "it": "correzione dei ruoli statali (richiede la cancellazione dell'oggetto ecoflow!); ATTENZIONE! cancellazione dei dati 'InverterHeartbeat2' da 'power stream'", + "es": "corrección de roles estatales (¡requiere la eliminación del árbol de objetos de ecoflow!); ¡ATENCIÓN! cancelación de datos 'InverterHeartbeat2' de 'power stream'", + "pl": "korekta ról stanowych (wymaga usunięcia drzewa obiektów ecoflow!); UWAGA! anulowanie danych „InverterHeartbeat2” ze „strumienia mocy”", + "uk": "виправлення ролей стану (вимагає видалення дерева об'єктів ecoflow!); УВАГА! скасування даних \"InverterHeartbeat2\" з \"power stream\"", + "zh-cn": "修正状态角色(需要删除 Ecoflow 对象树!);注意力!从“电力流”中取消“InverterHeartbeat2”数据" + } + }, + "messages": [ + { + "condition": { + "operand": "and", + "rules": [ "oldVersion<0.0.8", "newVersion>=0.0.9" ] + }, + "title": { + "en": "Important notice!", + "de": "Wichtiger Hinweis!", + "ru": "Важное замечание!", + "pt": "Notícia importante!", + "nl": "Belangrijke mededeling!", + "fr": "Avis important!", + "it": "Avviso IMPORTANTE!", + "es": "Noticia importante!", + "pl": "Ważna uwaga!", + "uk": "Погода!", + "zh-cn": "重要通知!" + }, + "text": { + "en": "In order to work properly the adapter requires ioBroker.admin >=6.12.3. Please ensure this boundary condition. You can do this by enabling expert settings and installation from npm as source. ", + "de": "Damit der Adapter ordnungsgemäß funktioniert, ist ioBroker.admin >=6.12.3 erforderlich. Bitte achten Sie auf diese Randbedingung. Sie können dies tun, indem Sie Experteneinstellungen und die Installation von npm als Quelle aktivieren.", + "ru": "Для правильной работы адаптера требуется ioBroker.admin >=6.12.3. Пожалуйста, обеспечьте это граничное условие. Это можно сделать, включив экспертные настройки и установив их из npm в качестве источника.", + "pt": "Para funcionar corretamente, o adaptador requer ioBroker.admin >=6.12.3. Por favor, garanta esta condição de limite. Você pode fazer isso habilitando configurações avançadas e instalação do npm como fonte.", + "nl": "Om goed te kunnen werken heeft de adapter ioBroker.admin >=6.12.3 nodig. Zorg ervoor dat deze randvoorwaarde aanwezig is. Dit kunt u doen door expertinstellingen en installatie vanuit npm als bron in te schakelen.", + "fr": "Pour fonctionner correctement, l'adaptateur nécessite ioBroker.admin >=6.12.3. Veuillez vous assurer de cette condition aux limites. Vous pouvez le faire en activant les paramètres experts et l'installation à partir de npm comme source.", + "it": "Per funzionare correttamente l'adattatore richiede ioBroker.admin >=6.12.3. Si prega di garantire questa condizione al contorno. Puoi farlo abilitando le impostazioni avanzate e l'installazione da npm come sorgente.", + "es": "Para funcionar correctamente, el adaptador requiere ioBroker.admin >=6.12.3. Asegúrese de que se cumpla esta condición límite. Puede hacerlo habilitando la configuración experta y la instalación desde npm como fuente.", + "pl": "Do poprawnego działania adapter wymaga ioBroker.admin >=6.12.3. Proszę zapewnić ten warunek brzegowy. Możesz to zrobić, włączając ustawienia eksperckie i instalację z npm jako źródła.", + "uk": "Для належної роботи адаптеру потрібен ioBroker.admin >=6.12.3. Будь ласка, переконайтеся в цій граничній умові. Ви можете зробити це, увімкнувши експертні налаштування та інсталяцію з npm як джерела.", + "zh-cn": "为了正常工作,适配器需要 ioBroker.admin >=6.12.3。请确保这个边界条件。您可以通过启用专家设置并从 npm 作为源进行安装来实现此目的。" + }, + "level": "warn", + "buttons": [ "ok", "cancel" ] + }, + { + "condition": { + "operand": "and", + "rules": [ "oldVersion<1.0.0", "newVersion>=1.0.0" ] + }, + "title": { + "en": "Important notice!", + "de": "Wichtiger Hinweis!", + "ru": "Важное замечание!", + "pt": "Notícia importante!", + "nl": "Belangrijke mededeling!", + "fr": "Avis important!", + "it": "Avviso IMPORTANTE!", + "es": "Noticia importante!", + "pl": "Ważna uwaga!", + "uk": "Погода!", + "zh-cn": "重要通知!" + }, + "text": { + "en": "State roles of the datapoints are corrected, please stop the adapter, delete all objects of the ecoflow-mqtt instance and restart adapter. Datapoints are recreated.", + "de": "Statusrollen der Datenpunkte wurden korrigiert, bitte stoppen Sie den Adapter, löschen Sie alle Objekte der ecoflow-mqtt-Instanz und starten Sie den Adapter neu. Datenpunkte werden neu erstellt.", + "ru": "Роли состояния точек данных исправлены. Остановите адаптер, удалите все объекты экземпляра ecoflow-mqtt и перезапустите адаптер. Точки данных воссоздаются.", + "pt": "As funções de estado dos pontos de dados foram corrigidas. Pare o adaptador, exclua todos os objetos da instância ecoflow-mqtt e reinicie o adaptador. Os pontos de dados são recriados.", + "nl": "De statusrollen van de datapunten zijn gecorrigeerd. Stop de adapter, verwijder alle objecten van de ecoflow-mqtt-instantie en start de adapter opnieuw. Datapunten worden opnieuw gemaakt.", + "fr": "Les rôles d'état des points de données sont corrigés, veuillez arrêter l'adaptateur, supprimer tous les objets de l'instance ecoflow-mqtt et redémarrer l'adaptateur. Les points de données sont recréés.", + "it": "I ruoli di stato dei datapoint sono corretti, arresta l'adattatore, elimina tutti gli oggetti dell'istanza ecoflow-mqtt e riavvia l'adattatore. I punti dati vengono ricreati.", + "es": "Se corrigen las funciones de estado de los puntos de datos. Detenga el adaptador, elimine todos los objetos de la instancia ecoflow-mqtt y reinicie el adaptador. Se recrean los puntos de datos.", + "pl": "Role stanowe punktów danych zostały poprawione. Zatrzymaj adapter, usuń wszystkie obiekty instancji ecoflow-mqtt i zrestartuj adapter. Punkty danych są odtwarzane.", + "uk": "Ролі станів точок даних виправлено. Зупиніть адаптер, видаліть усі об’єкти екземпляра ecoflow-mqtt і перезапустіть адаптер. Точки даних створюються заново.", + "zh-cn": "数据点的状态角色已更正,请停止适配器,删除ecoflow-mqtt实例的所有对象并重新启动适配器。数据点被重新创建。" + }, + "level": "warn", + "buttons": [ "ok", "cancel" ] + } + ], + "titleLang": { + "en": "ecoflow", + "de": "Ecoflow", + "ru": "экопоток", + "pt": "ecofluxo", + "nl": "ecostroom", + "fr": "écoflux", + "it": "ecoflusso", + "es": "ecoflujo", + "pl": "ekoprzepływ", + "uk": "екопотік", + "zh-cn": "生态流" + }, + "desc": { + "en": "connects to ecoflow products", + "de": "verbindet sich mit Ecoflow-Produkten", + "ru": "подключается к продуктам Ecoflow", + "pt": "conecta-se a produtos ecoflow", + "nl": "koppelt aan ecoflow-producten", + "fr": "se connecte aux produits ecoflow", + "it": "si collega ai prodotti ecoflow", + "es": "se conecta a productos ecoflow", + "pl": "łączy się z produktami ecoflow", + "uk": "підключається до продуктів ecoflow", + "zh-cn": "连接至 Ecoflow 产品" + }, + "authors": [ "foxthefox " ], + "keywords": [ "ecoflow", "powerstream", "powerstation", "delta", "river", "powerkit", "powerocaen", "shp" ], + "platform": "Javascript/Node.js", + "icon": "ecoflow-mqtt.png", + "enabled": true, + "extIcon": "https://raw.githubusercontent.com/foxthefox/ioBroker.ecoflow-mqtt/main/admin/ecoflow-mqtt.png", + "readme": "https://github.com/foxthefox/ioBroker.ecoflow-mqtt/blob/main/README.md", + "loglevel": "debug", + "mode": "daemon", + "type": "iot-systems", + "compact": true, + "messagebox": true, + "connectionType": "cloud", + "dataSource": "push", + "tier": 3, + "licenseInformation": { + "license": "MIT", + "link": "https://opensource.org/license/mit/", + "type": "free" + }, + "adminUI": { + "config": "json" + }, + "dependencies": [ + { + "js-controller": ">=5.0.12" + } + ], + "globalDependencies": [ + { + "admin": ">=6.12.3" + } + ] + }, + "protectedNative": [ + "userName", + "userPassword", + "mqttUserId", + "mqttPwd", + "mqttClientId", + "haMqttUserId", + "haMqttUserPWd" + ], + "encryptedNative": [ "userPassword", "mqttPwd", "haMqttUserPWd" ], + "native": { + "userName": "userEmail", + "userPassword": "pw", + "mqttUserId": "1xxxx", + "mqttUserName": "app-....", + "mqttPwd": "xxxx", + "mqttClientId": "ANDRIOD-...", + "mqttUrl": "mqtts://mqtt-e.ecoflow.com", + "mqttPort": 8883, + "enableMqttReconnect": false, + "pstreams": [], + "pstations": [], + "plugs": [], + "waves": [], + "glaciers": [], + "generators": [], + "panels": [], + "shellies": [], + "powerkits": [], + "poweroceans": [], + "alternators": [], + "unknowns": [], + "haMqttUserId": "hamqttuser", + "haMqttUserPWd": "hamqttusePWd", + "haMqttUrl": "192.x.x.x", + "haMqttPort": 1883, + "haMqttEnable": false, + "haMqttProtocol": "mqtt://", + "haDiscoveryRetain": false, + "msgHaAutoDiscovery": false, + "msgHaIncomming": false, + "msgHaOutgoing": false, + "msgHaStatusInitial": false, + "showDiscoveryObject": false, + "haTopic": "iob_ef", + "msgStateCreation": false, + "msgUpdate": false, + "msgUpdateValue": false, + "msgSetGet": false, + "msgCmd": false, + "msgUnknownMsg": false, + "showHex": false + }, + "objects": [], + "instanceObjects": [ + { + "_id": "info", + "type": "channel", + "common": { + "name": "Information" + }, + "native": {} + }, + { + "_id": "info.connection", + "type": "state", + "common": { + "role": "indicator.connected", + "name": "Device or service connected", + "type": "boolean", + "read": true, + "write": false, + "def": false + }, + "native": {} + } + ] } diff --git a/lib/ecoflow_data.js b/lib/ecoflow_data.js index 45e867e..aecd674 100644 --- a/lib/ecoflow_data.js +++ b/lib/ecoflow_data.js @@ -164,9 +164,58 @@ const models = { 'Discharging only) Pure sine, 7,200W total, 120/240 V~ 60 Hz; (Bypass) 100-120V~30A max, 50/60 Hz', usbOutput: 'USB-A: 5V⎓2.4A, 12W max per port, total 24W; USB-C: 5/9/12/15/20V⎓5A, 100W max per port, total 200W', + dcInput: '12V 8A max, 48V 20A max', carOutput: '12.6V⎓30A, 378W max' } }, + deltapro3: { + identifiers: 'R331Zxxx', //todo + manufacturer: 'Ecoflow', + model: 'Delta Pro 3, 4096Wh', + name: 'Delta Pro 3', + type: 89, //todo + spec: { + capacity: 'V⎓A, 4096Wh', + acInputPower: '(Charging only) 200-240V~12.5A, 50/60 Hz 2900W max', + solarInput: '30-150V⎓15A max, 1600W max; 11-60V⎓20A max, 1000W max', + acOutput: '4000W, (6000W X-Boost), max 8000W', + usbOutput: + 'USB-A fast charge: 5V⎓2,4A/9⎓2A/12V⎓1,5A, 2x, 18W max per port; USB-C: 5/9/12/15/20V⎓5A, 2x, 100W max per port', + carOutput: '12.6V⎓30A, 378W max, DC5521 1x 3 A max, Anderson 1x 30A max.' + } + }, + delta3plus: { + identifiers: 'MR51xxx', //todo + manufacturer: 'Ecoflow', + model: 'Delta 3 Plus, 1536Wh', + name: 'Delta 3 Plus', + type: 89, //todo + spec: { + capacity: 'V⎓A, 1536Wh', + acInputPower: '(Charging only) 100-120V~15A; 200-240V~12.5A, 50/60 Hz 1500W;', + solarInput: '11-60V⎓ A max, 2x 500W max', + acOutput: '1800W, 3600W X-Boost', + usbOutput: + 'USB-A: 5V⎓2.4A, 2x, 12W max per port; USB-A fast charge: 5V⎓2,4A/9⎓2A/12V⎓1,5A 2x, 18W max per port, USB-C: 5/9/12/15/20V⎓5A, 2x, 100W max per port', + carOutput: '12.6V⎓10A, 126W max, DC5521 2 × 12,6 V, 3 A max' + } + }, + delta3: { + identifiers: 'R331Zxxx', //todo + manufacturer: 'Ecoflow', + model: 'Delta 3, 1024Wh', + name: 'Delta 3', + type: 89, //todo + spec: { + capacity: 'V⎓ A, 1024Wh', + acInputPower: '(Charging only) 100-120V~A; 200-240V~A, 50/60 Hz, 1500W', + solarInput: '11-60V⎓ A max, 1x 500W max', + acOutput: '1800W, 3600W X-Boost', + usbOutput: + 'USB-A fast charge: 5V⎓2,4A/9⎓2A/12V⎓1,5A, 2x, 18W max per port; USB-C: 5/9/12/15/20V⎓5A, 2x, 100W max per port', + carOutput: '12.6V⎓10A, 126W max, DC5521 2 × 12,6 V, 3 A max' + } + }, river2max: { identifiers: 'Rxxx', manufacturer: 'Ecoflow', @@ -433,6 +482,12 @@ const models = { manufacturer: 'Ecoflow', model: 'Power OCEAN DC FIT', name: 'Power OCEAN DC FIT' + }, + alternator: { + identifiers: 'F371ZEBxxxx', + manufacturer: 'Ecoflow', + model: 'Alternator 800W', + name: 'Alternator 800W' } }; @@ -1806,1570 +1861,104 @@ const pstreamStates = { role: 'info', name: 'unknown35' }, - unknown36: { - entity_type: 'text', - entity_category: 'diagnostic', - role: 'info', - name: 'unknown36' - }, - unknown37: { - entity_type: 'text', - entity_category: 'diagnostic', - role: 'info', - name: 'unknown37' - }, - unixtime_38: { - entity_type: 'text', - entity_category: 'diagnostic', - role: 'info', - name: 'unknown38' - } - }, - level: { - maxWatts: { - min: 1000, - max: 2500, - unit_of_measurement: 'W', - mult: 1, - step: 100, - entity_type: 'number', - device_class: 'power', - name: 'Plug Max. AC power', - unique_id: 'efplug_maxWatts', - role: 'level' - }, - brightness: { - min: 0, - max: 100, - unit_of_measurement: '%', - mult: 0.097752, - step: 1, - entity_type: 'number', - device_class: 'illuminance', - name: 'Plug brightness', - unique_id: 'efplug_brightness', - role: 'level', - subrole: 'brightness' - } - }, - switch: { - switch: { - entity_type: 'switch', - device_class: 'switch', - payload_off: 'off', - payload_on: 'on', - name: 'Plug Switch', - unique_id: 'efplug_switch', - role: 'switch', - switch: { '0': 'off', '1': 'on' } - }, - meshEnable: { - entity_type: 'switch', - device_class: 'switch', - payload_off: 'disabled', - payload_on: 'enabled', - name: 'Plug Mesh enable', - unique_id: 'efplug_mesh_enable', - role: 'switch', - meshEnable: { '0': 'disabled', '1': 'enabled' } - }, - dynWattEnable: { - entity_type: 'switch', - device_class: 'switch', - payload_off: 'off', - payload_on: 'on', - name: 'Dynamic watt enable', - unique_id: 'efplug_dynwatt_enable', - role: 'switch', - dynWattEnable: { '0': 'off', '1': 'on' } - } - }, - diagnostic: { - errCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Plug Error Code', - unique_id: 'efplug_errCode', - role: 'info', - errCode: { - '0': 'OK ?' - } - }, - warnCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Plug Warn Code', - unique_id: 'efstream_warnCode', - role: 'info', - warnCode: { - '0': 'OK ?' - } - } - } - }, - //new delta pro ultra - AppParaHeartbeatReport: { - diagnostic: { - sysWorkMode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'System Work Mode', - role: 'info', - sysWorkMode: { '0': 'OK?' } - }, - sysBackupEvent: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'System Backup Event', - role: 'info', - sysBackupEvent: { '0': 'OK?' } - }, - acXboost: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'AC X-Boost', - role: 'info', - acXboost: { '0': 'disabled?', '1': 'enabled?' } - }, - bmsModeSet: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'BMS Mode Setting', - role: 'info', - bmsModeSet: { '0': '?' } - }, - acOftenOpenFlg: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'acOftenOpenFlg', - role: 'info', - acOftenOpenFlg: { '0': 'OK?' } - }, - solarOnlyFlg: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Solar only', - role: 'info', - solarOnlyFlg: { '0': 'all?', '1': 'solar only?' } - }, - timezoneSettype: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Timezone tracking', - role: 'info', - timezoneSettype: { '0': 'no tracking?', '1': 'tracking?' } - } - }, - number: { - sysBackupSoc: { - min: 0, - max: 100, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'System backup SOC' - }, - acOutFreq: { - min: 50, - max: 60, - unit_of_measurement: 'Hz', - mult: 1, - entity_type: 'sensor', - device_class: 'frequency', - role: 'value', - name: 'AC output frequency' - }, - acOftenOpenMinSoc: { - min: 0, - max: 30, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'acOftenOpenMinSoc' - }, - sysTimezone: { - min: -12, - max: 12, - unit_of_measurement: 'h', - mult: 0.01, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Timezone offset' - }, - //to be deleted when level - backupRatio: { - min: 20, - max: 90, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'Backup limit (ratio?)' - } - }, - switch: { - energyManageEnable: { - entity_type: 'switch', - device_class: 'switch', - payload_off: 'off', - payload_on: 'on', - name: 'Enable energy management', - role: 'switch', - energyManageEnable: { '0': 'off', '1': 'on' } - } - }, - level: { - backupRatio: { - min: 20, - max: 90, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'level', - name: 'Backup limit (ratio?)' - }, - chgMaxSoc: { - min: 50, - max: 100, - unit_of_measurement: '%', - mult: 1, - step: 1, - entity_type: 'sensor', - device_class: 'battery', - name: 'Maximum charge SOC', - role: 'level' - }, - dsgMinSoc: { - min: 0, - max: 30, - unit_of_measurement: '%', - mult: 1, - step: 1, - entity_type: 'sensor', - device_class: 'battery', - name: 'Minimum discharge SOC', - role: 'level' - }, - chg_5p8SetWatts: { - min: 200, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - step: 1, - entity_type: 'sensor', - device_class: 'power', - name: 'Default charge power PowerI/O', - role: 'level' - }, - chgC20SetWatts: { - min: 200, - max: 2400, - unit_of_measurement: 'W', - mult: 1, - step: 1, - entity_type: 'sensor', - device_class: 'power', - name: 'Default charge power AC IN', - role: 'level' - }, - powerStandbyMins: { - min: 0, - max: 800, - unit_of_measurement: 'min', - mult: 1, - step: 1, - entity_type: 'select', - device_class: 'duration', - select: [ 'Never', '30 min', '1 hr', '2 hr', '4 hr', '6 hr', '12 hr' ], - select_obj: { - Never: 0, - '30 min': 30, - '1 hr': 60, - '2 hr': 120, - '4 hr': 240, - '6 hr': 360, - '12 hr': 720 - }, - states: { - 0: 'Never', - 30: '30 min', - 60: '1 hr', - 120: '2 hr', - 240: '4 hr', - 360: '6 hr', - 720: '12 hr' - }, - name: 'System standby time', - role: 'level', - subrole: 'timer' - }, - screenStandbySec: { - min: 0, - max: 1800, - unit_of_measurement: 's', - mult: 1, - step: 60, - entity_type: 'select', - device_class: 'duration', - select: [ 'Never', '10 sec', '30 sec', '1 min', '5 min', '30 min' ], - select_obj: { - Never: 0, - '10 sec': 10, - '30 sec': 30, - '1 min': 60, - '5 min': 300, - '30 min': 1800 - }, - states: { - 0: 'Never', - 10: '10 sec', - 30: '30 sec', - 60: '1 min', - 300: '5 min', - 1800: '30 min' - }, - name: 'Screen standby time', - role: 'level', - subrole: 'timer' - }, - dcStandbyMins: { - min: 0, - max: 1440, - unit_of_measurement: 'min', - mult: 1, - step: 120, - entity_type: 'select', - device_class: 'duration', - select: [ 'Never', '30 min', '1 hr', '2 hr', '4 hr', '6 hr', '12 hr', '24 hr' ], - select_obj: { - Never: 0, - '30 min': 30, - '1 hr': 60, - '2 hr': 120, - '4 hr': 240, - '6 hr': 360, - '12 hr': 720, - '24 hr': 1440 - }, - states: { - 0: 'Never', - 30: '30 min', - 60: '1 hr', - 120: '2 hr', - 240: '4 hr', - 360: '6 hr', - 720: '12 hr', - 1440: '24 hr' - }, - name: 'DC12V standby time', - role: 'level', - subrole: 'timer' - }, - acStandbyMins: { - min: 0, - max: 800, - unit_of_measurement: 'W', - mult: 1, - step: 1, - entity_type: 'select', - device_class: 'duration', - select: [ 'Never', '30 min', '1 hr', '2 hr', '4 hr', '6 hr', '12 hr', '24 hr' ], - select_obj: { - Never: 0, - '30 min': 30, - '1 hr': 60, - '2 hr': 120, - '4 hr': 240, - '6 hr': 360, - '12 hr': 720, - '24 hr': 1440 - }, - states: { - 0: 'Never', - 30: '30 min', - 60: '1 hr', - 120: '2 hr', - 240: '4 hr', - 360: '6 hr', - 720: '12 hr', - 1440: '24 hr' - }, - name: 'AC standby time', - role: 'level', - subrole: 'timer' - } - }, - string: { - sysTimezoneId: { entity_type: 'text', entity_category: 'diagnostic', name: 'Timezone', role: 'info' } - } - }, - AppShowHeartbeatReport: { - string: { - protoVer: { entity_type: 'text', entity_category: 'diagnostic', name: 'Version', role: 'info' }, - simIccid: { entity_type: 'text', entity_category: 'diagnostic', name: 'simIccid:', role: 'info' }, - chgTimeTaskTable_0: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Table 0', - role: 'info' - }, - chgTimeTaskTable_1: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Table 1', - role: 'info' - }, - chgTimeTaskTable_2: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Table 2', - role: 'info' - }, - dsgTimeTaskTable_0: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Table 0', - role: 'info' - }, - dsgTimeTaskTable_1: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Table 1', - role: 'info' - }, - dsgTimeTaskTable_2: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Table 2', - role: 'info' - } - }, - number: { - //as a number until it is clear how the bits are used - showFlag: { - min: 0, - unit_of_measurement: '', - mult: 1, - entity_type: 'sensor', - role: 'value', - name: 'show flag' - }, - soc: { - min: 0, - max: 100, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'SOC' - }, - bpNum: { - min: 0, - max: 5, - unit_of_measurement: '', - mult: 1, - entity_type: 'sensor', - role: 'value', - name: 'Baiiery pack count' - }, - c20ChgMaxWatts: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Max charging power AC IN' - }, - paraChgMaxWatts: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Max parallel charging power' - }, - remainTime: { - min: 0, - unit_of_measurement: 'min', - mult: 1, - entity_type: 'sensor', - device_class: 'time', - role: 'value', - name: 'Remaining time' - }, - fullCombo: { - min: 0, - max: 100, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'fullCombo' - }, - remainCombo: { - min: 0, - max: 100, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'remainCombo' - }, - wattsInSum: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Total power input' - }, - wattsOutSum: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Total power output' - }, - outUsb1Pwr: { - min: 0, - max: 12, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power USB-A 1' - }, - outUsb2Pwr: { - min: 0, - max: 12, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power USB-A 2' - }, - outTypec1Pwr: { - min: 0, - max: 100, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power USB-C 1' - }, - outTypec2Pwr: { - min: 0, - max: 100, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power USB-C 2' - }, - outAdsPwr: { - min: 0, - max: 378, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power DC12V' - }, - outAcL1_1Pwr: { - min: 0, - max: 2400, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power Backup 1' - }, - outAcL1_2Pwr: { - min: 0, - max: 2400, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power Backup 2' - }, - outAcL2_1Pwr: { - min: 0, - max: 2400, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power UPS 1' - }, - outAcL2_2Pwr: { - min: 0, - max: 2400, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power UPS 2' - }, - outAcTtPwr: { - min: 0, - max: 3600, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power UPS TT-30' - }, - outAcL14Pwr: { - min: 0, - max: 4800, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power Backup L-14' - }, - outAc_5p8Pwr: { - min: 0, - max: 3600, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Output power Power I/O' - }, - inAc_5p8Pwr: { - min: 0, - max: 3600, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Input power Power I/O' - }, - inAcC20Pwr: { - min: 0, - max: 2800, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'Input power AC IN' - }, - inLvMpptPwr: { - min: 0, - max: 1600, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'LV solar power input' - }, - inHvMpptPwr: { - min: 0, - max: 4000, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'HV solar power input' - }, - outPrPwr: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'outPrPwr' - }, - timeTaskChangeCnt: { - min: 0, - unit_of_measurement: '', - mult: 1, - entity_type: 'sensor', - role: 'value', - name: 'Time Task Change Count' - } - }, - diagnostic: { - accessType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Access Type', - role: 'info', - accessType: { '0': 'OK?' } - }, - wireless_4gSta: { - entity_type: 'text', - entity_category: 'diagnostic', - name: '4G connection status', - role: 'info', - wireless_4gSta: { - '0': 'Operator not search?', - '1': 'registered?', - '2': 'searching?', - '3': 'refuses?', - '4': 'unknwon?', - '5': 'roaming registered?' - } - }, - access_5p8InType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Power I/O input type', - role: 'info', - access_5p8InType: { '0': 'idle?', '1': 'AC EV?', '2': 'SHP2?', '3': 'L14 transfer switch?' } - }, - access_5p8OutType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Power I/O output type', - role: 'info', - access_5p8OutType: { '0': 'idle?', '1': 'parallel box?', '2': 'SHP2?' } - }, - wireless_4gCon: { - entity_type: 'text', - entity_category: 'diagnostic', - name: '4G connection', - role: 'info', - wireless_4gCon: { '0': 'none?', '1': '2G?', '2?': '3G?', '4': '4G?' } - }, - wirlesss_4gErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: '4G error code', - role: 'info', - wirlesss_4gErrCode: { - '0': 'OK?', - '1': 'SIM not inserted?', - '2': 'PIN required?', - '3': 'PUK required?', - '4': 'SIM error?', - '6': 'No Operator?', - '7': 'USB disconnect?', - '8': 'unknown device?', - '9': 'CTL error?' - } - }, - pcsType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'PCS type', - role: 'info', - pcsType: { '0': 'OK?' } - }, - sysErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'System error code', - role: 'info', - sysErrCode: { '0': 'OK?' } - }, - timeTaskConflictFlag: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Time Task Conflict', - role: 'info', - timeTaskConflictFlag: { '0': 'OK?' } - }, - chgTimeTaskNotice: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Notice', - role: 'info', - chgTimeTaskNotice: { '0': 'OK?' } - }, - chgTimeTaskType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Type', - role: 'info', - chgTimeTaskType: { '-1': 'nothing set?', '0': 'AC charge?', '1': 'AC discharge?', '2': 'DC discharge?' } - }, - chgTimeTaskIndex: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Index', - role: 'info', - chgTimeTaskIndex: { '-1': 'nothing set?', '0': 'OK?' } - }, - chgTimeTaskMode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Mode', - role: 'info', - chgTimeTaskMode: { '-1': 'nothing set?', '0': 'OK?' } - }, - chgTimeTaskParam: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Charging Time Task Param', - role: 'info', - chgTimeTaskParam: { '0': 'OK?' } - }, - dsgTimeTaskNotice: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Notice', - role: 'info', - dsgTimeTaskNotice: { '0': 'OK?' } - }, - dsgTimeTaskType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Type', - role: 'info', - dsgTimeTaskType: { '-1': 'nothing set?', '0': 'AC charge?', '1': 'AC discharge?', '2': 'DC discharge?' } - }, - dsgTimeTaskIndex: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Index', - role: 'info', - dsgTimeTaskIndex: { '-1': 'nothing set?', '0': 'OK?' } - }, - dsgTimeTaskMode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Mode', - role: 'info', - dsgTimeTaskMode: { '-1': 'nothing set?', '0': 'OK?' } - }, - dsgTimeTaskParam: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Discharging Time Task Param', - role: 'info', - dsgTimeTaskParam: { '0': 'OK?' } - } - }, - switch: { - wireless_4gOn: { - entity_type: 'switch', - device_class: 'switch', - payload_off: 'off', - payload_on: 'on', - name: '4G connection off/on', - role: 'switch', - wireless_4gOn: { '0': 'off', '1': 'on' } - } - } - }, - BackendRecordHeartbeatReport: { - diagnostic: { - recordFlag: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Record flag', - role: 'info', - recordFlag: { '0': 'OK?' } - }, - sysWorkSta: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'System work status', - role: 'info', - sysWorkSta: { '0': 'OK?' } - }, - chgReignSta: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'chgReignSta', - role: 'info', - chgReignSta: { '0': 'OK?' } - }, - pcsWorkSta: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'PCS work status', - role: 'info', - pcsWorkSta: { '0': 'OK?' } - }, - fanState: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Fan state', - role: 'info', - fanState: { '0': 'off?', '1': 'level 1?' } - }, - emsWorkSta: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'EMS work status', - role: 'info', - emsWorkSta: { '0': 'OK?' } - }, - c20InType: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'AC IN type', - role: 'info', - c20InType: { '0': '120V?', '1': '240V?' } - }, - work_5p8Mode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Power I/O work mode', - role: 'info', - work_5p8Mode: { '0': 'comm?', '1': 'solar only?', '2': 'backup?', '3': 'dbg?' } - }, - emsOpenBmsIdx: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Battery pack enable state', - role: 'info', - emsOpenBmsIdx: { '0': 'off', '1': 'OK?' } - }, - pcsDcErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Error code PCS DC', - role: 'info', - pcsDcErrCode: { '0': 'OK?' } - }, - pcsAcErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Error code PCS AC', - role: 'info', - pcsAcErrCode: { '0': 'OK?' } - }, - lvPvErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Error code LV MPPT', - role: 'info', - lvPvErrCode: { '0': 'OK?' } - }, - hvPvErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Error code HV MPPT', - role: 'info', - hvPvErrCode: { '0': 'OK?' } - }, - adsErrCode: { - entity_type: 'text', - entity_category: 'diagnostic', - name: 'Error code DC12V', - role: 'info', - adsErrCode: { '0': 'OK?' } - } - }, - number: { - acInFreq: { - min: 50, - max: 60, - unit_of_measurement: 'Hz', - mult: 1, - entity_type: 'sensor', - device_class: 'frequency', - role: 'value', - name: 'AC input frequency' - }, - emsMaxAvailNum: { - min: 0, - max: 5, - unit_of_measurement: 'pcs', - mult: 1, - entity_type: 'sensor', - role: 'value', - name: 'EMS max avail. number' - }, - emsParaVolMin: { - min: 0, - max: 120, - unit_of_measurement: 'V', - mult: 0.001, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Minimum parallel voltage' - }, - emsParaVolMax: { - min: 0, - max: 120, - unit_of_measurement: 'V', - mult: 0.001, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Maximum parallel voltage' - }, - acOutFreq: { - min: 50, - max: 60, - unit_of_measurement: 'Hz', - mult: 1, - entity_type: 'sensor', - device_class: 'frequency', - role: 'value', - name: 'AC output frequency' - }, - batVol: { - min: 0, - max: 120, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Battery voltage' - }, - batAmp: { - min: 0, - max: 60, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Battery current' - }, - bmsInputWatts: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'BMS input power' - }, - bmsOutputWatts: { - min: 0, - max: 7200, - unit_of_measurement: 'W', - mult: 1, - entity_type: 'sensor', - device_class: 'power', - role: 'value', - name: 'BMS output power' - }, - outUsb1Vol: { - min: 0, - max: 6, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage USB-A 1' - }, - outUsb1Amp: { - min: 0, - max: 3, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current USB-A 1' - }, - outUsb2Vol: { - min: 0, - max: 6, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage USB-A 2' - }, - outUsb2Amp: { - min: 0, - max: 3, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current USB-A 2' - }, - outTypec1Vol: { - min: 0, - max: 25, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage USB-C 1' - }, - outTypec1Amp: { - min: 0, - max: 6, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current USB-C 1' - }, - outTypec2Vol: { - min: 0, - max: 25, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage USB-C 2' - }, - outTypec2Amp: { - min: 0, - max: 6, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current USB-C 2' - }, - outAdsVol: { - min: 0, - max: 13, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage DC12V' - }, - outAdsAmp: { - min: 0, - max: 30, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current DC12V' - }, - outAcL1_1Vol: { - min: 0, - max: 130, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage Backup 1' - }, - outAcL1_1Amp: { - min: 0, - max: 20, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current Backup 1' - }, - outAcL1_2Vol: { - min: 0, - max: 130, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage Backup 2' - }, - outAcL1_2Amp: { - min: 0, - max: 20, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current Backup 2' - }, - outAcL2_1Vol: { - min: 0, - max: 130, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage UPS 1' - }, - outAcL2_1Amp: { - min: 0, - max: 20, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current UPS 1' - }, - outAcL2_2Vol: { - min: 0, - max: 130, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage UPS 2' - }, - outAcL2_2Amp: { - min: 0, - max: 20, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current UPS 2' - }, - outAcTtVol: { - min: 0, - max: 130, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage UPS TT-30' - }, - outAcTtAmp: { - min: 0, - max: 30, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current UPS TT-30' - }, - outAcL14Vol: { - min: 0, - max: 250, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage Backup L-14' - }, - outAcL14Amp: { - min: 0, - max: 20, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current Backup L-14' - }, - outAc_5p8Vol: { - min: 0, - max: 250, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Output voltage PowerI/O' - }, - outAc_5p8Amp: { - min: 0, - max: 30, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Output current PowerI/O' - }, - inAc_5p8Vol: { - min: 0, - max: 250, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Input voltage PowerI/O' - }, - inAc_5p8Amp: { - min: 0, - max: 30, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Input current PowerI/O' - }, - inAcC20Vol: { - min: 0, - max: 250, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'Input voltage AC IN' - }, - inAcC20Amp: { - min: 0, - max: 20, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Input current AC IN' - }, - inLvMpptVol: { - min: 0, - max: 150, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'LV solar input voltage' - }, - inLvMpptAmp: { - min: 0, - max: 15, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'LV solar input current' - }, - inHvMpptVol: { - min: 0, - max: 450, - unit_of_measurement: 'V', - mult: 1, - entity_type: 'sensor', - device_class: 'voltage', - role: 'value', - name: 'HV solar input voltage' - }, - inHvMpptAmp: { - min: 0, - max: 15, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'HV solar input current' - }, - pcsDcTemp: { - min: 0, - max: 90, - unit_of_measurement: '°C', - mult: 1, - entity_type: 'sensor', - device_class: 'temperature', - role: 'value', - name: 'Temperature PCS DC' - }, - pcsAcTemp: { - min: 0, - max: 90, - unit_of_measurement: '°C', - mult: 1, - entity_type: 'sensor', - device_class: 'temperature', - role: 'value', - name: 'Temperature PCS AC' - }, - mpptLvTemp: { - min: 0, - max: 69, - unit_of_measurement: '°C', - mult: 1, - entity_type: 'sensor', - device_class: 'temperature', - role: 'value', - name: 'Temperature LV MPPT' - }, - mpptHvTemp: { - min: 0, - max: 90, - unit_of_measurement: '°C', - mult: 1, - entity_type: 'sensor', - device_class: 'temperature', - role: 'value', - name: 'Temperature HV MPPT' - }, - pdTemp: { - min: 0, - max: 90, - unit_of_measurement: '°C', - mult: 1, - entity_type: 'sensor', - device_class: 'temperature', - role: 'value', - name: 'Temperature PD' - }, - evMaxChargerCur: { - min: 0, - max: 30, - unit_of_measurement: 'A', - mult: 1, - entity_type: 'sensor', - device_class: 'current', - role: 'value', - name: 'Maximum EV charge current' - } - } - }, - BPInfo: { - number: { - bpNo: { - min: 0, - max: 5, - unit_of_measurement: '', - mult: 1, - entity_type: 'sensor', - role: 'value', - name: 'Battery pack number' + unknown36: { + entity_type: 'text', + entity_category: 'diagnostic', + role: 'info', + name: 'unknown36' }, - bpSoc: { - min: 0, - max: 100, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'Battery pack SOC' + unknown37: { + entity_type: 'text', + entity_category: 'diagnostic', + role: 'info', + name: 'unknown37' }, - bpPwr: { - min: 0, - max: 7200, + unixtime_38: { + entity_type: 'text', + entity_category: 'diagnostic', + role: 'info', + name: 'unknown38' + } + }, + level: { + maxWatts: { + min: 1000, + max: 2500, unit_of_measurement: 'W', mult: 1, - entity_type: 'sensor', + step: 100, + entity_type: 'number', device_class: 'power', - role: 'value', - name: 'Battery pack power' - }, - bpEnergy: { - min: 0, - max: 6200, - unit_of_measurement: 'Wh', - mult: 1, - entity_type: 'sensor', - device_class: 'energy', - role: 'value', - name: 'Battery pack energy' - }, - heatTime: { - min: 0, - max: 360, - unit_of_measurement: 'min', - mult: 1, - entity_type: 'sensor', - device_class: 'duration', - role: 'value', - name: 'Battery pack heating time' + name: 'Plug Max. AC power', + unique_id: 'efplug_maxWatts', + role: 'level' }, - remainTime: { + brightness: { min: 0, - unit_of_measurement: 'min', - mult: 1, - entity_type: 'sensor', - device_class: 'duration', - role: 'value', - name: 'Battery pack remain time' - }, - bpSocMax: { - min: 60, max: 100, unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'Battery pack max SOC' + mult: 0.097752, + step: 1, + entity_type: 'number', + device_class: 'illuminance', + name: 'Plug brightness', + unique_id: 'efplug_brightness', + role: 'level', + subrole: 'brightness' + } + }, + switch: { + switch: { + entity_type: 'switch', + device_class: 'switch', + payload_off: 'off', + payload_on: 'on', + name: 'Plug Switch', + unique_id: 'efplug_switch', + role: 'switch', + switch: { '0': 'off', '1': 'on' } }, - bpSocMin: { - min: 0, - max: 30, - unit_of_measurement: '%', - mult: 1, - entity_type: 'sensor', - device_class: 'battery', - role: 'value', - name: 'Battery pack min SOC' + meshEnable: { + entity_type: 'switch', + device_class: 'switch', + payload_off: 'disabled', + payload_on: 'enabled', + name: 'Plug Mesh enable', + unique_id: 'efplug_mesh_enable', + role: 'switch', + meshEnable: { '0': 'disabled', '1': 'enabled' } }, - bpTemp: { - min: 0, - max: 80, - unit_of_measurement: '°C', - mult: 1, - entity_type: 'sensor', - device_class: 'temperature', - role: 'value', - name: 'Battery pack temperature' + dynWattEnable: { + entity_type: 'switch', + device_class: 'switch', + payload_off: 'off', + payload_on: 'on', + name: 'Dynamic watt enable', + unique_id: 'efplug_dynwatt_enable', + role: 'switch', + dynWattEnable: { '0': 'off', '1': 'on' } } }, diagnostic: { - bpChgSta: { + errCode: { entity_type: 'text', entity_category: 'diagnostic', - name: 'Battery pack Charge State', + name: 'Plug Error Code', + unique_id: 'efplug_errCode', role: 'info', - bpChgSta: { '0': 'OK?' } + errCode: { + '0': 'OK ?' + } }, - bpErrCode: { + warnCode: { entity_type: 'text', entity_category: 'diagnostic', - name: 'Battery pack Error Code', + name: 'Plug Warn Code', + unique_id: 'efstream_warnCode', role: 'info', - bpErrCode: { '0': 'OK?' } + warnCode: { + '0': 'OK ?' + } } } }, @@ -3793,172 +2382,6 @@ const pstreamStatesDict = { info: { status: { entity: 'diagnostic' } } - }, - deltaproultra: { - AppParaHeartbeatReport: { - sysWorkMode: { entity: 'diagnostic' }, - sysBackupEvent: { entity: 'diagnostic' }, - sysBackupSoc: { entity: 'number' }, - energyManageEnable: { entity: 'switch' }, - backupRatio: { entity: 'number' }, - acXboost: { entity: 'diagnostic' }, - acOutFreq: { entity: 'number' }, - bmsModeSet: { entity: 'diagnostic' }, - chgMaxSoc: { entity: 'level' }, - dsgMinSoc: { entity: 'level' }, - acOftenOpenFlg: { entity: 'diagnostic' }, - acOftenOpenMinSoc: { entity: 'number' }, - chg_5p8SetWatts: { entity: 'level' }, - chgC20SetWatts: { entity: 'level' }, - powerStandbyMins: { entity: 'level' }, - screenStandbySec: { entity: 'level' }, - dcStandbyMins: { entity: 'level' }, - acStandbyMins: { entity: 'level' }, - solarOnlyFlg: { entity: 'diagnostic' }, - timezoneSettype: { entity: 'diagnostic' }, - sysTimezone: { entity: 'number' }, - sysTimezoneId: { entity: 'string' } - }, - AppShowHeartbeatReport: { - protoVer: { entity: 'string' }, - showFlag: { entity: 'number' }, - accessType: { entity: 'diagnostic' }, - wireless_4gOn: { entity: 'switch' }, - wireless_4gSta: { entity: 'diagnostic' }, - access_5p8InType: { entity: 'diagnostic' }, - access_5p8OutType: { entity: 'diagnostic' }, - wireless_4gCon: { entity: 'diagnostic' }, - wirlesss_4gErrCode: { entity: 'diagnostic' }, - simIccid: { entity: 'string' }, - soc: { entity: 'number' }, - bpNum: { entity: 'number' }, - pcsType: { entity: 'diagnostic' }, - c20ChgMaxWatts: { entity: 'number' }, - paraChgMaxWatts: { entity: 'number' }, - remainTime: { entity: 'number' }, - sysErrCode: { entity: 'diagnostic' }, - fullCombo: { entity: 'number' }, - remainCombo: { entity: 'number' }, - wattsInSum: { entity: 'number' }, - wattsOutSum: { entity: 'number' }, - outUsb1Pwr: { entity: 'number' }, - outUsb2Pwr: { entity: 'number' }, - outTypec1Pwr: { entity: 'number' }, - outTypec2Pwr: { entity: 'number' }, - outAdsPwr: { entity: 'number' }, - outAcL1_1Pwr: { entity: 'number' }, - outAcL1_2Pwr: { entity: 'number' }, - outAcL2_1Pwr: { entity: 'number' }, - outAcL2_2Pwr: { entity: 'number' }, - outAcTtPwr: { entity: 'number' }, - outAcL14Pwr: { entity: 'number' }, - outAc_5p8Pwr: { entity: 'number' }, - inAc_5p8Pwr: { entity: 'number' }, - inAcC20Pwr: { entity: 'number' }, - inLvMpptPwr: { entity: 'number' }, - inHvMpptPwr: { entity: 'number' }, - outPrPwr: { entity: 'number' }, - timeTaskChangeCnt: { entity: 'number' }, - timeTaskConflictFlag: { entity: 'diagnostic' }, - chgTimeTaskNotice: { entity: 'diagnostic' }, - chgTimeTaskType: { entity: 'diagnostic' }, - chgTimeTaskIndex: { entity: 'diagnostic' }, - chgTimeTaskMode: { entity: 'diagnostic' }, - chgTimeTaskParam: { entity: 'diagnostic' }, - chgTimeTaskTable_0: { entity: 'string' }, - chgTimeTaskTable_1: { entity: 'string' }, - chgTimeTaskTable_2: { entity: 'string' }, - dsgTimeTaskNotice: { entity: 'diagnostic' }, - dsgTimeTaskType: { entity: 'diagnostic' }, - dsgTimeTaskIndex: { entity: 'diagnostic' }, - dsgTimeTaskMode: { entity: 'diagnostic' }, - dsgTimeTaskParam: { entity: 'diagnostic' }, - dsgTimeTaskTable_0: { entity: 'string' }, - dsgTimeTaskTable_1: { entity: 'string' }, - dsgTimeTaskTable_2: { entity: 'string' } - }, - BackendRecordHeartbeatReport: { - recordFlag: { entity: 'diagnostic' }, - sysWorkSta: { entity: 'diagnostic' }, - chgReignSta: { entity: 'diagnostic' }, - pcsWorkSta: { entity: 'diagnostic' }, - fanState: { entity: 'diagnostic' }, - emsWorkSta: { entity: 'diagnostic' }, - c20InType: { entity: 'diagnostic' }, - work_5p8Mode: { entity: 'diagnostic' }, - acInFreq: { entity: 'number' }, - emsMaxAvailNum: { entity: 'number' }, - emsOpenBmsIdx: { entity: 'diagnostic' }, - emsParaVolMin: { entity: 'number' }, - emsParaVolMax: { entity: 'number' }, - acOutFreq: { entity: 'number' }, - pcsDcErrCode: { entity: 'diagnostic' }, - pcsAcErrCode: { entity: 'diagnostic' }, - lvPvErrCode: { entity: 'diagnostic' }, - hvPvErrCode: { entity: 'diagnostic' }, - adsErrCode: { entity: 'diagnostic' }, - batVol: { entity: 'number' }, - batAmp: { entity: 'number' }, - bmsInputWatts: { entity: 'number' }, - bmsOutputWatts: { entity: 'number' }, - outUsb1Vol: { entity: 'number' }, - outUsb1Amp: { entity: 'number' }, - outUsb2Vol: { entity: 'number' }, - outUsb2Amp: { entity: 'number' }, - outTypec1Vol: { entity: 'number' }, - outTypec1Amp: { entity: 'number' }, - outTypec2Vol: { entity: 'number' }, - outTypec2Amp: { entity: 'number' }, - outAdsVol: { entity: 'number' }, - outAdsAmp: { entity: 'number' }, - outAcL1_1Vol: { entity: 'number' }, - outAcL1_1Amp: { entity: 'number' }, - outAcL1_2Vol: { entity: 'number' }, - outAcL1_2Amp: { entity: 'number' }, - outAcL2_1Vol: { entity: 'number' }, - outAcL2_1Amp: { entity: 'number' }, - outAcL2_2Vol: { entity: 'number' }, - outAcL2_2Amp: { entity: 'number' }, - outAcTtVol: { entity: 'number' }, - outAcTtAmp: { entity: 'number' }, - outAcL14Vol: { entity: 'number' }, - outAcL14Amp: { entity: 'number' }, - outAc_5p8Vol: { entity: 'number' }, - outAc_5p8Amp: { entity: 'number' }, - inAc_5p8Vol: { entity: 'number' }, - inAc_5p8Amp: { entity: 'number' }, - inAcC20Vol: { entity: 'number' }, - inAcC20Amp: { entity: 'number' }, - inLvMpptVol: { entity: 'number' }, - inLvMpptAmp: { entity: 'number' }, - inHvMpptVol: { entity: 'number' }, - inHvMpptAmp: { entity: 'number' }, - pcsDcTemp: { entity: 'number' }, - pcsAcTemp: { entity: 'number' }, - mpptLvTemp: { entity: 'number' }, - mpptHvTemp: { entity: 'number' }, - pdTemp: { entity: 'number' }, - evMaxChargerCur: { entity: 'number' } - }, - BPInfo: { - bpNo: { entity: 'number' }, - bpChgSta: { entity: 'diagnostic' }, - bpSoc: { entity: 'number' }, - bpPwr: { entity: 'number' }, - bpEnergy: { entity: 'number' }, - heatTime: { entity: 'number' }, - remainTime: { entity: 'number' }, - bpSocMax: { entity: 'number' }, - bpSocMin: { entity: 'number' }, - bpErrCode: { entity: 'diagnostic' }, - bpTemp: { entity: 'number' } - }, - action: { - latestQuotas: { entity: 'switch' } - }, - info: { - status: { entity: 'diagnostic' } - } } }; @@ -6145,42 +4568,42 @@ const pstationStates = { }, chgPowerAC: { min: 0, - max: 65000, unit_of_measurement: 'kWh', mult: 0.001, entity_type: 'sensor', device_class: 'energy', + state_class: 'total_increasing', name: 'Cumulative AC power charged for PD (wall socket)', role: 'value' }, chgPowerDC: { min: 0, - max: 65000, unit_of_measurement: 'kWh', mult: 0.001, entity_type: 'sensor', device_class: 'energy', + state_class: 'total_increasing', name: 'Cumulative DC power charged for PD (adapter)', role: 'value' }, dsgPowerAC: { min: 0, - max: 4000, - unit_of_measurement: 'W', - mult: 0.1, + unit_of_measurement: 'kWh', + mult: 0.001, entity_type: 'sensor', - device_class: 'power', - name: 'Discharge Power AC', + device_class: 'energy', + state_class: 'total_increasing', + name: 'Cumulative AC power discharged ', role: 'value' }, dsgPowerDC: { min: 0, - max: 4000, - unit_of_measurement: 'W', - mult: 0.1, + unit_of_measurement: 'kWh', + mult: 0.001, entity_type: 'sensor', - device_class: 'power', - name: 'Discharge Power DC', + device_class: 'energy', + state_class: 'total_increasing', + name: 'Cumulative DC discharge capacity', role: 'value' }, //new delta 2 max @@ -11864,8 +10287,7 @@ const pstationStatesDict = { pv2ChargeType: { entity: 'diagnostic' }, pv2ChargeWatts: { entity: 'number' }, pvChargePrioSet: { entity: 'diagnostic' }, - minAcoutSoc: { entity: 'number' }, - bpPowerSoc: { entity: 'level' } + minAcoutSoc: { entity: 'number' } }, action: { latestQuotas: { entity: 'switch' }, @@ -12967,6 +11389,30 @@ const pstationStatesDict = { info: { status: { entity: 'diagnostic' } } + }, + delta3: { + action: { + latestQuotas: { entity: 'switch' } + }, + info: { + status: { entity: 'diagnostic' } + } + }, + delta3plus: { + action: { + latestQuotas: { entity: 'switch' } + }, + info: { + status: { entity: 'diagnostic' } + } + }, + deltapro3: { + action: { + latestQuotas: { entity: 'switch' } + }, + info: { + status: { entity: 'diagnostic' } + } } }; @@ -13251,13 +11697,6 @@ const pstreamRanges = { } } } - }, - deltaproultra: { - AppShowHeartbeatReport: { - number: { - c20ChgMaxWatts: { max: 7200 } - } - } } }; @@ -13369,33 +11808,6 @@ const pstreamCmd = { action: { latestQuotas: { msg: { cmdFunc: 20, cmdId: 1, dataLen: 0 } } } - }, - deltaproultra: { - AppShowHeartbeatReport: { - wireless_4gOn: { msg: { dest: 53, cmdFunc: 2, cmdId: 117, dataLen: 2 } } - }, - AppParaHeartbeatReport: { - energyManageEnable: { msg: { dest: 2, cmdFunc: 2, cmdId: 94, dataLen: 4 } }, // field 1 = enable, field2 = limit backupRatio - chgMaxSoc: { msg: { dest: 2, cmdFunc: 2, cmdId: 87, dataLen: 2 } }, - dsgMinSoc: { msg: { dest: 2, cmdFunc: 2, cmdId: 88, dataLen: 2 } }, - chg_5p8SetWatts: { msg: { dest: 2, cmdFunc: 2, cmdId: 73, dataLen: 3 } }, //field 1 - chgC20SetWatts: { msg: { dest: 2, cmdFunc: 2, cmdId: 73, dataLen: 3 } }, //field 2 - powerStandbyMins: { msg: { dest: 2, cmdFunc: 2, cmdId: 81, dataLen: 2 } }, - screenStandbySec: { msg: { dest: 2, cmdFunc: 2, cmdId: 82, dataLen: 3 } }, - dcStandbyMins: { msg: { dest: 2, cmdFunc: 2, cmdId: 84, dataLen: 2 } }, - acStandbyMins: { msg: { dest: 2, cmdFunc: 2, cmdId: 83, dataLen: 2 } }, - //missing datapoints for mapping - dcON: { msg: { dest: 2, cmdFunc: 2, cmdId: 68, dataLen: 2 } }, - acAlwaysOn: { msg: { dest: 2, cmdFunc: 2, cmdId: 93, dataLen: 2 } }, //acAlwaysOnTime - BatteryPreCond_ON: { msg: { dest: 2, cmdFunc: 2, cmdId: 89, dataLen: 2 } }, - // should be done through the app - timezone: { msg: { dest: 2, cmdFunc: 2, cmdId: 86, dataLen: 2 } }, //+ timezoneSetAuto - town: { msg: { dest: 2, cmdFunc: 2, cmdId: 87, dataLen: 2 } }, //länge des strings - rename: { msg: { dest: 2, cmdFunc: 2, cmdId: 65, dataLen: 2 } } //länge des strings - }, - action: { - latestQuotas: { msg: { cmdFunc: 2, cmdId: 1, dataLen: 0 } } - } } }; @@ -15220,6 +13632,51 @@ const pstationCmd = { } } } + }, + deltapro3: { + action: { + latestQuotas: { + moduleType: 0, + msg: { + from: 'iOS', + operateType: 'latestQuotas', + id: '83154039', + lang: 'de-de', + params: {}, + version: '1.0' + } + } + } + }, + delta3plus: { + action: { + latestQuotas: { + moduleType: 0, + msg: { + from: 'iOS', + operateType: 'latestQuotas', + id: '83154039', + lang: 'de-de', + params: {}, + version: '1.0' + } + } + } + }, + delta3: { + action: { + latestQuotas: { + moduleType: 0, + msg: { + from: 'iOS', + operateType: 'latestQuotas', + id: '83154039', + lang: 'de-de', + params: {}, + version: '1.0' + } + } + } } }; diff --git a/lib/ecoflow_utils.js b/lib/ecoflow_utils.js index 04d3e8c..8248e5c 100644 --- a/lib/ecoflow_utils.js +++ b/lib/ecoflow_utils.js @@ -598,7 +598,7 @@ message BPInfo optional int32 bp_temp = 11; } -message BpInfoReport +message BPInfoReport { repeated BPInfo bp_info = 1; } @@ -931,8 +931,8 @@ message MasterTimeInfo message LoadTimeInfo { - repeated int32 hall1_watt = 1; - repeated int32 hall1_curr = 2; + repeated float hall1_watt = 1; + repeated float hall1_curr = 2; } message BackupTimeInfo @@ -946,9 +946,9 @@ message BackupTimeInfo message WattTimeInfo { - optional int32 grid_watt = 1; - optional int32 ch_watt = 11; - optional int32 all_hall_watt = 21; + optional float grid_watt = 1; + optional float ch_watt = 11; + optional float all_hall_watt = 21; } message MasterVerTimeInfo @@ -1883,6 +1883,37 @@ message setReply_dp3 { optional int32 switchGFCIRCDStatus = 61; } +//ALTERNATOR + +message alternatorHeartbeat { + optional int32 status1 =1; + optional int32 temp = 102; + optional float actPower = 105; + optional int32 unknown130 = 130; + optional int32 startVoltage = 138; // *0.1 + optional float carBatVolt = 139; + optional float batSoc = 262; + optional int32 unknown268 = 268; + optional int32 unknown269 = 269; + optional float current425 = 425; + optional int32 unknown427 = 427; + optional int32 unknown428 = 428; + optional int32 operationMode = 581; + optional int32 startStop = 597; + optional float permanentWatts = 598; + optional float wifiRssi = 602; + optional float ratedPower = 603; + optional float unknown608 = 608; + optional float unknown609 = 609; +} + +message alternatorSet { + optional int32 operationModeCmd = 116; // 1=Charge; 2=reverse charge; 3=battery maintenance; + optional int32 startStopCmd = 122; // 0=off; 1= on + optional float permanentWattsCmd = 123; // 0 - 800 Watt + optional int32 startVoltageCmd = 137; // 11 - 30 V *10 +} + `; function decodeMsg(hexString, msgtype) { @@ -2392,6 +2423,17 @@ function pstreamDecode(adapter, payload, usage, topic, msgtype, log) { break; } break; + case 21: + switch (deviceType) { + case 254: + //alternator + prototyp = 'alternatorHeartbeat'; + break; + default: + prototyp = 'undef'; + break; + } + break; case 18: switch (deviceType) { case 254: @@ -2481,7 +2523,7 @@ function pstreamDecode(adapter, payload, usage, topic, msgtype, log) { //prototyp = 'InverterHeartbeat2'; break; case 2: - prototyp = 'BPInfo'; + prototyp = 'BPInfoReport'; //prototyp = 'dpu_4'; break; default: @@ -2836,8 +2878,8 @@ async function storeStreamPayload(adapter, stateDictObj, stateObj, topic, payloa case 'AppParaHeartbeatReport': case 'AppShowHeartbeatReport': case 'BackendRecordHeartbeatReport': - case 'BPInfo': case 'JTS1_ENERGY_STREAM_REPORT': + case 'alternatorHeartbeat': // all cases without nested states await setOnlineStatus(adapter, topic); for (let state in payload[channel]) { @@ -2859,6 +2901,35 @@ async function storeStreamPayload(adapter, stateDictObj, stateObj, topic, payloa if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); } break; + case 'BPInfoReport': + await setOnlineStatus(adapter, topic); + //BPInfo mit bpNo verknüpfen + for (let i = 0; i < payload[channel]['bpInfo'].length; i++) { + //BPInfo mit bpNo verknüpfen, wenn 1 dann ohne Anhang wegen Kompatibilität + let name = + payload[channel]['bpInfo'][i]['bpNo'] == 1 + ? 'BPInfo' + : ''.concat('BPInfo', String(payload[channel]['bpInfo'][i]['bpNo'])); + for (let state in payload[channel]['bpInfo'][i]) { + let val; + let haupd; + val = payload[channel]['bpInfo'][i][state]; + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + name, //channel, + state, + val, + 'BPInfo', //channel, + logged + ); + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + } + } + break; case 'JTS1_BP_STA_REPORT': await setOnlineStatus(adapter, topic); for (let i = 0; i < payload[channel]['bpSta'].length; i++) { @@ -3120,6 +3191,36 @@ async function storeStreamPayload(adapter, stateDictObj, stateObj, topic, payloa logged ); if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + let power = 0; + for (let i = 0; i < val.length; i++) { + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + 'loadPower', + 'chWatt'.concat('_', String(i)), + val[i], + 'loadPower', + logged + ); + power = power + val[i]; + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + } + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + 'loadPower', + 'sumWatt', + power, + 'loadPower', + logged + ); + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); } if ( Object.prototype.hasOwnProperty.call( @@ -3141,6 +3242,36 @@ async function storeStreamPayload(adapter, stateDictObj, stateObj, topic, payloa logged ); if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + let current = 0; + for (let i = 0; i < val.length; i++) { + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + 'loadCurrent', + 'cur'.concat('_', String(i)), + val[i], + 'loadCurrent', + logged + ); + current = current + val[i]; + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + } + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + 'loadCurrent', + 'sumCur', + current, + 'loadCurrent', + logged + ); + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); } break; case 'backupInfo': @@ -3307,6 +3438,45 @@ async function storeStreamPayload(adapter, stateDictObj, stateObj, topic, payloa ); if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); } + if ( + Object.prototype.hasOwnProperty.call(payload[channel]['wattInfo'], 'chWatt') + ) { + val = payload[channel][state]['chWatt']; + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + channel, + 'wattInfoChWatt', + val, + channel, + logged + ); + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + } + if ( + Object.prototype.hasOwnProperty.call( + payload[channel]['wattInfo'], + 'allHallWatt' + ) + ) { + val = payload[channel][state]['allHallWatt']; + haupd = await compareUpdate( + adapter, + stateDictObj, + stateObj, + haenable, + topic, + channel, + 'wattInfoAllHallWatt', + val, + channel, + logged + ); + if (Object.keys(haupd).length !== 0) haUpdate.push(haupd); + } break; case 'masterVerInfo': if ( diff --git a/lib/ef_alternator_data.js b/lib/ef_alternator_data.js new file mode 100644 index 0000000..c11ce88 --- /dev/null +++ b/lib/ef_alternator_data.js @@ -0,0 +1,279 @@ +const alternatorStates = { + //new alternator + alternatorHeartbeat: { + number: { + unknown268: { + min: 0, + max: 144000, + unit_of_measurement: 'min', + mult: 1, + entity_type: 'sensor', + device_class: 'duration', + name: 'Battery Charging Time', + role: 'value' + }, + unknown269: { + min: 0, + max: 144000, + unit_of_measurement: 'min', + mult: 1, + entity_type: 'sensor', + device_class: 'duration', + name: 'Battery Discharging Time', + role: 'value', + icon: 'mdi:clock-start' + }, + carBatVolt: { + min: 10, + max: 30, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + name: 'Car battery voltage', + role: 'value' + }, + ratedPower: { + min: 0, + max: 800, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'number', + device_class: 'power', + name: 'Alternator rated power', + role: 'value' + }, + actPower: { + min: 0, + max: 800, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'number', + device_class: 'power', + name: 'Alternator actual power', + role: 'value' + }, + wifiRssi: { + min: -90, + max: 10, + unit_of_measurement: 'dBm', + mult: 1, + entity_type: 'sensor', + device_class: 'signal_strength', + name: 'Wifi RSSI', + role: 'value' + }, + temp: { + min: 0, + max: 80, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + name: 'Temperature', + role: 'value' + }, + batSoc: { + min: 0, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + name: 'Powerstation battery state of charge', + role: 'value' + }, + current425: { + min: 0, + max: 13, + unit_of_measurement: 'A', + mult: 0.001, + entity_type: 'sensor', + device_class: 'current', + name: 'current', + role: 'value' + } + }, + level: { + permanentWatts: { + min: 0, + max: 800, + unit_of_measurement: 'W', + mult: 1, + step: 100, + entity_type: 'number', + device_class: 'power', + name: 'Permanent Power Limit', + role: 'level' + }, + startVoltage: { + min: 11, + max: 30, + unit_of_measurement: 'V', + mult: 0.1, + step: 0.1, + entity_type: 'number', + device_class: 'voltage', + name: 'Start voltage', + role: 'level' + }, + operationMode: { + min: 1, + max: 3, + unit_of_measurement: '', + mult: 1, + step: 1, + entity_type: 'select', + select: [ 'charge', 'reverse charge', 'battery maintenance' ], + select_obj: { + charge: 1, + 'reverse charge': 2, + 'battery maintenance': 3 + }, + states: { + 1: 'charge', + 2: 'reverse charge', + 3: 'battery maintenance' + }, + name: 'Operation mode', + role: 'level' + } + }, + switch: { + startStop: { + entity_type: 'switch', + device_class: 'switch', + payload_off: 'off', + payload_on: 'on', + name: 'Start/Stop cmd', + role: 'switch', + startStop: { '0': 'off', '1': 'on' } + } + }, + string: { + status1: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'X_status1', + role: 'info' + }, + unknown130: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'X_unknown130', + role: 'info' + }, + unknown427: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'X_unknown427', + role: 'info' + }, + unknown428: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'X_unknown428', + role: 'info' + }, + unknown608: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'X_unknown608', + role: 'info' + }, + unknown609: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'X_unknown609', + role: 'info' + } + } + }, + action: { + switch: { + latestQuotas: { + entity_type: 'switch', + device_class: 'switch', + role: 'switch', + name: 'Get latest Quotas', + payload_off: 'no trigger', + payload_on: 'trigger', + latestQuotas: { '0': 'no trigger', '1': 'trigger' } + } + } + }, + info: { + diagnostic: { + status: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Status', + role: 'info', + status: { 0: 'offline', 1: 'online' } + } + } + } +}; + +const alternatorStatesDict = { + alternator: { + alternatorHeartbeat: { + status1: { entity: 'string' }, + temp: { entity: 'number' }, + actPower: { entity: 'number' }, + unknown130: { entity: 'string' }, + startVoltage: { entity: 'level' }, + carBatVolt: { entity: 'number' }, + batSoc: { entity: 'number' }, + unknown268: { entity: 'number' }, + unknown269: { entity: 'number' }, + current425: { entity: 'number' }, + unknown427: { entity: 'string' }, + unknown428: { entity: 'string' }, + operationMode: { entity: 'level' }, + startStop: { entity: 'switch' }, + permanentWatts: { entity: 'level' }, + wifiRssi: { entity: 'number' }, + ratedPower: { entity: 'number' }, + unknown608: { entity: 'string' }, + unknown609: { entity: 'string' } + }, + action: { + latestQuotas: { entity: 'switch' } + }, + info: { + status: { entity: 'diagnostic' } + } + } +}; + +const alternatorRanges = { + alternator: { + alternatorHeartbeat: { + number: { + current425: { max: 30 } + } + } + } +}; + +const alternatorCmd = { + alternator: { + alternatorHeartbeat: { + startVoltage: { msg: { dest: 20, cmdFunc: 2, cmdId: 17, dataLen: 6 } }, //137 + operationMode: { msg: { dest: 20, cmdFunc: 2, cmdId: 17, dataLen: 6 } }, //116 + startStop: { msg: { dest: 20, cmdFunc: 2, cmdId: 17, dataLen: 6 } }, //122 + permanentWatts: { msg: { dest: 20, cmdFunc: 2, cmdId: 17, dataLen: 6 } } //123 + }, + action: { + latestQuotas: { msg: { cmdFunc: 2, cmdId: 1, dataLen: 0 } } //toCheck + } + } +}; + +module.exports = { + alternatorStates, + alternatorStatesDict, + alternatorRanges, + alternatorCmd +}; diff --git a/lib/ef_dpu_data.js b/lib/ef_dpu_data.js new file mode 100644 index 0000000..78f77e9 --- /dev/null +++ b/lib/ef_dpu_data.js @@ -0,0 +1,1708 @@ +const deltaproultraStates = { + //new delta pro ultra + AppParaHeartbeatReport: { + diagnostic: { + sysWorkMode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'System Work Mode', + role: 'info', + sysWorkMode: { '0': 'OK?' } + }, + sysBackupEvent: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'System Backup Event', + role: 'info', + sysBackupEvent: { '0': 'OK?' } + }, + acXboost: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'AC X-Boost', + role: 'info', + acXboost: { '0': 'disabled?', '1': 'enabled?' } + }, + bmsModeSet: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'BMS Mode Setting', + role: 'info', + bmsModeSet: { '0': '?' } + }, + acOftenOpenFlg: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'acOftenOpenFlg', + role: 'info', + acOftenOpenFlg: { '0': 'OK?' } + }, + solarOnlyFlg: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Solar only', + role: 'info', + solarOnlyFlg: { '0': 'all?', '1': 'solar only?' } + }, + timezoneSettype: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Timezone tracking', + role: 'info', + timezoneSettype: { '0': 'no tracking?', '1': 'tracking?' } + } + }, + number: { + sysBackupSoc: { + min: 0, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'System backup SOC' + }, + acOutFreq: { + min: 50, + max: 60, + unit_of_measurement: 'Hz', + mult: 1, + entity_type: 'sensor', + device_class: 'frequency', + role: 'value', + name: 'AC output frequency' + }, + acOftenOpenMinSoc: { + min: 0, + max: 30, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'acOftenOpenMinSoc' + }, + sysTimezone: { + min: -12, + max: 12, + unit_of_measurement: 'h', + mult: 0.01, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Timezone offset' + }, + //to be deleted when level + backupRatio: { + min: 20, + max: 90, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'Backup limit (ratio?)' + } + }, + switch: { + energyManageEnable: { + entity_type: 'switch', + device_class: 'switch', + payload_off: 'off', + payload_on: 'on', + name: 'Enable energy management', + role: 'switch', + energyManageEnable: { '0': 'off', '1': 'on' } + } + }, + level: { + backupRatio: { + min: 20, + max: 90, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'level', + name: 'Backup limit (ratio?)' + }, + chgMaxSoc: { + min: 50, + max: 100, + unit_of_measurement: '%', + mult: 1, + step: 1, + entity_type: 'sensor', + device_class: 'battery', + name: 'Maximum charge SOC', + role: 'level' + }, + dsgMinSoc: { + min: 0, + max: 30, + unit_of_measurement: '%', + mult: 1, + step: 1, + entity_type: 'sensor', + device_class: 'battery', + name: 'Minimum discharge SOC', + role: 'level' + }, + chg_5p8SetWatts: { + min: 200, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + step: 1, + entity_type: 'sensor', + device_class: 'power', + name: 'Default charge power PowerI/O', + role: 'level' + }, + chgC20SetWatts: { + min: 200, + max: 2400, + unit_of_measurement: 'W', + mult: 1, + step: 1, + entity_type: 'sensor', + device_class: 'power', + name: 'Default charge power AC IN', + role: 'level' + }, + powerStandbyMins: { + min: 0, + max: 800, + unit_of_measurement: 'min', + mult: 1, + step: 1, + entity_type: 'select', + device_class: 'duration', + select: [ 'Never', '30 min', '1 hr', '2 hr', '4 hr', '6 hr', '12 hr' ], + select_obj: { + Never: 0, + '30 min': 30, + '1 hr': 60, + '2 hr': 120, + '4 hr': 240, + '6 hr': 360, + '12 hr': 720 + }, + states: { + 0: 'Never', + 30: '30 min', + 60: '1 hr', + 120: '2 hr', + 240: '4 hr', + 360: '6 hr', + 720: '12 hr' + }, + name: 'System standby time', + role: 'level', + subrole: 'timer' + }, + screenStandbySec: { + min: 0, + max: 1800, + unit_of_measurement: 's', + mult: 1, + step: 60, + entity_type: 'select', + device_class: 'duration', + select: [ 'Never', '10 sec', '30 sec', '1 min', '5 min', '30 min' ], + select_obj: { + Never: 0, + '10 sec': 10, + '30 sec': 30, + '1 min': 60, + '5 min': 300, + '30 min': 1800 + }, + states: { + 0: 'Never', + 10: '10 sec', + 30: '30 sec', + 60: '1 min', + 300: '5 min', + 1800: '30 min' + }, + name: 'Screen standby time', + role: 'level', + subrole: 'timer' + }, + dcStandbyMins: { + min: 0, + max: 1440, + unit_of_measurement: 'min', + mult: 1, + step: 120, + entity_type: 'select', + device_class: 'duration', + select: [ 'Never', '30 min', '1 hr', '2 hr', '4 hr', '6 hr', '12 hr', '24 hr' ], + select_obj: { + Never: 0, + '30 min': 30, + '1 hr': 60, + '2 hr': 120, + '4 hr': 240, + '6 hr': 360, + '12 hr': 720, + '24 hr': 1440 + }, + states: { + 0: 'Never', + 30: '30 min', + 60: '1 hr', + 120: '2 hr', + 240: '4 hr', + 360: '6 hr', + 720: '12 hr', + 1440: '24 hr' + }, + name: 'DC12V standby time', + role: 'level', + subrole: 'timer' + }, + acStandbyMins: { + min: 0, + max: 800, + unit_of_measurement: 'W', + mult: 1, + step: 1, + entity_type: 'select', + device_class: 'duration', + select: [ 'Never', '30 min', '1 hr', '2 hr', '4 hr', '6 hr', '12 hr', '24 hr' ], + select_obj: { + Never: 0, + '30 min': 30, + '1 hr': 60, + '2 hr': 120, + '4 hr': 240, + '6 hr': 360, + '12 hr': 720, + '24 hr': 1440 + }, + states: { + 0: 'Never', + 30: '30 min', + 60: '1 hr', + 120: '2 hr', + 240: '4 hr', + 360: '6 hr', + 720: '12 hr', + 1440: '24 hr' + }, + name: 'AC standby time', + role: 'level', + subrole: 'timer' + } + }, + string: { + sysTimezoneId: { entity_type: 'text', entity_category: 'diagnostic', name: 'Timezone', role: 'info' } + } + }, + AppShowHeartbeatReport: { + string: { + protoVer: { entity_type: 'text', entity_category: 'diagnostic', name: 'Version', role: 'info' }, + simIccid: { entity_type: 'text', entity_category: 'diagnostic', name: 'simIccid:', role: 'info' }, + chgTimeTaskTable_0: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Table 0', + role: 'info' + }, + chgTimeTaskTable_1: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Table 1', + role: 'info' + }, + chgTimeTaskTable_2: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Table 2', + role: 'info' + }, + dsgTimeTaskTable_0: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Table 0', + role: 'info' + }, + dsgTimeTaskTable_1: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Table 1', + role: 'info' + }, + dsgTimeTaskTable_2: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Table 2', + role: 'info' + } + }, + number: { + //as a number until it is clear how the bits are used + showFlag: { + min: 0, + unit_of_measurement: '', + mult: 1, + entity_type: 'sensor', + role: 'value', + name: 'show flag' + }, + soc: { + min: 0, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'SOC' + }, + bpNum: { + min: 0, + max: 5, + unit_of_measurement: '', + mult: 1, + entity_type: 'sensor', + role: 'value', + name: 'Battery pack count' + }, + c20ChgMaxWatts: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Max charging power AC IN' + }, + paraChgMaxWatts: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Max parallel charging power' + }, + remainTime: { + min: 0, + unit_of_measurement: 'min', + mult: 1, + entity_type: 'sensor', + device_class: 'time', + role: 'value', + name: 'Remaining time' + }, + fullCombo: { + min: 0, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'fullCombo' + }, + remainCombo: { + min: 0, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'remainCombo' + }, + wattsInSum: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Total power input' + }, + wattsOutSum: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Total power output' + }, + outUsb1Pwr: { + min: 0, + max: 12, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power USB-A 1' + }, + outUsb2Pwr: { + min: 0, + max: 12, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power USB-A 2' + }, + outTypec1Pwr: { + min: 0, + max: 100, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power USB-C 1' + }, + outTypec2Pwr: { + min: 0, + max: 100, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power USB-C 2' + }, + outAdsPwr: { + min: 0, + max: 378, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power DC12V' + }, + outAcL1_1Pwr: { + min: 0, + max: 2400, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power Backup 1' + }, + outAcL1_2Pwr: { + min: 0, + max: 2400, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power Backup 2' + }, + outAcL2_1Pwr: { + min: 0, + max: 2400, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power UPS 1' + }, + outAcL2_2Pwr: { + min: 0, + max: 2400, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power UPS 2' + }, + outAcTtPwr: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power UPS TT-30' + }, + outAcL14Pwr: { + min: 0, + max: 4800, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power Backup L-14' + }, + outAc_5p8Pwr: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Output power Power I/O' + }, + inAc_5p8Pwr: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Input power Power I/O' + }, + inAcC20Pwr: { + min: 0, + max: 2800, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Input power AC IN' + }, + inLvMpptPwr: { + min: 0, + max: 1600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'LV solar power input' + }, + inHvMpptPwr: { + min: 0, + max: 4000, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'HV solar power input' + }, + outPrPwr: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'outPrPwr' + }, + timeTaskChangeCnt: { + min: 0, + unit_of_measurement: '', + mult: 1, + entity_type: 'sensor', + role: 'value', + name: 'Time Task Change Count' + } + }, + diagnostic: { + accessType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Access Type', + role: 'info', + accessType: { '0': 'OK?' } + }, + wireless_4gSta: { + entity_type: 'text', + entity_category: 'diagnostic', + name: '4G connection status', + role: 'info', + wireless_4gSta: { + '0': 'Operator not search?', + '1': 'registered?', + '2': 'searching?', + '3': 'refuses?', + '4': 'unknwon?', + '5': 'roaming registered?' + } + }, + access_5p8InType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Power I/O input type', + role: 'info', + access_5p8InType: { '0': 'idle?', '1': 'AC EV?', '2': 'SHP2?', '3': 'L14 transfer switch?' } + }, + access_5p8OutType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Power I/O output type', + role: 'info', + access_5p8OutType: { '0': 'idle?', '1': 'parallel box?', '2': 'SHP2?' } + }, + wireless_4gCon: { + entity_type: 'text', + entity_category: 'diagnostic', + name: '4G connection', + role: 'info', + wireless_4gCon: { '0': 'none?', '1': '2G?', '2?': '3G?', '4': '4G?' } + }, + wirlesss_4gErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: '4G error code', + role: 'info', + wirlesss_4gErrCode: { + '0': 'OK?', + '1': 'SIM not inserted?', + '2': 'PIN required?', + '3': 'PUK required?', + '4': 'SIM error?', + '6': 'No Operator?', + '7': 'USB disconnect?', + '8': 'unknown device?', + '9': 'CTL error?' + } + }, + pcsType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'PCS type', + role: 'info', + pcsType: { '0': 'OK?' } + }, + sysErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'System error code', + role: 'info', + sysErrCode: { '0': 'OK?' } + }, + timeTaskConflictFlag: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Time Task Conflict', + role: 'info', + timeTaskConflictFlag: { '0': 'OK?' } + }, + chgTimeTaskNotice: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Notice', + role: 'info', + chgTimeTaskNotice: { '0': 'OK?' } + }, + chgTimeTaskType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Type', + role: 'info', + chgTimeTaskType: { '-1': 'nothing set?', '0': 'AC charge?', '1': 'AC discharge?', '2': 'DC discharge?' } + }, + chgTimeTaskIndex: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Index', + role: 'info', + chgTimeTaskIndex: { '-1': 'nothing set?', '0': 'OK?' } + }, + chgTimeTaskMode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Mode', + role: 'info', + chgTimeTaskMode: { '-1': 'nothing set?', '0': 'OK?' } + }, + chgTimeTaskParam: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Charging Time Task Param', + role: 'info', + chgTimeTaskParam: { '0': 'OK?' } + }, + dsgTimeTaskNotice: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Notice', + role: 'info', + dsgTimeTaskNotice: { '0': 'OK?' } + }, + dsgTimeTaskType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Type', + role: 'info', + dsgTimeTaskType: { '-1': 'nothing set?', '0': 'AC charge?', '1': 'AC discharge?', '2': 'DC discharge?' } + }, + dsgTimeTaskIndex: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Index', + role: 'info', + dsgTimeTaskIndex: { '-1': 'nothing set?', '0': 'OK?' } + }, + dsgTimeTaskMode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Mode', + role: 'info', + dsgTimeTaskMode: { '-1': 'nothing set?', '0': 'OK?' } + }, + dsgTimeTaskParam: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Discharging Time Task Param', + role: 'info', + dsgTimeTaskParam: { '0': 'OK?' } + } + }, + switch: { + wireless_4gOn: { + entity_type: 'switch', + device_class: 'switch', + payload_off: 'off', + payload_on: 'on', + name: '4G connection off/on', + role: 'switch', + wireless_4gOn: { '0': 'off', '1': 'on' } + } + } + }, + BackendRecordHeartbeatReport: { + diagnostic: { + recordFlag: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Record flag', + role: 'info', + recordFlag: { '0': 'OK?' } + }, + sysWorkSta: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'System work status', + role: 'info', + sysWorkSta: { '0': 'OK?' } + }, + chgReignSta: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'chgReignSta', + role: 'info', + chgReignSta: { '0': 'OK?' } + }, + pcsWorkSta: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'PCS work status', + role: 'info', + pcsWorkSta: { '0': 'OK?' } + }, + fanState: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Fan state', + role: 'info', + fanState: { '0': 'off?', '1': 'level 1?' } + }, + emsWorkSta: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'EMS work status', + role: 'info', + emsWorkSta: { '0': 'OK?' } + }, + c20InType: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'AC IN type', + role: 'info', + c20InType: { '0': '120V?', '1': '240V?' } + }, + work_5p8Mode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Power I/O work mode', + role: 'info', + work_5p8Mode: { '0': 'comm?', '1': 'solar only?', '2': 'backup?', '3': 'dbg?' } + }, + emsOpenBmsIdx: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Battery pack enable state', + role: 'info', + emsOpenBmsIdx: { '0': 'off', '1': 'OK?' } + }, + pcsDcErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Error code PCS DC', + role: 'info', + pcsDcErrCode: { '0': 'OK?' } + }, + pcsAcErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Error code PCS AC', + role: 'info', + pcsAcErrCode: { '0': 'OK?' } + }, + lvPvErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Error code LV MPPT', + role: 'info', + lvPvErrCode: { '0': 'OK?' } + }, + hvPvErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Error code HV MPPT', + role: 'info', + hvPvErrCode: { '0': 'OK?' } + }, + adsErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Error code DC12V', + role: 'info', + adsErrCode: { '0': 'OK?' } + } + }, + number: { + acInFreq: { + min: 50, + max: 60, + unit_of_measurement: 'Hz', + mult: 1, + entity_type: 'sensor', + device_class: 'frequency', + role: 'value', + name: 'AC input frequency' + }, + emsMaxAvailNum: { + min: 0, + max: 5, + unit_of_measurement: 'pcs', + mult: 1, + entity_type: 'sensor', + role: 'value', + name: 'EMS max avail. number' + }, + emsParaVolMin: { + min: 0, + max: 120, + unit_of_measurement: 'V', + mult: 0.001, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Minimum parallel voltage' + }, + emsParaVolMax: { + min: 0, + max: 120, + unit_of_measurement: 'V', + mult: 0.001, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Maximum parallel voltage' + }, + acOutFreq: { + min: 0, //should always be 50 + max: 60, + unit_of_measurement: 'Hz', + mult: 1, + entity_type: 'sensor', + device_class: 'frequency', + role: 'value', + name: 'AC output frequency' + }, + batVol: { + min: 0, + max: 120, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Battery voltage' + }, + batAmp: { + min: 0, + max: 60, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Battery current' + }, + bmsInputWatts: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'BMS input power' + }, + bmsOutputWatts: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'BMS output power' + }, + outUsb1Vol: { + min: 0, + max: 6, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage USB-A 1' + }, + outUsb1Amp: { + min: 0, + max: 3, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current USB-A 1' + }, + outUsb2Vol: { + min: 0, + max: 6, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage USB-A 2' + }, + outUsb2Amp: { + min: 0, + max: 3, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current USB-A 2' + }, + outTypec1Vol: { + min: 0, + max: 25, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage USB-C 1' + }, + outTypec1Amp: { + min: 0, + max: 6, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current USB-C 1' + }, + outTypec2Vol: { + min: 0, + max: 25, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage USB-C 2' + }, + outTypec2Amp: { + min: 0, + max: 6, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current USB-C 2' + }, + outAdsVol: { + min: 0, + max: 13, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage DC12V' + }, + outAdsAmp: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current DC12V' + }, + outAcL1_1Vol: { + min: 0, + max: 130, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage Backup 1' + }, + outAcL1_1Amp: { + min: 0, + max: 20, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current Backup 1' + }, + outAcL1_2Vol: { + min: 0, + max: 130, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage Backup 2' + }, + outAcL1_2Amp: { + min: 0, + max: 20, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current Backup 2' + }, + outAcL2_1Vol: { + min: 0, + max: 130, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage UPS 1' + }, + outAcL2_1Amp: { + min: 0, + max: 20, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current UPS 1' + }, + outAcL2_2Vol: { + min: 0, + max: 130, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage UPS 2' + }, + outAcL2_2Amp: { + min: 0, + max: 20, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current UPS 2' + }, + outAcTtVol: { + min: 0, + max: 130, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage UPS TT-30' + }, + outAcTtAmp: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current UPS TT-30' + }, + outAcL14Vol: { + min: 0, + max: 250, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage Backup L-14' + }, + outAcL14Amp: { + min: 0, + max: 20, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current Backup L-14' + }, + outAc_5p8Vol: { + min: 0, + max: 250, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Output voltage PowerI/O' + }, + outAc_5p8Amp: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Output current PowerI/O' + }, + inAc_5p8Vol: { + min: 0, + max: 260, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Input voltage PowerI/O' + }, + inAc_5p8Amp: { + min: 0, + max: 31, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Input current PowerI/O' + }, + inAcC20Vol: { + min: 0, + max: 250, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'Input voltage AC IN' + }, + inAcC20Amp: { + min: 0, + max: 20, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Input current AC IN' + }, + inLvMpptVol: { + min: 0, + max: 150, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'LV solar input voltage' + }, + inLvMpptAmp: { + min: 0, + max: 15, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'LV solar input current' + }, + inHvMpptVol: { + min: 0, + max: 450, + unit_of_measurement: 'V', + mult: 1, + entity_type: 'sensor', + device_class: 'voltage', + role: 'value', + name: 'HV solar input voltage' + }, + inHvMpptAmp: { + min: 0, + max: 15, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'HV solar input current' + }, + pcsDcTemp: { + min: 0, + max: 90, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + role: 'value', + name: 'Temperature PCS DC' + }, + pcsAcTemp: { + min: 0, + max: 90, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + role: 'value', + name: 'Temperature PCS AC' + }, + mpptLvTemp: { + min: 0, + max: 69, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + role: 'value', + name: 'Temperature LV MPPT' + }, + mpptHvTemp: { + min: 0, + max: 90, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + role: 'value', + name: 'Temperature HV MPPT' + }, + pdTemp: { + min: 0, + max: 90, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + role: 'value', + name: 'Temperature PD' + }, + evMaxChargerCur: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Maximum EV charge current' + } + } + }, + BPInfo: { + number: { + bpNo: { + min: 0, + max: 5, + unit_of_measurement: '', + mult: 1, + entity_type: 'sensor', + role: 'value', + name: 'Battery pack number' + }, + bpSoc: { + min: 0, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'Battery pack SOC' + }, + bpPwr: { + min: 0, + max: 7200, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Battery pack power' + }, + bpEnergy: { + min: 0, + max: 6200, + unit_of_measurement: 'Wh', + mult: 1, + entity_type: 'sensor', + device_class: 'energy', + role: 'value', + name: 'Battery pack energy' + }, + heatTime: { + min: 0, + max: 360, + unit_of_measurement: 'min', + mult: 1, + entity_type: 'sensor', + device_class: 'duration', + role: 'value', + name: 'Battery pack heating time' + }, + remainTime: { + min: 0, + unit_of_measurement: 'min', + mult: 1, + entity_type: 'sensor', + device_class: 'duration', + role: 'value', + name: 'Battery pack remain time' + }, + bpSocMax: { + min: 60, + max: 100, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'Battery pack max SOC' + }, + bpSocMin: { + min: 0, + max: 30, + unit_of_measurement: '%', + mult: 1, + entity_type: 'sensor', + device_class: 'battery', + role: 'value', + name: 'Battery pack min SOC' + }, + bpTemp: { + min: 0, + max: 80, + unit_of_measurement: '°C', + mult: 1, + entity_type: 'sensor', + device_class: 'temperature', + role: 'value', + name: 'Battery pack temperature' + } + }, + diagnostic: { + bpChgSta: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Battery pack Charge State', + role: 'info', + bpChgSta: { '0': 'OK?' } + }, + bpErrCode: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Battery pack Error Code', + role: 'info', + bpErrCode: { '0': 'OK?' } + } + } + }, + action: { + switch: { + latestQuotas: { + entity_type: 'switch', + device_class: 'switch', + role: 'switch', + name: 'Get latest Quotas', + payload_off: 'no trigger', + payload_on: 'trigger', + latestQuotas: { '0': 'no trigger', '1': 'trigger' } + } + } + }, + info: { + diagnostic: { + status: { + entity_type: 'text', + entity_category: 'diagnostic', + name: 'Status', + role: 'info', + status: { 0: 'offline', 1: 'online' } + } + } + } +}; + +const deltaproultraStatesDict = { + deltaproultra: { + AppParaHeartbeatReport: { + sysWorkMode: { entity: 'diagnostic' }, + sysBackupEvent: { entity: 'diagnostic' }, + sysBackupSoc: { entity: 'number' }, + energyManageEnable: { entity: 'switch' }, + backupRatio: { entity: 'number' }, + acXboost: { entity: 'diagnostic' }, + acOutFreq: { entity: 'number' }, + bmsModeSet: { entity: 'diagnostic' }, + chgMaxSoc: { entity: 'level' }, + dsgMinSoc: { entity: 'level' }, + acOftenOpenFlg: { entity: 'diagnostic' }, + acOftenOpenMinSoc: { entity: 'number' }, + chg_5p8SetWatts: { entity: 'level' }, + chgC20SetWatts: { entity: 'level' }, + powerStandbyMins: { entity: 'level' }, + screenStandbySec: { entity: 'level' }, + dcStandbyMins: { entity: 'level' }, + acStandbyMins: { entity: 'level' }, + solarOnlyFlg: { entity: 'diagnostic' }, + timezoneSettype: { entity: 'diagnostic' }, + sysTimezone: { entity: 'number' }, + sysTimezoneId: { entity: 'string' } + }, + AppShowHeartbeatReport: { + protoVer: { entity: 'string' }, + showFlag: { entity: 'number' }, + accessType: { entity: 'diagnostic' }, + wireless_4gOn: { entity: 'switch' }, + wireless_4gSta: { entity: 'diagnostic' }, + access_5p8InType: { entity: 'diagnostic' }, + access_5p8OutType: { entity: 'diagnostic' }, + wireless_4gCon: { entity: 'diagnostic' }, + wirlesss_4gErrCode: { entity: 'diagnostic' }, + simIccid: { entity: 'string' }, + soc: { entity: 'number' }, + bpNum: { entity: 'number' }, + pcsType: { entity: 'diagnostic' }, + c20ChgMaxWatts: { entity: 'number' }, + paraChgMaxWatts: { entity: 'number' }, + remainTime: { entity: 'number' }, + sysErrCode: { entity: 'diagnostic' }, + fullCombo: { entity: 'number' }, + remainCombo: { entity: 'number' }, + wattsInSum: { entity: 'number' }, + wattsOutSum: { entity: 'number' }, + outUsb1Pwr: { entity: 'number' }, + outUsb2Pwr: { entity: 'number' }, + outTypec1Pwr: { entity: 'number' }, + outTypec2Pwr: { entity: 'number' }, + outAdsPwr: { entity: 'number' }, + outAcL1_1Pwr: { entity: 'number' }, + outAcL1_2Pwr: { entity: 'number' }, + outAcL2_1Pwr: { entity: 'number' }, + outAcL2_2Pwr: { entity: 'number' }, + outAcTtPwr: { entity: 'number' }, + outAcL14Pwr: { entity: 'number' }, + outAc_5p8Pwr: { entity: 'number' }, + inAc_5p8Pwr: { entity: 'number' }, + inAcC20Pwr: { entity: 'number' }, + inLvMpptPwr: { entity: 'number' }, + inHvMpptPwr: { entity: 'number' }, + outPrPwr: { entity: 'number' }, + timeTaskChangeCnt: { entity: 'number' }, + timeTaskConflictFlag: { entity: 'diagnostic' }, + chgTimeTaskNotice: { entity: 'diagnostic' }, + chgTimeTaskType: { entity: 'diagnostic' }, + chgTimeTaskIndex: { entity: 'diagnostic' }, + chgTimeTaskMode: { entity: 'diagnostic' }, + chgTimeTaskParam: { entity: 'diagnostic' }, + chgTimeTaskTable_0: { entity: 'string' }, + chgTimeTaskTable_1: { entity: 'string' }, + chgTimeTaskTable_2: { entity: 'string' }, + dsgTimeTaskNotice: { entity: 'diagnostic' }, + dsgTimeTaskType: { entity: 'diagnostic' }, + dsgTimeTaskIndex: { entity: 'diagnostic' }, + dsgTimeTaskMode: { entity: 'diagnostic' }, + dsgTimeTaskParam: { entity: 'diagnostic' }, + dsgTimeTaskTable_0: { entity: 'string' }, + dsgTimeTaskTable_1: { entity: 'string' }, + dsgTimeTaskTable_2: { entity: 'string' } + }, + BackendRecordHeartbeatReport: { + recordFlag: { entity: 'diagnostic' }, + sysWorkSta: { entity: 'diagnostic' }, + chgReignSta: { entity: 'diagnostic' }, + pcsWorkSta: { entity: 'diagnostic' }, + fanState: { entity: 'diagnostic' }, + emsWorkSta: { entity: 'diagnostic' }, + c20InType: { entity: 'diagnostic' }, + work_5p8Mode: { entity: 'diagnostic' }, + acInFreq: { entity: 'number' }, + emsMaxAvailNum: { entity: 'number' }, + emsOpenBmsIdx: { entity: 'diagnostic' }, + emsParaVolMin: { entity: 'number' }, + emsParaVolMax: { entity: 'number' }, + acOutFreq: { entity: 'number' }, + pcsDcErrCode: { entity: 'diagnostic' }, + pcsAcErrCode: { entity: 'diagnostic' }, + lvPvErrCode: { entity: 'diagnostic' }, + hvPvErrCode: { entity: 'diagnostic' }, + adsErrCode: { entity: 'diagnostic' }, + batVol: { entity: 'number' }, + batAmp: { entity: 'number' }, + bmsInputWatts: { entity: 'number' }, + bmsOutputWatts: { entity: 'number' }, + outUsb1Vol: { entity: 'number' }, + outUsb1Amp: { entity: 'number' }, + outUsb2Vol: { entity: 'number' }, + outUsb2Amp: { entity: 'number' }, + outTypec1Vol: { entity: 'number' }, + outTypec1Amp: { entity: 'number' }, + outTypec2Vol: { entity: 'number' }, + outTypec2Amp: { entity: 'number' }, + outAdsVol: { entity: 'number' }, + outAdsAmp: { entity: 'number' }, + outAcL1_1Vol: { entity: 'number' }, + outAcL1_1Amp: { entity: 'number' }, + outAcL1_2Vol: { entity: 'number' }, + outAcL1_2Amp: { entity: 'number' }, + outAcL2_1Vol: { entity: 'number' }, + outAcL2_1Amp: { entity: 'number' }, + outAcL2_2Vol: { entity: 'number' }, + outAcL2_2Amp: { entity: 'number' }, + outAcTtVol: { entity: 'number' }, + outAcTtAmp: { entity: 'number' }, + outAcL14Vol: { entity: 'number' }, + outAcL14Amp: { entity: 'number' }, + outAc_5p8Vol: { entity: 'number' }, + outAc_5p8Amp: { entity: 'number' }, + inAc_5p8Vol: { entity: 'number' }, + inAc_5p8Amp: { entity: 'number' }, + inAcC20Vol: { entity: 'number' }, + inAcC20Amp: { entity: 'number' }, + inLvMpptVol: { entity: 'number' }, + inLvMpptAmp: { entity: 'number' }, + inHvMpptVol: { entity: 'number' }, + inHvMpptAmp: { entity: 'number' }, + pcsDcTemp: { entity: 'number' }, + pcsAcTemp: { entity: 'number' }, + mpptLvTemp: { entity: 'number' }, + mpptHvTemp: { entity: 'number' }, + pdTemp: { entity: 'number' }, + evMaxChargerCur: { entity: 'number' } + }, + BPInfo: { + bpNo: { entity: 'number' }, + bpChgSta: { entity: 'diagnostic' }, + bpSoc: { entity: 'number' }, + bpPwr: { entity: 'number' }, + bpEnergy: { entity: 'number' }, + heatTime: { entity: 'number' }, + remainTime: { entity: 'number' }, + bpSocMax: { entity: 'number' }, + bpSocMin: { entity: 'number' }, + bpErrCode: { entity: 'diagnostic' }, + bpTemp: { entity: 'number' } + }, + action: { + latestQuotas: { entity: 'switch' } + }, + info: { + status: { entity: 'diagnostic' } + } + } +}; + +const deltaproultraRanges = { + deltaproultra: { + AppShowHeartbeatReport: { + number: { + c20ChgMaxWatts: { max: 7200 } + } + } + } +}; + +const deltaproultraCmd = { + deltaproultra: { + AppShowHeartbeatReport: { + wireless_4gOn: { msg: { dest: 53, cmdFunc: 2, cmdId: 117, dataLen: 2 } } + }, + AppParaHeartbeatReport: { + energyManageEnable: { msg: { dest: 2, cmdFunc: 2, cmdId: 94, dataLen: 4 } }, // field 1 = enable, field2 = limit backupRatio + chgMaxSoc: { msg: { dest: 2, cmdFunc: 2, cmdId: 87, dataLen: 2 } }, + dsgMinSoc: { msg: { dest: 2, cmdFunc: 2, cmdId: 88, dataLen: 2 } }, + chg_5p8SetWatts: { msg: { dest: 2, cmdFunc: 2, cmdId: 73, dataLen: 3 } }, //field 1 + chgC20SetWatts: { msg: { dest: 2, cmdFunc: 2, cmdId: 73, dataLen: 3 } }, //field 2 + powerStandbyMins: { msg: { dest: 2, cmdFunc: 2, cmdId: 81, dataLen: 2 } }, + screenStandbySec: { msg: { dest: 2, cmdFunc: 2, cmdId: 82, dataLen: 3 } }, + dcStandbyMins: { msg: { dest: 2, cmdFunc: 2, cmdId: 84, dataLen: 2 } }, + acStandbyMins: { msg: { dest: 2, cmdFunc: 2, cmdId: 83, dataLen: 2 } }, + //missing datapoints for mapping + dcON: { msg: { dest: 2, cmdFunc: 2, cmdId: 68, dataLen: 2 } }, + acAlwaysOn: { msg: { dest: 2, cmdFunc: 2, cmdId: 93, dataLen: 2 } }, //acAlwaysOnTime + BatteryPreCond_ON: { msg: { dest: 2, cmdFunc: 2, cmdId: 89, dataLen: 2 } }, + // should be done through the app + timezone: { msg: { dest: 2, cmdFunc: 2, cmdId: 86, dataLen: 2 } }, //+ timezoneSetAuto + town: { msg: { dest: 2, cmdFunc: 2, cmdId: 87, dataLen: 2 } }, //länge des strings + rename: { msg: { dest: 2, cmdFunc: 2, cmdId: 65, dataLen: 2 } } //länge des strings + }, + action: { + latestQuotas: { msg: { cmdFunc: 2, cmdId: 1, dataLen: 0 } } + } + } +}; + +module.exports = { + deltaproultraStates, + deltaproultraStatesDict, + deltaproultraRanges, + deltaproultraCmd +}; diff --git a/lib/ef_shp2_data.js b/lib/ef_shp2_data.js index 2b9ddb3..58e568e 100644 --- a/lib/ef_shp2_data.js +++ b/lib/ef_shp2_data.js @@ -9,7 +9,7 @@ const panel2States = { entity_type: 'sensor', device_class: 'power', role: 'value', - name: 'Backup charge power' + name: 'Master grid power' }, bkpChWatt: { min: 0, @@ -59,7 +59,7 @@ const panel2States = { entity_type: 'sensor', device_class: 'duration', role: 'value', - name: 'Backup Energy#1 charge time' + name: 'Backup Energy#2 charge time' }, bkpEnerg2DischargeTime: { min: 0, @@ -69,7 +69,7 @@ const panel2States = { entity_type: 'sensor', device_class: 'duration', role: 'value', - name: 'Backup Energy#1 discharge time' + name: 'Backup Energy#2 discharge time' }, wattInfoGridWatt: { min: 0, @@ -79,7 +79,27 @@ const panel2States = { entity_type: 'sensor', device_class: 'power', role: 'value', - name: 'Power info' + name: 'Power info grid' + }, + wattInfoChWatt: { + min: 0, + max: 12000, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power info channel' + }, + wattInfoAllHallWatt: { + min: 0, + max: 12000, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power info all hall' } }, string: { @@ -274,7 +294,13 @@ const panel2States = { entity_category: 'diagnostic', name: 'Power Status', role: 'info', - powerSta: { '0': 'feeding loads?', '1': 'standby?', '2': 'charging?', '3': 'error?' } + powerSta: { + '0': 'LOAD_CH_EG_POWER', + '1': 'LOAD_CH_ES_POWER', + '2': 'LOAD_CH_OIL_POWER', + '3': 'LOAD_CH_STOP_EM', + '4': 'LOAD_CH_OFF_POWER' + } }, isSetOilEngine: { entity_type: 'text', @@ -2388,7 +2414,7 @@ const panel2States = { entity_category: 'diagnostic', name: 'Grid status', role: 'info', - gridSta: { '0': 'Grid OK?', '1': 'Grid overvolt./overfreq?', '2': 'Grid volt. not detected?' } + gridSta: { '0': 'Grid volt. not detected', '1': 'Grid OK', '2': 'Grid overvolt./overfreq' } // #168 }, masterRlyErrFlg: { entity_type: 'text', @@ -2733,6 +2759,274 @@ const panel2States = { } } }, + loadCurrent: { + number: { + cur_0: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #1 current' + }, + cur_1: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #2 current' + }, + cur_2: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #3 current' + }, + cur_3: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #4 current' + }, + cur_4: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #5 current' + }, + cur_5: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #6 current' + }, + cur_6: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #7 current' + }, + cur_7: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #8 current' + }, + cur_8: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #9 current' + }, + cur_9: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #10 current' + }, + cur_10: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #11 current' + }, + cur_11: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Channel #12 current' + }, + sumCur: { + min: 0, + max: 30, + unit_of_measurement: 'A', + mult: 1, + entity_type: 'sensor', + device_class: 'current', + role: 'value', + name: 'Total Load Current' + } + } + }, + loadPower: { + number: { + chWatt_0: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #1' + }, + chWatt_1: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #2' + }, + chWatt_2: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #3' + }, + chWatt_3: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #4' + }, + chWatt_4: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #5' + }, + chWatt_5: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #6' + }, + chWatt_6: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #7' + }, + chWatt_7: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #8' + }, + chWatt_8: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #9' + }, + chWatt_9: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #10' + }, + chWatt_10: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #11' + }, + chWatt_11: { + min: 0, + max: 3600, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Power channel #12' + }, + sumWatt: { + min: 0, + max: 10000, + unit_of_measurement: 'W', + mult: 1, + entity_type: 'sensor', + device_class: 'power', + role: 'value', + name: 'Total Load Power' + } + } + }, action: { switch: { latestQuotas: { @@ -2773,6 +3067,8 @@ const panel2StatesDict = { bkpEnerg2ChargeTime: { entity: 'number' }, bkpEnerg2DischargeTime: { entity: 'number' }, wattInfoGridWatt: { entity: 'number' }, + wattInfoChWatt: { entity: 'number' }, + wattInfoAllHallWatt: { entity: 'number' }, appMainVer: { entity: 'string' }, appDbgVer: { entity: 'string' }, appTestVer: { entity: 'string' } @@ -3138,6 +3434,37 @@ const panel2StatesDict = { loadIsEnable12: { entity: 'diagnostic' }, loadPriority12: { entity: 'number' } }, + loadCurrent: { + cur_0: { entity: 'number' }, + cur_1: { entity: 'number' }, + cur_2: { entity: 'number' }, + cur_3: { entity: 'number' }, + cur_4: { entity: 'number' }, + cur_5: { entity: 'number' }, + cur_6: { entity: 'number' }, + cur_7: { entity: 'number' }, + cur_8: { entity: 'number' }, + cur_9: { entity: 'number' }, + cur_10: { entity: 'number' }, + cur_11: { entity: 'number' }, + sumCur: { entity: 'number' } + }, + loadPower: { + chWatt_0: { entity: 'number' }, + chWatt_1: { entity: 'number' }, + chWatt_2: { entity: 'number' }, + chWatt_3: { entity: 'number' }, + chWatt_4: { entity: 'number' }, + chWatt_5: { entity: 'number' }, + chWatt_6: { entity: 'number' }, + chWatt_7: { entity: 'number' }, + chWatt_8: { entity: 'number' }, + chWatt_9: { entity: 'number' }, + chWatt_10: { entity: 'number' }, + chWatt_11: { entity: 'number' }, + sumWatt: { entity: 'number' } + }, + action: { latestQuotas: { entity: 'switch' } }, diff --git a/lib/gen_docs.js b/lib/gen_docs.js index 75ff866..a9ffaab 100644 --- a/lib/gen_docs.js +++ b/lib/gen_docs.js @@ -48,11 +48,23 @@ function createobj(device) { dict = require('./ef_powerocean_data.js').poweroceanStatesDict[device]; ranges = require('./ef_powerocean_data.js').poweroceanRanges[device]; cmd = require('./ef_powerocean_data.js').poweroceanCmd[device]; + } else if (device === 'deltaproultra') { + console.log('deltaproultra'); + states = require('./ef_dpu_data.js').deltaproultraStates; + dict = require('./ef_dpu_data.js').deltaproultraStatesDict[device]; + ranges = require('./ef_dpu_data.js').deltaproultraRanges[device]; + cmd = require('./ef_dpu_data.js').deltaproultraCmd[device]; + } else if (device === 'alternator') { + console.log('powerocean'); + states = require('./ef_alternator_data.js').alternatorStates; + dict = require('./ef_alternator_data.js').alternatorStatesDict[device]; + ranges = require('./ef_alternator_data.js').alternatorRanges[device]; + cmd = require('./ef_alternator_data.js').alternatorCmd[device]; } else { states = require('./ecoflow_data.js').pstreamStates; ranges = require('./ecoflow_data.js').pstreamRanges[device]; cmd = require('./ecoflow_data.js').pstreamCmd[device]; - if (device !== 'plug' && device !== 'deltaproultra') { + if (device !== 'plug') { device = 'pstream'; } dict = require('./ecoflow_data.js').pstreamStatesDict[device]; @@ -201,7 +213,8 @@ function createDocu() { 'powerocean', 'shelly3em', 'panel', - 'panel2' + 'panel2', + 'alternator' ]; for (let i = 0; i < devices.length; i++) { makedoku(devices[i]); diff --git a/main.js b/main.js index 9b061eb..951e00c 100644 --- a/main.js +++ b/main.js @@ -87,6 +87,8 @@ class EcoflowMqtt extends utils.Adapter { this.log.info('shelly -> ' + JSON.stringify(this.config.shellies)); this.log.info('powerkit -> ' + JSON.stringify(this.config.powerkits)); this.log.info('powerocean -> ' + JSON.stringify(this.config.poweroceans)); + this.log.info('alternator -> ' + JSON.stringify(this.config.alternators)); + this.log.info('unknown -> ' + JSON.stringify(this.config.unknowns)); try { //loop durch alle Geräte @@ -101,7 +103,9 @@ class EcoflowMqtt extends utils.Adapter { this.config.panels, this.config.shellies, this.config.powerkits, - this.config.poweroceans + this.config.poweroceans, + this.config.alternators, + this.config.unknowns ); if (confdevices.length > 0) { //loop durch alle pstations @@ -110,7 +114,11 @@ class EcoflowMqtt extends utils.Adapter { if (devtype !== 'none' && devtype !== '') { const id = confdevices[psta]['devId']; const name = confdevices[psta]['devName']; - const haEnable = confdevices[psta]['haEnable']; + let haEnable = false; + //Testgeräte haben kein haEnable + if (confdevices[psta]['haEnable']) { + haEnable = confdevices[psta]['haEnable']; + } const debugEnable = confdevices[psta]['debugEnable']; this.pdevices[id] = {}; this.pdevices[id]['devType'] = devtype; @@ -125,12 +133,7 @@ class EcoflowMqtt extends utils.Adapter { } let devStates = null; - if ( - devtype === 'pstream600' || - devtype === 'pstream800' || - devtype === 'plug' || - devtype === 'deltaproultra' - ) { + if (devtype === 'pstream600' || devtype === 'pstream800' || devtype === 'plug') { devStates = require('./lib/ecoflow_data.js').pstreamStates; } else if ( devtype === 'powerkitbp2000' || @@ -144,18 +147,17 @@ class EcoflowMqtt extends utils.Adapter { devStates = require('./lib/ef_shp_data.js').panelStates; } else if (devtype === 'panel2') { devStates = require('./lib/ef_shp2_data.js').panel2States; + } else if (devtype === 'deltaproultra') { + devStates = require('./lib/ef_dpu_data.js').deltaproultraStates; + } else if (devtype === 'alternator') { + devStates = require('./lib/ef_alternator_data.js').alternatorStates; } else { devStates = require('./lib/ecoflow_data.js').pstationStates; } //ef_powerkit_data.js if (devtype !== 'none' && devStates) { let devupd = null; - if ( - devtype === 'pstream600' || - devtype === 'pstream800' || - devtype === 'plug' || - devtype === 'deltaproultra' - ) { + if (devtype === 'pstream600' || devtype === 'pstream800' || devtype === 'plug') { devupd = require('./lib/ecoflow_data.js').pstreamRanges[devtype]; } else if ( devtype === 'powerkitbp2000' || @@ -169,6 +171,10 @@ class EcoflowMqtt extends utils.Adapter { devupd = require('./lib/ef_shp_data.js').panelRanges[devtype]; } else if (devtype === 'panel2') { devupd = require('./lib/ef_shp2_data.js').panel2Ranges[devtype]; + } else if (devtype === 'deltaproultra') { + devupd = require('./lib/ef_dpu_data.js').deltaproultraRanges[devtype]; + } else if (devtype === 'alternator') { + devupd = require('./lib/ef_alternator_data.js').alternatorRanges[devtype]; } else { devupd = require('./lib/ecoflow_data.js').pstationRanges[devtype]; } @@ -220,7 +226,7 @@ class EcoflowMqtt extends utils.Adapter { let pdevicesStatesDict = null; let pdevicesCmd = null; - if (devtype === 'pstream' || devtype === 'plug' || devtype === 'deltaproultra') { + if (devtype === 'pstream' || devtype === 'plug') { pdevicesStatesDict = require('./lib/ecoflow_data.js').pstreamStatesDict[devtype]; pdevicesCmd = require('./lib/ecoflow_data.js').pstreamCmd[origdevtype]; } else if (devtype === 'powerkit') { @@ -237,6 +243,14 @@ class EcoflowMqtt extends utils.Adapter { } else if (devtype === 'panel2') { pdevicesStatesDict = require('./lib/ef_shp2_data.js').panel2StatesDict[devtype]; pdevicesCmd = require('./lib/ef_shp2_data.js').panel2Cmd[devtype]; + } else if (devtype === 'deltaproultra') { + pdevicesStatesDict = require('./lib/ef_dpu_data.js').deltaproultraStatesDict[devtype]; + pdevicesCmd = require('./lib/ef_dpu_data.js').deltaproultraCmd[devtype]; + } else if (devtype === 'alternator') { + pdevicesStatesDict = require('./lib/ef_alternator_data.js').alternatorStatesDict[ + devtype + ]; + pdevicesCmd = require('./lib/ef_alternator_data.js').alternatorCmd[devtype]; } else { pdevicesStatesDict = require('./lib/ecoflow_data.js').pstationStatesDict[origdevtype]; pdevicesCmd = require('./lib/ecoflow_data.js').pstationCmd[origdevtype]; @@ -469,6 +483,39 @@ class EcoflowMqtt extends utils.Adapter { } } this.log.info('powerocean add battery #1 states created'); + } else if (devtype == 'deltaproultra') { + if (this.config.msgStateCreation) { + this.log.debug('____________________________________________'); + this.log.debug('create channel ' + 'BPInfo2'); + } + await myutils.createMyChannel(this, id, 'BPInfo2', 'BPInfo2', 'channel'); + for (let key in pdevicesStatesDict['BPInfo']) { + if (this.config.msgStateCreation) { + this.log.debug('state creation ' + key); + } + let type = pdevicesStatesDict['BPInfo'][key]['entity']; + if (type !== 'icon') { + if (devStates['BPInfo'][type][key]) { + await myutils.createMyState( + this, + id, + 'BPInfo2', + key, + devStates['BPInfo'][type][key] + ); + } else { + this.log.info( + 'not created/mismatch ' + + ' BPInfo2 ->' + + ' ' + + key + + ' ' + + type + ); + } + } + } + this.log.info('DPU add battery (#2) states created'); } else { if (this.config.msgStateCreation) { this.log.debug('____________________________________________'); @@ -579,6 +626,39 @@ class EcoflowMqtt extends utils.Adapter { } } this.log.info('powerocean add battery #1 states created'); + } else if (devtype == 'deltaproultra') { + if (this.config.msgStateCreation) { + this.log.debug('____________________________________________'); + this.log.debug('create channel ' + 'BPInfo3'); + } + await myutils.createMyChannel(this, id, 'BPInfo3', 'BPInfo3', 'channel'); + for (let key in pdevicesStatesDict['BPInfo']) { + if (this.config.msgStateCreation) { + this.log.debug('state creation ' + key); + } + let type = pdevicesStatesDict['BPInfo'][key]['entity']; + if (type !== 'icon') { + if (devStates['BPInfo'][type][key]) { + await myutils.createMyState( + this, + id, + 'BPInfo3', + key, + devStates['BPInfo'][type][key] + ); + } else { + this.log.info( + 'not created/mismatch ' + + ' BPInfo3 ->' + + ' ' + + key + + ' ' + + type + ); + } + } + } + this.log.info('DPU add battery (#3) states created'); } else { if (this.config.msgStateCreation) { this.log.debug('____________________________________________'); @@ -750,14 +830,31 @@ class EcoflowMqtt extends utils.Adapter { devtype === 'plug' || devtype === 'deltaproultra' || devtype === 'powerocean' || - devtype === 'panel2' + devtype === 'panel2' || + devtype === 'alternator' || + devtype === 'deltapro3' || + devtype === 'delta3' || + devtype === 'delta3plus' ) { if (this.pdevicesStatesDict && this.pdevicesStates) { let msgdecode = null; - try { - msgdecode = ef.pstreamDecode(this, message, '', topic, msgtype, logged); - } catch (error) { - this.log.debug('pstreamDecode call ->' + error); + if (devtype === 'deltapro3' || devtype === 'delta3' || devtype === 'delta3plus') { + this.log.debug( + '[PROTOBUF unknown] ' + + topic + + ' [' + + devtype + + '/' + + msgtype + + '] raw (hex): ' + + message.toString('hex') + ); + } else { + try { + msgdecode = ef.pstreamDecode(this, message, '', topic, msgtype, logged); + } catch (error) { + this.log.debug('pstreamDecode call ->' + error); + } } if (msgtype === 'update' || msgtype === 'get_reply') { if (msgdecode !== null && typeof msgdecode === 'object') { @@ -814,7 +911,8 @@ class EcoflowMqtt extends utils.Adapter { devtype === 'pstream800' || devtype === 'deltaproultra' || devtype === 'powerocean' || - devtype === 'panel2' + devtype === 'panel2' || + devtype === 'alternator' ) { this.msgCountPstream++; await this.setStateAsync('info.msgCountPstream', { @@ -1366,6 +1464,10 @@ class EcoflowMqtt extends utils.Adapter { case 'deltaproultra': case 'powerocean': case 'panel2': + case 'alternator': + case 'deltapro3': + case 'dalta3plus': + case 'dalta3': devicetype = this.pdevices[device]['devType']; type = 'protobuf'; //includes also plugs cmd = this.pdevicesCmd[devicetype]; diff --git a/package.json b/package.json index 0c84a63..b758e81 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "iobroker.ecoflow-mqtt", - "version": "1.0.5", + "version": "1.1.0", "description": "connects to ecoflow products", "author": { "name": "foxthefox", From 510c6a8445e6c42eb9cc0c7c42ccd59912a8096c Mon Sep 17 00:00:00 2001 From: foxthefox <16841643+foxthefox@users.noreply.github.com> Date: Thu, 2 Jan 2025 15:33:56 +0100 Subject: [PATCH 2/3] 1.1.0 --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 37e00bf..b2a0c9c 100644 --- a/README.md +++ b/README.md @@ -294,6 +294,14 @@ Wave is not available, could be implemented, if data is available. ### Glacier refrigerator [Glacier](./doc/devices/glacier.md) +### Alternator +[Alternator](./doc/devices/alternator.md) + +### Unsupported devices +for debugging purpose this section is created, please select the device (delta pro3, delta3, delta3 plus) und put the serial in the added line +it is anticipated that the unknown device is using protobuf +it creates [PROTOBUF unknown] messages in th log, they contain the raw hex telegram + ## ToDo * check forgotten boundary conditions for commands (inhibit cmd, or additional value) From 898385b060f355a16268b34199ea4cc63b03d3b5 Mon Sep 17 00:00:00 2001 From: foxthefox <16841643+foxthefox@users.noreply.github.com> Date: Thu, 2 Jan 2025 15:45:17 +0100 Subject: [PATCH 3/3] 1.1.0 --- README.md | 2 ++ main.js | 10 +++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b2a0c9c..8f2e3bd 100644 --- a/README.md +++ b/README.md @@ -312,6 +312,8 @@ it creates [PROTOBUF unknown] messages in th log, they contain the raw hex teleg ## Changelog ### 1.1.0 (npm) +* (foxthefox) added a preliminary version of alternator (no cmd, non final state names) +* (foxthefox) added a config possibility for unsupported devices for capturing the transmitted telegrams * (foxthefox) #168 changed SHP2 masterIncreInfo.gridSta '0': 'Grid volt. not detected', '1': 'Grid OK' * (foxthefox) #173 DPU added additional battery selection * (foxthefox) #174 SHP2 added in ProtoTime the wattInfoChWatt, wattInfoAllHallWatt diff --git a/main.js b/main.js index 951e00c..29b1e90 100644 --- a/main.js +++ b/main.js @@ -1500,7 +1500,15 @@ class EcoflowMqtt extends utils.Adapter { switch (type) { case 'protobuf': - if (devicetype !== '' && devicetype !== 'none' && cmd) { + if ( + devicetype !== '' && + devicetype !== 'none' && + cmd && + (devicetype !== 'delta3' && + devicetype !== 'delta3plus' && + devicetype !== 'deltapro3' && + devicetype !== 'alternator') + ) { const msgBuf = await ef.prepareStreamCmd( this, device,