Smanar / Domoticz-deCONZ

deCONZ plugin for Domoticz (Zigbee application)
GNU General Public License v3.0
36 stars 27 forks source link

Crash on start #156

Closed arjannv closed 7 months ago

arjannv commented 8 months ago

I'm having an issue where the DeConz plugin crashes just after starting. I'm tested this with lated stable and beta release of the plugin. Also on latest stable of Domoticz and latest beta of DeConz.

Without the plugin, Domoticz runs just fine.

in the log I found this: The devices mentioned in the log are just plain and simple Hue lights.


2023-10-07 22:22:49.076  [7fd47bfff640] DeConz Hub: ### Request config
2023-10-07 22:22:49.081  [7fd47bfff640] Status: DeConz Hub: Firmware version: 0x26720700
2023-10-07 22:22:49.081  [7fd47bfff640] Status: DeConz Hub: Websocketnotifyall: True

2023-10-07 22:22:49.082  [7fd47bfff640] DeConz Hub: ### Request lights
2023-10-07 22:22:49.086  [7fd47bfff640] DeConz Hub: ### Device > 1 Name:WC2 Type:Dimmable light Details:{'alert': 'none', 'bri': 25, 'effect': 'none', 'on': False, 'reachable': True} and {'bri': {'execute_if_off': True, 'startup': 'previous'}, 'groups': ['0', '13'], 'on': {'startup': 'previous'}}
2023-10-07 22:22:49.088  [7fd47bfff640] DeConz Hub: ### Device > 10 Name:WC1 Type:Dimmable light Details:{'alert': 'none', 'bri': 25, 'effect': 'none', 'on': False, 'reachable': True} and {'bri': {'execute_if_off': True, 'startup': 'previous'}, 'groups': ['0', '6'], 'on': {'startup': 'previous'}}
2023-10-07 22:22:49.089  [7fd47bfff640] DeConz Hub: ### Device > 14 Name:Eetkamer Type:Dimmable light Details:{'alert': 'none', 'bri': 205, 'on': True, 'reachable': True} and {'groups': ['0', '8', '1']}
2023-10-07 22:22:49.089  [7fd47bfff640] DeConz Hub: ### Device > 17 Name:Configuration tool 17 Type:Configuration tool Details:{'reachable': True} and []
2023-10-07 22:22:49.089  [7fd47bfff640] DeConz Hub: Skipping Device (Useless) : 00:21:2e:ff:ff:05:21:c6-01
2023-10-07 22:22:49.089  [7fd47bfff640] DeConz Hub: ### Device > 18 Name:Zithoek Stalamp Type:Dimmable light Details:{'alert': 'none', 'bri': 204, 'on': True, 'reachable': True} and {'groups': ['0', '1']}
2023-10-07 22:22:49.090  [7fd47bfff640] Debug: SQLH HandleOnOffAction: OnAction:
2023-10-07 22:22:49.090  [7fd47bfff640] Debug: SQLH UpdateValueInt Zithoek Stalamp HwID:14  DevID:00:17:88:01:08:1b:cc:8f-0b Type:244  sType:73 nValue:1 sValue:80
Fatal Python error: Segmentation fault

Current thread 0x00007fd47bfff640 (most recent call first):
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1494 in UpdateDeviceProc
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1393 in UpdateDevice
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 806 in InitDomoticzDB
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 870 in NormalConnexion
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1161 in UpdateBuffer
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1120 in SendCommand
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 592 in ManageInit
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 951 in ReadConfig
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 854 in NormalConnexion
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1161 in UpdateBuffer
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1120 in SendCommand
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 592 in ManageInit
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 533 in onHeartbeat
  File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1233 in onHeartbeat

Extension modules: Domoticz (total: 1)
2023-10-07 22:22:49.093  [7fd47bfff640] Error: Domoticz(pid:5894, tid:5913('DeConz Hub')) received fatal signal 11 (Segmentation fault)
2023-10-07 22:22:49.093  [7fd47bfff640] Error: siginfo address=0x1706, address=0x7fd49f8bc9fc
2023-10-07 22:22:49.694  [7fd47bfff640] Error: Did not find stack frame for thread (LWP 5913)), printing full gdb output:
arjannv commented 8 months ago

Sorry... A device that was wrongly paired via DeConz messed it all up. Solved!

