Skip to content

Commit

Permalink
use orignal counter
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasloetkolben committed Sep 23, 2024
1 parent 210c29c commit 0e78fbd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion opendbc/car/tesla/carcontroller.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def update(self, CC, CS, now_nanos):
if hands_on_fault:
state = 13 # "ACC_CANCEL_GENERIC_SILENT"
accel = clip(actuators.accel, CarControllerParams.ACCEL_MIN, CarControllerParams.ACCEL_MAX)
cntr = (self.frame // 4) % 8
cntr = CS.das_control["DAS_controlCounter"]
can_sends.append(self.tesla_can.create_longitudinal_command(state, accel, cntr))

# Increment counter so cancel is prioritized even without openpilot longitudinal
Expand Down

0 comments on commit 0e78fbd

Please sign in to comment.