navd: fix hysteresis when reaching destination (#29032)

fix destination hysteresis when reaching destination
pull/214/head
Shane Smiskol 2 years ago committed by GitHub
parent 412ed6a017
commit 431a2542c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      selfdrive/navd/navd.py

@ -274,11 +274,11 @@ class RouteEngine:
self.reset_recompute_limits()
else:
cloudlog.warning("Destination reached")
Params().remove("NavDestination")
# Clear route if driving away from destination
dist = self.nav_destination.distance_to(self.last_position)
if dist > REROUTE_DISTANCE:
self.params.remove("NavDestination")
self.clear_route()
def send_route(self):

Loading…
Cancel
Save