Smanar commented 8 months ago

A device that was wrongly paired via DeConz messed it all up. Solved!

Ha ? So a device can crash domoticz ? You had time to get more information ? Because not normal a python plugin can crash domoticz, it's a critic issue.

2023-10-07 22:22:49.090  [7fd47bfff640] Debug: SQLH UpdateValueInt Zithoek Stalamp HwID:14  DevID:00:17:88:01:08:1b:cc:8f-0b Type:244  sType:73 nValue:1 sValue:80
Fatal Python error: Segmentation fault

Values seem normal, I don't see what can provoque a Segmentation fault ... Because sValue is not an int ? but where is from the 80 value ...

arjannv commented 8 months ago

It was a Gledopto led dimmer. The GL-C-008. It needs to be reset by switching it off and on a number of times. While I was resetting that, it paired itself to deconz, but the process was not complete so it showed up as an unidentified device from Gledopto. Directly after pairing, I think Domoticz crashed. Then I removed the faulty device from deconz. After some trying to pair the dimmer again (unsuccessfully) I tried to restart Domoticz. But it wouldn’t. So I removed the deconz plugin from the Domoticz plugins folder and then Domoticz worked again. I could see the unidentified device in Domoticz and removed it. After that I re-added the deconz plugin and everything was working correctly again. I don’t know if I can replicate the issue again. Because I think it needs the incorrectly paired device in Domoticz. But I think I have a backup of the not-working-Domoticz folder so maybe that can be of use.

The devices shown in the log has nothing to do with this error I found out. I started removing devices from deconz that showed up in that log, but it still wouldn’t start. The faulty device I named “Border strip”, so it were not the devices in the log.

Smanar commented 8 months ago

So I removed the deconz plugin from the Domoticz plugins folder and then Domoticz worked again. I could see the unidentified device in Domoticz and removed it. After that I re-added the deconz plugin and everything was working correctly again.

Ha, so you have removed the device from the domoticz database ? in the "devices" list ? You haven't removed it from deconz ? And the plugin don't use database and remake a new one at every loading.

So something bad happen during the device creation in the domoticz database.

Thx for information.

Because I think it needs the incorrectly paired device in Domoticz. But I think I have a backup of the not-working-Domoticz folder so maybe that can be of use

If you have some free time, I will be happy if you can chek the domoticz database if you have a SQL browser, it's a SQL file Domoticz.db, perhaps we can see something usefull in the "deviceStatus" table. Else don't worry I will take a look on my side, but was probably just a "bad luck" event as it's the first time I see it.

arjannv commented 8 months ago

Ok, not quite solved.

I've removed it from DeConz first. But it was added to Domoticz as a "Interface Control" device.

In the mean time, i've managed to add the led dimmer. Had to create a manual DDF file. The plugin added it very weird to Domoticz: image

As I was trying to make Domoticz start again, I had removed some lights that showed up in the log. For instance, i've removed light/15. Only, when I added the gledopto dimmer, it took number "15" in the array. image

I've managed to start Domoticz again by removing the old light "15" from domoticz first.

Hope this makes sense... :)

arjannv commented 8 months ago

Thanks for your responses.

This happend for 2 more times as I was adding a few other lights that took the spot of old lights in the "lights" array. I needed to remove the old lights in Domoticz first before I could start Domoticz with the DeConz plugin without crashing again.

Also, please let me know if I still need to check some things in my database.

Smanar commented 8 months ago

Sorry was AFK for somes days. I don't think the problem is from deconz, as they are working fine without domoticz.

For me the probleme is more when domoticz create the entry in his own database, when you see it in the "devices" tab. There is so much problem on your capture :

What is your actual domoticz version ? If you prevent domoticz adding new devices, it will prevent crash if you haven't already "bad included one".

Give me 1h I will give you a debug line to add to test.

Smanar commented 8 months ago

Ok, seriously I will try with same version that you because I relay have no idea what can happen.

### Device > 14 Name:Eetkamer Type:Dimmable light Details:{'alert': 'none', 'bri': 205, 'on': True, 'reachable': True} and {'groups': ['0', '8', '1']}

This line is for all device see in deconz database. After that the plugin check if the device is or not in the domoticz database, if not the device is added on domoticz using this fonction.

