Battery nodes and communication failure
-
If I understand correctly, with the default settings nodes will keep trying forever if they are unable to reach the gateway.
Therefore, I have set
#define MY_TRANSPORT_WAIT_READY_MS (30000) // Don't stay awake for more than 30s if communication is broken
in my sketch. Is this a good way to handle temporary communication failures (gw has crashed for example)? Or will there be negative side-effects? Is there a better way to make sure battery-powered nodes don't drain the battery if the gateway becomes unavailable? Will the node be able to reestablish communication next time it wakes up and the gateway is available?
-
Hi, it looks like this constant is used only during the first initialization of the node, when the parent_id and the node_id are being written to the node's eeprom, not during normal operation.
I tested a method from another suggestion on this forum, to ask the controller for the last value sent by the node, since if you ask for data it do times out and you could then assume that the gateway was offline or some other network error occurred, but this technique did not work all the time.
I have power outages here that disable the gateway and then the nodes eat up their batteries trying to resend the same message over and over and I would love to find a way to stop this from happening too.
Suggested Topics
-
Arduino Celebrates 10 years (Malmö/Sweden)
Announcements • 29 Mar 2014, 17:08 • hek 29 Mar 2014, 17:08 -
Saving last known good state, but not in EEPROM
Development • 30 Jan 2024, 18:46 • OldSurferDude 15 Jan 2025, 08:51 -
Counting Incoming and Outgoing Messages from a Gateway
Development • 10 Dec 2024, 21:57 • Trand 14 Dec 2024, 20:23 -
Adding Listen only device to my system.
Development • 26 Feb 2025, 00:39 • dpcons 26 Feb 2025, 06:26 -
Sending offset to node
Development • 31 Jan 2025, 00:59 • bsl88k 4 Feb 2025, 12:14 -
PJON and Minicore not working
Development • 9 days ago • Trand 9 days ago