This commit is contained in:
Your Name
2024-02-05 00:25:42 -06:00
parent b7cb5c8893
commit 425594dd0c
3 changed files with 10 additions and 8 deletions

1
commit_and_push Normal file
View File

@@ -0,0 +1 @@
git add -A; git commit -m "wip"; bash push_github

View File

@@ -343,11 +343,11 @@ class Controls:
# self.events.add(EventName.laneChange)
# Handle turning
if not CS.standstill:
if self.sm['lateralPlan'].desire == Desire.turnLeft:
self.events.add(FrogPilotEventName.turningLeft)
elif self.sm['lateralPlan'].desire == Desire.turnRight:
self.events.add(FrogPilotEventName.turningRight)
# if not CS.standstill:
# if self.sm['lateralPlan'].desire == Desire.turnLeft:
# self.events.add(FrogPilotEventName.turningLeft)
# elif self.sm['lateralPlan'].desire == Desire.turnRight:
# self.events.add(FrogPilotEventName.turningRight)
for i, pandaState in enumerate(self.sm['pandaStates']):
# All pandas must match the list of safetyConfigs, and if outside this list, must be silent or noOutput

View File

@@ -91,10 +91,11 @@ class DesireHelper:
if not lateral_active or self.lane_change_timer > LANE_CHANGE_TIME_MAX:
self.lane_change_state = LaneChangeState.off
self.lane_change_direction = LaneChangeDirection.none
elif one_blinker and below_lane_change_speed and frogpilot_planner.turn_desires:
self.turn_direction = TurnDirection.turnLeft if carstate.leftBlinker else TurnDirection.turnRight
# elif one_blinker and below_lane_change_speed and frogpilot_planner.turn_desires:
# BBOT
# self.turn_direction = TurnDirection.turnLeft if carstate.leftBlinker else TurnDirection.turnRight
# Set the "turn_completed" flag to prevent lane changes after completing a turn
self.turn_completed = True
# self.turn_completed = True
else:
# TurnDirection.turnLeft / turnRight
self.turn_direction = TurnDirection.none