def CreateDevice(IEEE, _Name, _Type, opt = 0):
    kwarg = Createdatawidget(IEEE, _Name, _Type, opt)
    Unit = FreeUnit()
    TypeName = ''

    if not kwarg:
        Domoticz.Error("Unknow device type " + _Type )
        return

    kwarg['DeviceID'] = IEEE
    kwarg['Name'] = _Name
    kwarg['Unit'] = Unit
    Domoticz.Device(**kwarg).Create()

    Domoticz.Status("### Create Device " + IEEE + " > " + _Name + ' (' + _Type +') as Unit ' + str(Unit) ) #Devices[Unit].ID

And I don't see how you can have this result, it's like all values are corrupted. Perhaps something visible in the log starting by ### Create Device

For me not possible haven't IEEE, for Unit the fonction scan from 1 to 256 to search a free one, so to have - 1.... How many zigbee device have you ? How many entries I mean, some temperature sensor can have 3 entries.

arjannv commented 8 months ago

Hi Smanar, thanks for trying these things. Sorry, was away for some time.

I don't know if i'm able to replicate this issue because everything is working fine now. But I might be able to put a backup in place.

Regarding the versions i'm running: First I was running the latest stable version of Domoticz, then I tried the latest beta. Same result on both. Also running latest stable of DeConz.

Regarding the number of entries: I've got 253 entries at the moment made by the DeConz plugin in Domoticz. This includes everything including groups, scenes etcetera.

Smanar commented 8 months ago

So can be the problem, I m on the old version with the 255 devices limits. But in my mind domoticz need to generate an error message, not writting garbage in the database to crash after ...

I will update the plugin this Week end, and start a special branch with the extended framework, I will keep you in touch.

Smanar commented 8 months ago

For information I have added a message status on start on beta branch, this message give the amount widget possible to create. And have started a new branch using the domoticz extended framework (without the 255 devices limits), the branch "extended".

This branch is working on my side, but I haven't tested all possible thing. Take care, you can switch from the actual code to the extended branch without problem, the rollback is probably possible, but if you create a widget on the "extended" branch the rollback will be impossible. So better to make a domotics database backup before testing the extended branch.

arjannv commented 8 months ago

Hi Smanar, Thank you for your work.

I will test the extended version once I've got some devices to add and after a back-up.

Tested the beta branch for now, it says that I have 2 "widgets" left.

Found 41 Operators, 140 Sensors, 25 Groups, 6 Scenes and 5 others, with 2 Ignored
You can still create 2 widgets in domoticz. 

Only it generates a lot of error messages right after restarting the plugin (even before connecting to deConz). Everything is working fine though.. Is this something related?

2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Knop Babykamer 0' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Knop Studeerkamer 0' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Koken' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Tv' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Party' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Portiek 1' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Portiek 2' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Portiek' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Tuinkamer Bar 1' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Tuinkamer Bar 2' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Tuinkamer Bar 3' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Tuinkamer Bar' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Tuinkamer Bar 4' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Tuinkamer Knop - Draai' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'PM2.5 Slaapkamer' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Waskamer' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Raam Babykamer' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Status' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Groep Tuin' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Knop Zithoek' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'Knop Zithoek Draai' Reference Count not correct, expected 1 found 2.
2023-11-01 14:07:54.412 Error: DeConz Hub: Stop: Device 'DeConz Hub - Tap switch 163 four-press' Reference Count not correct, expected 1 found 2.
Smanar commented 8 months ago

So you are testing the extended version ATM ? IDK first time I m seing thoses messages, they are from domoticz, not the plugin.

Edit: Have found a link https://www.domoticz.com/forum/viewtopic.php?t=36926

arjannv commented 7 months ago

Hi Smanar, Sorry, took some while.

I've tried the extended branch of the plugin. It is working, as I can add (new) devices without crashing Domoticz again.

Only got 1 error during start of the plugin. Everything is working fine though..


