Update the plugin, see also https://github.com/JanJaapKo/domoticz-G ... /issues/30Jeweettoch13 wrote: Tuesday 30 December 2025 10:36 Hello fellow members.
For some reason i got some errors today when requesting the data from the Goodwe SEMS plugin. Do you guys know what this means?
Python Plugin: GoodWe solar inverter via SEMS API
Moderator: leecollings
- waltervl
- Posts: 7012
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2026.3
- Location: NL
- Contact:
RE: Python Plugin: GoodWe solar inverter via SEMS API
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: RE: Python Plugin: GoodWe solar inverter via SEMS API
Replaced the file in Domoticz plugins, but no luck:waltervl wrote: Tuesday 30 December 2025 10:56Update the plugin, see also https://github.com/JanJaapKo/domoticz-G ... /issues/30Jeweettoch13 wrote: Tuesday 30 December 2025 10:36 Hello fellow members.
For some reason i got some errors today when requesting the data from the Goodwe SEMS plugin. Do you guys know what this means?
2025-12-30 11:03:41.058 Error: (FindModule) Domoticz and DomoticzEx modules both found in interpreter, use one or the other.
2025-12-30 11:03:41.058 Error: Goodwe SEMS: Call to function 'onHeartbeat' failed, exception details:
2025-12-30 11:03:41.059 Error: Goodwe SEMS: Traceback (most recent call last):
2025-12-30 11:03:41.059 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 459, in onHeartbeat
2025-12-30 11:03:41.059 Error: Goodwe SEMS: _plugin.onHeartbeat()
2025-12-30 11:03:41.059 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 370, in onHeartbeat
2025-12-30 11:03:41.059 Error: Goodwe SEMS: elif len(Parameters["Mode1"]) == 0:
2025-12-30 11:03:41.059 Error: Goodwe SEMS: ^^^^^^^^^^
2025-12-30 11:03:41.059 Error: Goodwe SEMS: NameError: name 'Parameters' is not defined
- waltervl
- Posts: 7012
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2026.3
- Location: NL
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Did you restart Domoticz?
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Yes i did. Only copy paste the file. Don't know if that's sufficient.
- waltervl
- Posts: 7012
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2026.3
- Location: NL
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
What file? The plugin.py or the Goodwe.py or both?
In your case it looks like Domoticz is confused now about the plugin.py.
You are running Domoticz in Docker it looks like so not sure how to restart properly.
In your case it looks like Domoticz is confused now about the plugin.py.
You are running Domoticz in Docker it looks like so not sure how to restart properly.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
I copied the one provided by jeannot171 (GoodWe.py)waltervl wrote: Tuesday 30 December 2025 11:23 What file? The plugin.py or the Goodwe.py or both?
In your case it looks like Domoticz is confused now about the plugin.py.
You are running Domoticz in Docker it looks like so not sure how to restart properly.
also copied just the plugin file,It's working
I see on a sidenote that new sensors have been made, but need the old log on the new sensors. Is this achieved by restoring the backup data?
- waltervl
- Posts: 7012
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2026.3
- Location: NL
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
You could use the device replace function to move the history in the new device: https://wiki.domoticz.com/Managing_Devi ... ace_deviceJeweettoch13 wrote: Tuesday 30 December 2025 11:26I copied the one provided by jeannot171 (GoodWe.py)waltervl wrote: Tuesday 30 December 2025 11:23 What file? The plugin.py or the Goodwe.py or both?
In your case it looks like Domoticz is confused now about the plugin.py.
You are running Domoticz in Docker it looks like so not sure how to restart properly.
also copied just the plugin file,It's working.
I see on a sidenote that new sensors have been made, but need the old log on the new sensors. Is this achieved by restoring the backup data?
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
That should work indeed, if not turning the complete system haywire:waltervl wrote: Tuesday 30 December 2025 11:52You could use the device replace function to move the history in the new device: https://wiki.domoticz.com/Managing_Devi ... ace_deviceJeweettoch13 wrote: Tuesday 30 December 2025 11:26I copied the one provided by jeannot171 (GoodWe.py)waltervl wrote: Tuesday 30 December 2025 11:23 What file? The plugin.py or the Goodwe.py or both?
In your case it looks like Domoticz is confused now about the plugin.py.
You are running Domoticz in Docker it looks like so not sure how to restart properly.
also copied just the plugin file,It's working.
I see on a sidenote that new sensors have been made, but need the old log on the new sensors. Is this achieved by restoring the backup data?
2025-12-30 12:03:17.255 Error: Goodwe SEMS: ~~~~~~~~~~~~~~~~~~~~~^^^^^^
2025-12-30 12:03:17.255 Error: Goodwe SEMS: KeyError: 2
2025-12-30 12:03:27.742 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/2) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/4) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/5) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/6) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/14) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/7) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/8) already exists in Domoticz.
2025-12-30 12:03:27.743 Error: Goodwe SEMS: (Goodwe SEMS) Unit creation failed, Hardware/DeviceID/Unit combination (5/56000DTS205W0092/15) already exists in Domoticz.
2025-12-30 12:03:27.747 Error: Goodwe SEMS: Call to function 'onHeartbeat' failed, exception details:
2025-12-30 12:03:27.749 Error: Goodwe SEMS: Traceback (most recent call last):
2025-12-30 12:03:27.749 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 519, in onHeartbeat
2025-12-30 12:03:27.749 Error: Goodwe SEMS: _plugin.onHeartbeat()
2025-12-30 12:03:27.749 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 413, in onHeartbeat
2025-12-30 12:03:27.749 Error: Goodwe SEMS: self.startDeviceUpdateV2()
2025-12-30 12:03:27.754 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 175, in startDeviceUpdateV2
2025-12-30 12:03:27.754 Error: Goodwe SEMS: self.updateDevices(DeviceData)
2025-12-30 12:03:27.755 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 199, in updateDevices
2025-12-30 12:03:27.755 Error: Goodwe SEMS: UpdateDevice(inverter["sn"], theInverter.outputCurrentUnit, 0, str(inverter["output_current"]), AlwaysUpdate=True)
2025-12-30 12:03:27.755 Error: Goodwe SEMS: File "/opt/domoticz/userdata/plugins/domoticz-GoodWeSEMS/plugin.py", line 559, in UpdateDevice
2025-12-30 12:03:27.755 Error: Goodwe SEMS: logging.debug("Updating device '"+Devices[Device].Units[Unit].Name+ "' with current sValue '"+Devices[Device].Units[Unit].sValue+"' to '" +sValue+"'")
Luckily a backed up the database so can convert back easily.
Edit* Got it working. I restart the container per edit, and that works. Tnx for the help
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Hello all,
i got a error on the Sems plugin again (maybe because they went to Sems+ a short while ago)
Began around 4:20AM this morning.

