diff --git a/meshtastic/mesh_interface.py b/meshtastic/mesh_interface.py index 7052bc5fd..17eb9424e 100644 --- a/meshtastic/mesh_interface.py +++ b/meshtastic/mesh_interface.py @@ -670,7 +670,8 @@ def sendTraceRoute( hopLimit=hopLimit, ) # extend timeout based on number of nodes, limit by configured hopLimit - waitFactor = min(len(self.nodes) - 1 if self.nodes else 0, hopLimit) + nodes_based_factor = (len(self.nodes) - 1) if self.nodes else (hopLimit + 1) + waitFactor = max(1, min(nodes_based_factor, hopLimit + 1)) self.waitForTraceRoute(waitFactor) def onResponseTraceRoute(self, p: dict):