mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-02-18 21:14:01 +08:00
hyundai: disable steering on all steer warnings (#20657)
* hyundai: set CF_Lkas_ToiFlt for wind down
* hyundai: disable steering on all steer warnings
* Revert "hyundai: set CF_Lkas_ToiFlt for wind down"
This reverts commit 065f0a996db9e52511013c7011ed95876966d134.
* update refs
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 6e300aaf57
This commit is contained in:
@@ -49,8 +49,8 @@ class CarController():
|
||||
apply_steer = apply_std_steer_torque_limits(new_steer, self.apply_steer_last, CS.out.steeringTorque, self.p)
|
||||
self.steer_rate_limited = new_steer != apply_steer
|
||||
|
||||
# disable if steer angle reach 90 deg, otherwise mdps fault in some models
|
||||
lkas_active = enabled and abs(CS.out.steeringAngleDeg) < CS.CP.maxSteeringAngleDeg
|
||||
# disable when temp fault is active
|
||||
lkas_active = enabled and not CS.out.steerWarning
|
||||
|
||||
# fix for Genesis hard fault at low speed
|
||||
if CS.out.vEgo < 16.7 and self.car_fingerprint == CAR.HYUNDAI_GENESIS:
|
||||
|
||||
@@ -27,14 +27,8 @@ class CarInterface(CarInterfaceBase):
|
||||
ret.steerLimitTimer = 0.4
|
||||
tire_stiffness_factor = 1.
|
||||
|
||||
ret.maxSteeringAngleDeg = 90.
|
||||
ret.startAccel = 1.0
|
||||
|
||||
eps_modified = False
|
||||
for fw in car_fw:
|
||||
if fw.ecu == "eps" and b"," in fw.fwVersion:
|
||||
eps_modified = True
|
||||
|
||||
if candidate == CAR.SANTA_FE:
|
||||
ret.lateralTuning.pid.kf = 0.00005
|
||||
ret.mass = 3982. * CV.LB_TO_KG + STD_CARGO_KG
|
||||
@@ -66,8 +60,6 @@ class CarInterface(CarInterfaceBase):
|
||||
ret.steerRatio = 13.75 * 1.15
|
||||
ret.lateralTuning.pid.kiBP, ret.lateralTuning.pid.kpBP = [[0.], [0.]]
|
||||
ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.3], [0.05]]
|
||||
if eps_modified:
|
||||
ret.maxSteeringAngleDeg = 1000.
|
||||
elif candidate in [CAR.ELANTRA, CAR.ELANTRA_GT_I30]:
|
||||
ret.lateralTuning.pid.kf = 0.00006
|
||||
ret.mass = 1275. + STD_CARGO_KG
|
||||
|
||||
@@ -1 +1 @@
|
||||
7ed0df84ad09e52f53311f038d7765623ba710b2
|
||||
32ee8c7581957064cc24b6c11e1ccf80295a71ae
|
||||
Reference in New Issue
Block a user