From the Sems+ portal the data is visible.
I'm on v5.0 plugin
i got a error on the Sems plugin again (maybe because they went to Sems+ a short while ago)
Began around 4:20AM this morning.

From the Sems+ portal the data is visible.
I'm on v5.0 plugin
- Attachments
-
- Error.jpg (241.91 KiB) Viewed 592 times
-
JanJaap
- Posts: 244
- Joined: Thursday 12 October 2017 20:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Dev
- Location: the Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Hi,
I'm aware of the issue, it has something to do with the authentication on the Goodwe server. Looking for a solution....
See Github - issue 36
I'm aware of the issue, it has something to do with the authentication on the Goodwe server. Looking for a solution....
See Github - issue 36
RPi 3, Domoticz dev version, Aeon ZWave stick (with a whole bunch of slaves), Zigbee using Zigbee2MQTT, Nest thermo, P1 smart meter on RPi Zero
-
RNEE
- Posts: 77
- Joined: Sunday 05 August 2018 10:13
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2026.1
- Location: NL/Eindhoven area
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Same problem here, but I can't fix it.
This is a known issue, and this post might help us out: https://www.zonstraal.be/forum/viewtopic.php?p=352091
The GoodWe API documentation is available here: https://openapi.goodwe.com/#api/doc-10a71afe72c271
Do I understand correctly that a fixed authentication token must now be included?
This is a known issue, and this post might help us out: https://www.zonstraal.be/forum/viewtopic.php?p=352091
The GoodWe API documentation is available here: https://openapi.goodwe.com/#api/doc-10a71afe72c271
Do I understand correctly that a fixed authentication token must now be included?
Domoticz (since 2016) on Docker on Raspberry PI 5 with 500 Gb NVMe|Milight|KaKu + RFXCOM|Goodwe|Smartstuff P1 meter|Buienradar|Afval kalender|Tuya-wifi|Zigbee + deCONZ Conbee II|Marstek Homebattery 5,12Kwh via Modbus on Pusr-dr134|MQTTMapper|Quatt v2|
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Seems that the Anton version is working, but where to put the code?RNEE wrote: Thursday 24 September 2026 9:44 Same problem here, but I can't fix it.
This is a known issue, and this post might help us out: https://www.zonstraal.be/forum/viewtopic.php?p=352091
The GoodWe API documentation is available here: https://openapi.goodwe.com/#api/doc-10a71afe72c271
Do I understand correctly that a fixed authentication token must now be included?
-
RNEE
- Posts: 77
- Joined: Sunday 05 August 2018 10:13
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2026.1
- Location: NL/Eindhoven area
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
I (and Ai) have now a dzVents script what the total load in a parameter with idx 2954.
Connection and data retrieval works now !
But I have to work more things out.
Connection and data retrieval works now !
But I have to work more things out.
Code: Select all
return {
on = {
timer = {
'every 1 minutes' -- Haalt elke 1 minuten data op
}
},
logging = {
level = domoticz.LOG_INFO,
marker = 'SEMS_PLUS'
},
execute = function(domoticz, item)
-- ==========================================
-- CONFIGURATIE (PAS DIT AAN JOUW GEGEVENS AN)
-- ==========================================
local semsUser = 'user@sems'
local semsPassword = 'password_of_user'
local domoticzIdx = 2954 -- Het Idx nummer van het virtuele apparaat
local inverterNo = 0 -- 0 = eerste omvormer, 1 = tweede, etc.
-- ==========================================
-- De correcte Europese Gateway endpoints voor SEMS+
local baseUrl = 'https://eu-gateway.semsportal.com'
local loginUrl = baseUrl .. '/web/sems/sems-user/api/v1/auth/cross-login'
local dataUrl = baseUrl .. '/web/sems/sems-plant/api/web/device/centralized/page'
domoticz.log('Starten met ophalen van de gegevens via SEMS+...', domoticz.LOG_INFO)
-- 1. Wachtwoord versleutelen (MD5 -> Base64) via de Linux terminal
local cmdEncrypt = 'echo -n "' .. semsPassword .. '" | md5sum | cut -d" " -f1 | tr -d "\\n" | base64 | tr -d "\\n"'
local handleEnc = io.popen(cmdEncrypt)
local encryptedPassword = handleEnc:read("*a"):gsub("%s+", "")
handleEnc:close()
-- 2. Inloggen en Token ophalen
local loginPayload = domoticz.utils.toJSON({
account = semsUser,
pwd = encryptedPassword,
isChinese = false,
agreement = 1,
isLocal = true
})
-- Schone curl-aanroep voor inloggen
local cmdLogin = 'curl --silent --insecure --location --request POST "' .. loginUrl .. '" ' ..
'--header "Content-Type: application/json" ' ..
'--header "Accept: application/json, */*" ' ..
'--header "token: {\\"uid\\":\\"\\",\\"timestamp\\":0,\\"token\\":\\"\\",\\"client\\":\\"semsPlusWeb\\",\\"version\\":\\"\\",\\"language\\":\\"en\\"}" ' ..
'--data \'' .. loginPayload .. '\''
local handleLogin = io.popen(cmdLogin)
local loginResult = handleLogin:read("*a")
handleLogin:close()
-- Controleer of er een netwerkrespons is
if (not loginResult or loginResult == "") then
domoticz.log('Geen netwerkrespons ontvangen van de inlogserver.', domoticz.LOG_ERROR)
return
end
local loginJson = domoticz.utils.fromJSON(loginResult)
-- Controleer of de login succesvol is verwerkt (Code 00000)
if (loginJson and loginJson.code == '00000' and loginJson.data) then
domoticz.log('Login op de EU Gateway succesvol! Token gegenereerd.', domoticz.LOG_INFO)
local d = loginJson.data
local tokenHeader = domoticz.utils.toJSON({
uid = d.uid,
timestamp = d.timestamp,
token = d.token,
client = "semsPlusWeb",
version = d.version or "",
language = d.language or "en",
region = d.region or ""
})
-- 3. Data opvragen met het verkregen token uit Stap 2
local dataPayload = '{"deviceTypeList":["INVERTER"],"current":1,"size":10}'
local cmdData = 'curl --silent --insecure --location --request POST "' .. dataUrl .. '" ' ..
'--header "Content-Type: application/json" ' ..
'--header "Accept: application/json, */*" ' ..
'--header "token: ' .. tokenHeader:gsub('"', '\\"') .. '" ' ..
'--data \'' .. dataPayload .. '\''
local handleData = io.popen(cmdData)
local dataResult = handleData:read("*a")
handleData:close()
local dataJson = domoticz.utils.fromJSON(dataResult)
-- 4. Gegevens valideren en wegschrijven naar de Domoticz sensor
if (dataJson and dataJson.code == '00000' and dataJson.data and dataJson.data.dataList) then
local dataList = dataJson.data.dataList
-- Correcte navigatie door de SEMS+ array: dataList[1] -> children[1]
if (dataList[1] and dataList[1].children and dataList[1].children[1]) then
local dev = dataList[1].children[1]
local pAc = tonumber(dev.pAc) or 0 -- Actueel vermogen (kW)
local proToday = tonumber(dev.proToday) or 0 -- Dagopbrengst (kWh)
-- Omrekenen naar Watts en Watt-uren voor Domoticz
local wattActueel = math.floor(pAc * 1000)
local whTotaal = math.floor(proToday * 1000)
domoticz.log('SEMS+ Data succesvol verwerkt -> Actueel: ' .. wattActueel .. ' W | Vandaag: ' .. proToday .. ' kWh', domoticz.LOG_INFO)
-- Update de virtuele sensor (Formaat: ActueelVermogen;TotaalWh)
domoticz.devices(domoticzIdx).updateElectricity(wattActueel, whTotaal)
else
domoticz.log('Geen actieve installatie of omvormer gevonden in dataList structure.', domoticz.LOG_ERROR)
end
else
domoticz.log('Fout bij het ophalen van de installatiedata. Response: ' .. tostring(dataResult), domoticz.LOG_ERROR)
end
else
domoticz.log('Inloggen op SEMS+ geweigerd. Response van server: ' .. tostring(loginResult), domoticz.LOG_ERROR)
end
end
}
Domoticz (since 2016) on Docker on Raspberry PI 5 with 500 Gb NVMe|Milight|KaKu + RFXCOM|Goodwe|Smartstuff P1 meter|Buienradar|Afval kalender|Tuya-wifi|Zigbee + deCONZ Conbee II|Marstek Homebattery 5,12Kwh via Modbus on Pusr-dr134|MQTTMapper|Quatt v2|
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Is this piece of code anywhere to put in a current .py file?RNEE wrote: Thursday 24 September 2026 17:51 I (and Ai) have now a dzVents script what the total load in a parameter with idx 2954.
Connection and data retrieval works now !
But I have to work more things out.
Code: Select all
return { on = { timer = { 'every 1 minutes' -- Haalt elke 1 minuten data op } }, logging = { level = domoticz.LOG_INFO, marker = 'SEMS_PLUS' }, execute = function(domoticz, item) -- ========================================== -- CONFIGURATIE (PAS DIT AAN JOUW GEGEVENS AN) -- ========================================== local semsUser = 'user@sems' local semsPassword = 'password_of_user' local domoticzIdx = 2954 -- Het Idx nummer van het virtuele apparaat local inverterNo = 0 -- 0 = eerste omvormer, 1 = tweede, etc. -- ========================================== -- De correcte Europese Gateway endpoints voor SEMS+ local baseUrl = 'https://eu-gateway.semsportal.com' local loginUrl = baseUrl .. '/web/sems/sems-user/api/v1/auth/cross-login' local dataUrl = baseUrl .. '/web/sems/sems-plant/api/web/device/centralized/page' domoticz.log('Starten met ophalen van de gegevens via SEMS+...', domoticz.LOG_INFO) -- 1. Wachtwoord versleutelen (MD5 -> Base64) via de Linux terminal local cmdEncrypt = 'echo -n "' .. semsPassword .. '" | md5sum | cut -d" " -f1 | tr -d "\\n" | base64 | tr -d "\\n"' local handleEnc = io.popen(cmdEncrypt) local encryptedPassword = handleEnc:read("*a"):gsub("%s+", "") handleEnc:close() -- 2. Inloggen en Token ophalen local loginPayload = domoticz.utils.toJSON({ account = semsUser, pwd = encryptedPassword, isChinese = false, agreement = 1, isLocal = true }) -- Schone curl-aanroep voor inloggen local cmdLogin = 'curl --silent --insecure --location --request POST "' .. loginUrl .. '" ' .. '--header "Content-Type: application/json" ' .. '--header "Accept: application/json, */*" ' .. '--header "token: {\\"uid\\":\\"\\",\\"timestamp\\":0,\\"token\\":\\"\\",\\"client\\":\\"semsPlusWeb\\",\\"version\\":\\"\\",\\"language\\":\\"en\\"}" ' .. '--data \'' .. loginPayload .. '\'' local handleLogin = io.popen(cmdLogin) local loginResult = handleLogin:read("*a") handleLogin:close() -- Controleer of er een netwerkrespons is if (not loginResult or loginResult == "") then domoticz.log('Geen netwerkrespons ontvangen van de inlogserver.', domoticz.LOG_ERROR) return end local loginJson = domoticz.utils.fromJSON(loginResult) -- Controleer of de login succesvol is verwerkt (Code 00000) if (loginJson and loginJson.code == '00000' and loginJson.data) then domoticz.log('Login op de EU Gateway succesvol! Token gegenereerd.', domoticz.LOG_INFO) local d = loginJson.data local tokenHeader = domoticz.utils.toJSON({ uid = d.uid, timestamp = d.timestamp, token = d.token, client = "semsPlusWeb", version = d.version or "", language = d.language or "en", region = d.region or "" }) -- 3. Data opvragen met het verkregen token uit Stap 2 local dataPayload = '{"deviceTypeList":["INVERTER"],"current":1,"size":10}' local cmdData = 'curl --silent --insecure --location --request POST "' .. dataUrl .. '" ' .. '--header "Content-Type: application/json" ' .. '--header "Accept: application/json, */*" ' .. '--header "token: ' .. tokenHeader:gsub('"', '\\"') .. '" ' .. '--data \'' .. dataPayload .. '\'' local handleData = io.popen(cmdData) local dataResult = handleData:read("*a") handleData:close() local dataJson = domoticz.utils.fromJSON(dataResult) -- 4. Gegevens valideren en wegschrijven naar de Domoticz sensor if (dataJson and dataJson.code == '00000' and dataJson.data and dataJson.data.dataList) then local dataList = dataJson.data.dataList -- Correcte navigatie door de SEMS+ array: dataList[1] -> children[1] if (dataList[1] and dataList[1].children and dataList[1].children[1]) then local dev = dataList[1].children[1] local pAc = tonumber(dev.pAc) or 0 -- Actueel vermogen (kW) local proToday = tonumber(dev.proToday) or 0 -- Dagopbrengst (kWh) -- Omrekenen naar Watts en Watt-uren voor Domoticz local wattActueel = math.floor(pAc * 1000) local whTotaal = math.floor(proToday * 1000) domoticz.log('SEMS+ Data succesvol verwerkt -> Actueel: ' .. wattActueel .. ' W | Vandaag: ' .. proToday .. ' kWh', domoticz.LOG_INFO) -- Update de virtuele sensor (Formaat: ActueelVermogen;TotaalWh) domoticz.devices(domoticzIdx).updateElectricity(wattActueel, whTotaal) else domoticz.log('Geen actieve installatie of omvormer gevonden in dataList structure.', domoticz.LOG_ERROR) end else domoticz.log('Fout bij het ophalen van de installatiedata. Response: ' .. tostring(dataResult), domoticz.LOG_ERROR) end else domoticz.log('Inloggen op SEMS+ geweigerd. Response van server: ' .. tostring(loginResult), domoticz.LOG_ERROR) end end }
-
RNEE
- Posts: 77
- Joined: Sunday 05 August 2018 10:13
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2026.1
- Location: NL/Eindhoven area
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
It is a standalone dzVents script. It is put in Events. It is not a python .py program.
Now this works maybe JanJaap can use the info from the script to change it to the plugin.
Now this works maybe JanJaap can use the info from the script to change it to the plugin.
Domoticz (since 2016) on Docker on Raspberry PI 5 with 500 Gb NVMe|Milight|KaKu + RFXCOM|Goodwe|Smartstuff P1 meter|Buienradar|Afval kalender|Tuya-wifi|Zigbee + deCONZ Conbee II|Marstek Homebattery 5,12Kwh via Modbus on Pusr-dr134|MQTTMapper|Quatt v2|
-
JanJaap
- Posts: 244
- Joined: Thursday 12 October 2017 20:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Dev
- Location: the Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
I just pushed an update. But if I read the other blogs correctly, there is no data when the inverters are not active. And it is now 23:30.... I'll check tomorrow morning but likely only have time to fix tomorrow evening. Feel free to pull latest version of plugin and test
RPi 3, Domoticz dev version, Aeon ZWave stick (with a whole bunch of slaves), Zigbee using Zigbee2MQTT, Nest thermo, P1 smart meter on RPi Zero
-
RNEE
- Posts: 77
- Joined: Sunday 05 August 2018 10:13
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2026.1
- Location: NL/Eindhoven area
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Thank you for your work!JanJaap wrote: Thursday 24 September 2026 23:31 I just pushed an update. But if I read the other blogs correctly, there is no data when the inverters are not active. And it is now 23:30.... I'll check tomorrow morning but likely only have time to fix tomorrow evening. Feel free to pull latest version of plugin and test
I will test it tomorrow.
Domoticz (since 2016) on Docker on Raspberry PI 5 with 500 Gb NVMe|Milight|KaKu + RFXCOM|Goodwe|Smartstuff P1 meter|Buienradar|Afval kalender|Tuya-wifi|Zigbee + deCONZ Conbee II|Marstek Homebattery 5,12Kwh via Modbus on Pusr-dr134|MQTTMapper|Quatt v2|
-
Jeweettoch13
- Posts: 38
- Joined: Saturday 23 July 2022 16:42
- Target OS: NAS (Synology & others)
- Domoticz version: 2026.2
- Location: Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Much appreciated!JanJaap wrote: Thursday 24 September 2026 23:31 I just pushed an update. But if I read the other blogs correctly, there is no data when the inverters are not active. And it is now 23:30.... I'll check tomorrow morning but likely only have time to fix tomorrow evening. Feel free to pull latest version of plugin and test
The inverter is in waiting mode but not present in Domoticz at the moment
-
JanJaap
- Posts: 244
- Joined: Thursday 12 October 2017 20:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Dev
- Location: the Netherlands
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Same here, so I guess I need to give Copilot some more instructions.....
At least the amount of error loglines has been reduced
At least the amount of error loglines has been reduced
RPi 3, Domoticz dev version, Aeon ZWave stick (with a whole bunch of slaves), Zigbee using Zigbee2MQTT, Nest thermo, P1 smart meter on RPi Zero
-
RNEE
- Posts: 77
- Joined: Sunday 05 August 2018 10:13
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2026.1
- Location: NL/Eindhoven area
- Contact:
Re: Python Plugin: GoodWe solar inverter via SEMS API
Update indeed not working.
I used Google AI to make the dzVents script but i had many repeating faults / corrections to make in the process and more detailed instructions to give before it worked.
I think my dzVents script can be used to instruct Copilot ?
I know the dzVents script is not ready for production but it is a start.
I used Google AI to make the dzVents script but i had many repeating faults / corrections to make in the process and more detailed instructions to give before it worked.
I think my dzVents script can be used to instruct Copilot ?
I know the dzVents script is not ready for production but it is a start.
Domoticz (since 2016) on Docker on Raspberry PI 5 with 500 Gb NVMe|Milight|KaKu + RFXCOM|Goodwe|Smartstuff P1 meter|Buienradar|Afval kalender|Tuya-wifi|Zigbee + deCONZ Conbee II|Marstek Homebattery 5,12Kwh via Modbus on Pusr-dr134|MQTTMapper|Quatt v2|