2023-11-17 14:54:30.289 Error: DeConz Hub: Call to function 'onHeartbeat' failed, exception details:
2023-11-17 14:54:30.290 Error: DeConz Hub: Traceback (most recent call last):
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1236, in onHeartbeat
2023-11-17 14:54:30.290 Error: DeConz Hub: _plugin.onHeartbeat()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 531, in onHeartbeat
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ManageInit()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 595, in ManageInit
2023-11-17 14:54:30.290 Error: DeConz Hub: self.SendCommand("/api/" + Parameters["Mode2"] + "/" + self.INIT_STEP[0] + "/")
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1123, in SendCommand
2023-11-17 14:54:30.290 Error: DeConz Hub: self.UpdateBuffer()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1164, in UpdateBuffer
2023-11-17 14:54:30.290 Error: DeConz Hub: self.NormalConnexion(_Data)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 857, in NormalConnexion
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ReadConfig(_Data)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 954, in ReadConfig
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ManageInit(True)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 595, in ManageInit
2023-11-17 14:54:30.290 Error: DeConz Hub: self.SendCommand("/api/" + Parameters["Mode2"] + "/" + self.INIT_STEP[0] + "/")
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1123, in SendCommand
2023-11-17 14:54:30.290 Error: DeConz Hub: self.UpdateBuffer()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1164, in UpdateBuffer
2023-11-17 14:54:30.290 Error: DeConz Hub: self.NormalConnexion(_Data)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 876, in NormalConnexion
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ManageInit(True)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 595, in ManageInit
2023-11-17 14:54:30.290 Error: DeConz Hub: self.SendCommand("/api/" + Parameters["Mode2"] + "/" + self.INIT_STEP[0] + "/")
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1123, in SendCommand
2023-11-17 14:54:30.290 Error: DeConz Hub: self.UpdateBuffer()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1164, in UpdateBuffer
2023-11-17 14:54:30.290 Error: DeConz Hub: self.NormalConnexion(_Data)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 876, in NormalConnexion
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ManageInit(True)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 595, in ManageInit
2023-11-17 14:54:30.290 Error: DeConz Hub: self.SendCommand("/api/" + Parameters["Mode2"] + "/" + self.INIT_STEP[0] + "/")
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1123, in SendCommand
2023-11-17 14:54:30.290 Error: DeConz Hub: self.UpdateBuffer()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1164, in UpdateBuffer
2023-11-17 14:54:30.290 Error: DeConz Hub: self.NormalConnexion(_Data)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 876, in NormalConnexion
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ManageInit(True)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 595, in ManageInit
2023-11-17 14:54:30.290 Error: DeConz Hub: self.SendCommand("/api/" + Parameters["Mode2"] + "/" + self.INIT_STEP[0] + "/")
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1123, in SendCommand
2023-11-17 14:54:30.290 Error: DeConz Hub: self.UpdateBuffer()
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1164, in UpdateBuffer
2023-11-17 14:54:30.290 Error: DeConz Hub: self.NormalConnexion(_Data)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 876, in NormalConnexion
2023-11-17 14:54:30.290 Error: DeConz Hub: self.ManageInit(True)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 582, in ManageInit
2023-11-17 14:54:30.290 Error: DeConz Hub: Unit = getDeviceUnit(i)
2023-11-17 14:54:30.290 Error: DeConz Hub: File "/home/arjan/domoticz/plugins/Domoticz-deCONZ/plugin.py", line 1345, in getDeviceUnit
2023-11-17 14:54:30.290 Error: DeConz Hub: return list(Devices[device].Units)[0]
2023-11-17 14:54:30.290 Error: DeConz Hub: IndexError: list index out of range
Smanar commented 7 months ago

Hello, have updated the branch "extended", (you can update it just with a "git pull"), this change will make 2 things.

Prevent this kind of error display. Print a domoticz error with some informations.

I can hide this error, but it mean you have a device in the domoticz list without units, and IDK what It can be ...

arjannv commented 7 months ago

Hi Smanar,

Thanks for the update. The error in Domoticz now had some more info. Deleted the old/wrong device and now everything is working fine!

Thanks for your support!

Smanar commented 7 months ago

Deleted the old/wrong device and now everything is working fine!

Can you explain me what was the problem ?

For information I will now develop 2 branchs for the plugin (I m too shy to make a100% extended version ^^), the normal and the extended one, so you will have all new futures improvements on the branch you are using ATM too.

arjannv commented 7 months ago

It was an old Group Switch that did not exist anymore in deConz. Don't know what was wrong with it. I understand :) I'll keep using it and will let you know if I find anything.

arjannv commented 5 months ago

