Nudgeless lane change
Added toggles for nudgeless lane changes, lane detection, and one lane change per signal activation with a lane change delay factor.
This commit is contained in:
@@ -68,7 +68,7 @@ class FrogPilotPlanner:
|
||||
self.cem.update(carState, enabled, sm['frogpilotNavigation'], modelData, sm['radarState'], self.road_curvature, self.stop_distance, mpc.t_follow, v_ego)
|
||||
|
||||
# Update the current lane widths
|
||||
check_lane_width = self.adjacent_lanes or self.blind_spot_path
|
||||
check_lane_width = self.adjacent_lanes or self.blind_spot_path or self.lane_detection
|
||||
if check_lane_width and v_ego >= LANE_CHANGE_SPEED_MIN:
|
||||
self.lane_width_left = float(self.fpf.calculate_lane_width(modelData.laneLines[0], modelData.laneLines[1], modelData.roadEdges[0]))
|
||||
self.lane_width_right = float(self.fpf.calculate_lane_width(modelData.laneLines[3], modelData.laneLines[2], modelData.roadEdges[1]))
|
||||
@@ -156,6 +156,9 @@ class FrogPilotPlanner:
|
||||
self.adjacent_lanes = custom_ui and params.get_bool("AdjacentPath")
|
||||
self.blind_spot_path = custom_ui and params.get_bool("BlindSpotPath")
|
||||
|
||||
nudgeless_lane_change = params.get_bool("NudgelessLaneChange")
|
||||
self.lane_detection = nudgeless_lane_change and params.get_bool("LaneDetection")
|
||||
|
||||
longitudinal_tune = params.get_bool("LongitudinalTune")
|
||||
self.acceleration_profile = params.get_int("AccelerationProfile") if longitudinal_tune else 0
|
||||
self.deceleration_profile = params.get_int("DecelerationProfile") if longitudinal_tune else 0
|
||||
|
||||
Reference in New Issue
Block a user