idea: allow the present function to indicate if an echo will be sent


  • Plugin Developer

    An echo is a great way of making sure data is actually delivered. Currently, a node can request an echo from the controller.

    But how about the other way around? It would be great if the node could indicate to the controller that if it sends for a specific child, then the node will echo this back to confirm it was received.

    For example, imagine a door lock child. If during the presentation the child could indicate "I will always let you know if I received a state update", then the controller could resend the data if no echo was received.


  • Mod

    @alowhum I don't agree that echo is a great way to make sure data is actually delivered. There are lots of cases where an echo is insufficient, especially if the device sends another message without waiting for the echo to be received / time out.

    A small correction: The controller is not involved in echo. The destination MySensors node sends the echo. In your case that node is probably the gateway.

    I don't have sufficient knowledge to comment on if/how controllers can be involved, but I think some controllers already do something similar to what you are asking for,


  • Plugin Developer

    I suspect I'm not being clear, so let me give an example instead.

    With the WebThings Gateway add-on I've created, which is based on the PyMySensors library, this works:

    NODE: Hey, the user has changed the boolean state on my end, please update the controller UI and acknowledge with an echo.
    CONTROLLER: Ok, I received your message.
    NODE: thanks, now that I am sure you received my message, and I will stop trying to resend it.

    But I would like this to work as well:

    CONTROLLER: Hey node, please change the boolean state, and send me an echo.
    NODE: Ok, I've changed the relay state. Here's an echo to indicate I received your message.
    CONTROLLER: Ok, thanks, I will allow the new state in the UX to stay as it is now instead of reverting after a few seconds.

    The thing I'm advocating for is to streamline/automate this second process somewhat, and during the presentation phase let the controller know of which children it can try to ask an echo, and which won't generate an echo.

    Maybe I should have called it ACK instead of Echo.


  • Mod

    @alowhum no you should definitely not call it ACK. I have spent many hours to eradicate the mention of ACK (when it doesn’t really mean ack) in the MySensors code.

    To my knowledge, the MySensors library itself will send an echo when requested. There is no need to present if the node supports echo or not, echo is always enabled.


  • Plugin Developer

    @mfalkvidd said in idea: allow the present function to indicate if an echo will be sent:

    To my knowledge, the MySensors library itself will send an echo when requested. There is no need to present if the node supports echo or not, echo is always enabled.

    Very interesting!


Log in to reply
 

Suggested Topics

  • 90
  • 13
  • 1
  • 2
  • 3
  • 5

0
Online

11.2k
Users

11.1k
Topics

112.5k
Posts