Hi Smanar, there seems to be some other problem with the Extended branch.

I've got 2 Danfoss radiator valves connected via DeConz. Since the move to the extended branch, they behave funny. I can't change the setpoint from Domoticz anymore and the temperature reading from the device is all over the place.

Here you can see the blue temperature lines acting weird. All other temperature sensors work OK. plugin

Also, maybe related to this. I can't change the speed of my Ikea Starkvind purifier in Domoticz.

Smanar commented 5 months ago

I think 17.5°C and 18°C are your heatpoint value ?

Have updated the code on the branch "extended", I think it will solve this problem. And yes the problem on stakvind and problem on setpoint can come from same issue, but I don't see the problem on my side.

Can you share some logs when changing a setpoint for exemple ? (with "debug info only")

arjannv commented 5 months ago

Thanks for your quick response!

The setpoints are the orange striped lines. The yellow line is from another temperature sensor in the same room.

Without updating the plugin I get the following: The setpoint of the thermostat is changed, only it is not visible in Domoticz.


2024-01-16 16:24:21.157 DeConz Hub: onCommand called for DevideID: 14:b4:57:ff:fe:d3:c3:c3-01-0201_heatsetpoint Unit:144: Parameter 'Set Level', Level: 20.0, Hue:
2024-01-16 16:24:21.157 DeConz Hub: Send Command /api/13485B9E27/sensors/94/config with {'heatsetpoint': 2000} (0 in buffer)
2024-01-16 16:24:21.157 DeConz Hub: Making Request: http://127.0.0.1:80/api/13485B9E27/sensors/94/config with params {'heatsetpoint': 2000}
2024-01-16 16:24:21.161 DeConz Hub: Request Return: [{"success":{"/sensors/94/config/heatsetpoint":2000}}]
2024-01-16 16:24:21.161 DeConz Hub: Classic Data : [{'success': {'/sensors/94/config/heatsetpoint': 2000}}]
2024-01-16 16:24:21.161 DeConz Hub: onMessage called
2024-01-16 16:24:21.161 DeConz Hub: ### WebSocket Data : {'config': {'battery': 70, 'displayflipped': False, 'externalsensortemp': -8000, 'externalwindowopen': False, 'heatsetpoint': 2000, 'loadbalancing': True, 'locked': False, 'mode': 'heat', 'mountingmode': False, 'offset': 0, 'on': True, 'radiatorcovered': False, 'reachable': True, 'schedule': {}, 'schedule_on': False, 'windowopendetectionenabled': True}, 'e': 'changed', 'id': '94', 'r': 'sensors', 't': 'event', 'uniqueid': '14:b4:57:ff:fe:d3:c3:c3-01-0201'}
2024-01-16 16:24:21.161 DeConz Hub: ### Update device (Radiator Tuinkamer) : {'BatteryLevel': 70, 'nValue': 0, 'sValue': '20.0'}
2024-01-16 16:24:21.163 DeConz Hub: ### Update device (Radiator Tuinkamer) : {'BatteryLevel': 70, 'nValue': 10, 'sValue': '10'}
2024-01-16 16:24:21.166 DeConz Hub: ### Update device (Radiator Tuinkamer) : {'BatteryLevel': 70, 'nValue': 10, 'sValue': '10'}, IGNORED , no changes !
2024-01-16 16:24:21.138 Status: User: arjan initiated a SetPoint command
arjannv commented 5 months ago

I've just updated the plugin. The thermostat setpoint change is now also visible in Domoticz. Starkvind is working again as well.

I'll wait a bit to see if the temperature log from the radiator valve is also back to normal.

Smanar commented 5 months ago

Ha nice, so all problems was concerning the same error ?

arjannv commented 5 months ago

Yes, apparently. 😃 Temperature sensor values also seems stable. So, thanks for that! I think all problems in the extended branch are now gone.

Smanar commented 5 months ago

Lol, for the moment at least. But if you have problem, don't hesitate to say it, I will try to correct it as fast I can, you are the only beta-tester I have for this branch ^^.

I m too shy to make an official migration.

arjannv commented 5 months ago

Haha, I've been running my home of this branch since november with a lot of different devices. And these devices where the only ones that behaved funny. Currently on 227 devices though, still below the original limit (30 widgets left).

But I understand :) Best to be on the safe side.