Closed bvhoesel closed 3 months ago
Yes, I noticed the same, and will look into it this weekend.
Did some more testing. If there is movement the stop command (from a 'binds + stop' device) does work. The previous mentioned exact values 1 and 99 are not the whole situation. I also get sometimes movement if I move the slider (very) slow with a back and forward move. Then it will pick up a position setting and sends is successfully to the Slide. Looking at the debug logs is seems that (most of the time) a successful call starts with something like:
Pushing 'onCommandCallback' on to queue Processing 'onCommandCallback' message Slide: Acquiring GIL for 'onCommandCallback' Calling message handler 'onCommand' on 'module' type object. onCommand called for Unit 1: Parameter 'Set Level', Level: 1
And it has a hex dump of the /rpc/Slide.SetPos url to send.
A failing call starts with something like:
Part 1: 86... Part 2: 5c... {"Verb": ...snipped... }
This gives the impression as if parts of the code are not executed because the plugin 'onCommand' debug message is missing. And it is missing the SetPos hex dump. So it seems the command is never send to the Slide.
And ... to complicate things ...
I added my second Slide to the local config. Now I get a more or less consistent error every 30 seconds (no slide actions from my side, heartbeat?). The errors vary from the 3 below
Error: Slide: Failed to connect (125) to: x.x.x.x with error: Operation canceled Error: Slide: No transport, write directive to 'Slide_32' ignored. Error: Slide: Transport is not connected, write directive to 'Slide_88' ignored.
The IP it cannot connect to is the first IP address added! No issue apparently with the newly added IP?
Can you test latest version?
Solved with #6
Thanks for the quick solution. If I may add one comment still? It is working with the setting 'Reverse Position:' enabled. (Yes I do use a position to not fully open the curtain).
Since the Slide cloud is is going to be shut down I tried to switch to this local Domoticz plugin.
Unfortunately this is not working at the moment. After enabling the plugin and entering the needed Slide info there is no movement of the curtain when using the open or close buttons in Domoticz.
The following curl command do work, showing the Slide is in local mode:
curl http://x.x.x.x/rpc/Slide.GetInfo
curl -X POST \ 'x.x.x.x/rpc/Slide.SetPos' \ --header 'Accept: /' \ --header 'Content-Type: application/json' \ --data-raw '{ "pos": 0.5 }'
And with expected results of the info asked and partially closing the curtains. Even without authentication! Needed info taken from the provided postman files.
After activating 'All' debug of the plugin there is no error information on using the open and close buttons. Only the (successful) heartbeats show in the log:
Slide: onCommand called for Unit 1: Parameter 'Close', Level: 0 Status: User: admin (IP: 172.21.143.11) initiated a switch command (515/Slide - Slide/Close) Slide: onHeartbeat called
Direct setting the slider does generate some debug log. The log shows the (expected) url to be executed but nothing is moving. And a general error is shown:
Error: Slide: Transport is not connected, write directive to 'Slide_266' ignored.
The only way I discovered to get some action from Domoticz is using the slider with exact values 1 and 99 to open and close the curtains. Other values trigger no action.
This issue looks al lot like the 'latest' issue solved for the cloud plugin from December 2022.
Is there any change this plugin can be fixed and be working again in the latest Domoticz? I really would appreciate that. Might also be great and useful for others who want (need) to migrate to a local solution.
Thanks in advance.