Skip to content

Commit

Permalink
ToyotaFlags.RAISED_ACCEL_LIMITが立った時に対処。
Browse files Browse the repository at this point in the history
  • Loading branch information
ikawaoka committed Dec 2, 2024
1 parent dd6185e commit e6303b9
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions opendbc/car/toyota/carcontroller.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,13 @@ def get_long_tune(CP, params):
if CP.flags & ToyotaFlags.RAISED_ACCEL_LIMIT:
kiV = [0.0]
else:
# kiBP = [0., 5., 35.]
# kiV = [3.6, 2.4, 1.5]
# kiBP = [0.] #<-[0., 5., 35.],上と一緒
kiV = [1.2] # <-[3.6, 2.4, 1.5]
if CP.flags & ToyotaFlags.RAISED_ACCEL_LIMIT:
kiBP = [0., 5., 35.]
kiV = [3.6, 2.4, 1.5]
else:
# cydia method
# kiBP = [0.] #上と一緒
kiV = [1.2]

return PIDController(0.0, (kiBP, kiV), k_f=1.0, k_d=(kdBP, kdV),
pos_limit=params.ACCEL_MAX, neg_limit=params.ACCEL_MIN,
Expand Down

0 comments on commit e6303b9

Please sign in to comment.