Error sending switch command, check device/hardware ! ACK problems gateway to node.

  • I am working on upgrading a couple of existing Mysensor 1.5 networks to the latest version and am again running into this behavior of getting the dreaded error message: "Error sending switch command, check device/hardware !" from the Domoticz UI when trying to send commands from the controller to Relay nodes. Even just using the relay example from the lib shows the problem. I am convinced that this is not a common HW issue as often blamed. The issue has been verified with a multitude of HW and I see no other communication issues such as range etc.

    So, the problem shows up on any message sent from the controller to a node. For testing purposes the network has only the Gateway and one Relay node. When clicking on the Lightbulb device to affect the relay most times, but not always, you see the error message after the timeout, even though the command was received and handled by the device right away. You also see that the controller sends the command a second time, when this happens ( about 90% of the times) .. No change in network frequency or phase of the moon makes a difference here.

    Now here is what I found that did make a difference:

    When I go on the Domoticz UI under "Setup/Hardware" and drill down through the Gateway "Setup" link to the Node and then select the child under scrutiny, I see at the bottom of the page an On/OFF selector labeled "ACK" together with a timeout value of 1200 . If I turn this "ACK" off then the node works flawlessly -- a million times / forth and back and even through power failures of the gateway/controller. I see only one command sent and no error messages ever.

    Upon further investigation I further found that right after initial inclusion of a node this "ACK" feature seems to be off. The node works without retires/ error messages, however only until you go and update it with a name for example, then the ACK features gets turned on by default.

    Now the question to @hek is : What is this "ACK" feature doing-to/expecting-from a node. Is this looking at the HW ACK from the NRF24 radio and that's what is getting missed by the GW most of the times. Is there some sort of TX/RX turn around time that is too short possibly? Or is this based on some response packet the node is expected to send from it's receive function? I did not see anything mentioned in the examples or the .h files to that effect.

    When checking the HW-ACK from the Node to the GW ( in the node sketch ) I find that it works as expected. I only get NACKs when I block the antenna sufficiently to suppress the transmission.

    Disabling the "ACK" feature for the node via Setup/Hardware/MyGateway/node/child on Domoticz is a workaround but probably not the desirable solution, especially as long as the problem is not fully understood.

    @hek @Yveaux ??

Log in to reply

Suggested Topics