From a7602eae5ee3be9c987a2b4ed55aabb3d075ff55 Mon Sep 17 00:00:00 2001 From: dragonpilot Date: Fri, 11 Oct 2019 09:57:07 +1000 Subject: [PATCH] Improve honda dp_allow_gas logic --- selfdrive/car/honda/carcontroller.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/selfdrive/car/honda/carcontroller.py b/selfdrive/car/honda/carcontroller.py index 76f4fbbe7..59ae644ce 100644 --- a/selfdrive/car/honda/carcontroller.py +++ b/selfdrive/car/honda/carcontroller.py @@ -194,10 +194,11 @@ class CarController(): gasPressed = CS.pedal_gas > 0 else: gasPressed = CS.user_gas_pressed + dragon_apply_brake = apply_brake if self.dragon_allow_gas and gasPressed: - apply_brake = 0 + dragon_apply_brake = 0 apply_gas = 0 - can_sends.append(hondacan.create_brake_command(self.packer, apply_brake, pump_on, + can_sends.append(hondacan.create_brake_command(self.packer, dragon_apply_brake, pump_on, pcm_override, pcm_cancel_cmd, hud.fcw, idx, CS.CP.carFingerprint, CS.CP.isPandaBlack)) self.apply_brake_last = apply_brake