It could be. I'm not sure. The node does send ACK but domoticz has a too short timeout for the ACK to arrive. On the communication channel, the ACK is sent to domoticz before domoticz sends the second message but I am not sure of the order "inside" domoticz. I have a different thread where I have explained the problem with ACK timeout. This might be related to that. The ACK timeout really needs to be increased for MySensors, or be configurable. I have a simple setup, with one gateway and one node. The only difference from the simplest form is that I enable message signing with add some time to message processing. This appear to make the turnaround for a message be slightly longer than domoticz accepts. Other controller softwares I have tried does not seem to have a problem with this. I suspect their ACK timeouts are longer.
Just started with Domoticz, and have implemented my sensors. Firstly, the ack seems to work great returning an error if it isn't received! Thanks.
My question is, I have a number of flows that send with a relay action on a my sensors node. i.e. if node reports reports rain, toggle node relay. The issue is, the node relay is attached to my robot mower, which might be out of range cutting the garden... What I'd like is for the toggle to be resent until it's successful, instead of just once (which might fail, thanks to ack). Any ideas?
I had the same feeling that the timeout is too short and the message is send twice (while using HW signing). I just did some experimenting using the Soft Signing in, the response is faster which ensure that the ACK is received by Domoticz within the 1200ms. When using the Secure Element (HW signing) the time to produce the nonce, wait for the signed message (from GW), verifying the signed message, and sending back the message with the ACK seem to take too long. Currently, the retry counter (hardware/MySensorsBase.cpp) is 12 with a 100ms sleep. By gradually increasing the counter the timeout (and resending the same message) stopped occurring from 14 (~1.4s) or higher.
As I use HW signing on all my nodes to ensure a proper random number, besides sensors that only send stuff (e.g. door sensors as they get the nonce from the GW) I would be great if this can be added as an options that can be set in the Setup > Hardware > Mysensors, or at least increase it to >1.4 seconds.
BTW great work what you did on the signing, this was one of my prerequisites before using My Sensors. Ensuring authenticity and integrity are key and in my opinion a minimum requirement for all IoT devices.
Hi,
yes, I have noticed the same thing. This in combination with the fact that a node can be several hops away, strongly motivates a setting to make ACK timeout longer or at least configurable. I have filed a issue on the github page for this. Hopefully, it will be included in future releases.
Thanks, btw
Thanks for filing the issue. Actually, I should register on GitHub as well. As I'm gratefully using Domoticz (and My Sensors) it would be great to contribute if/where possible.