mirror of
https://github.com/dragonpilot/dragonpilot.git
synced 2026-09-30 11:23:44 +08:00
do not allow stock_dsu mode on reverse/park/neutural gear
This commit is contained in:
@@ -132,6 +132,8 @@ class CarState(CarStateBase):
|
||||
|
||||
if self.dragon_toyota_stock_dsu and ret.cruiseState.available:
|
||||
enable_acc = True
|
||||
if ret.gearShifter in [car.CarState.GearShifter.reverse, car.CarState.GearShifter.park, car.CarState.GearShifter.neutral]:
|
||||
enable_acc = False
|
||||
if ret.seatbeltUnlatched or ret.doorOpen:
|
||||
enable_acc = False
|
||||
ret.cruiseState.enabled = enable_acc
|
||||
|
||||
Reference in New Issue
Block a user