GM: resolve cruise faults (#24167)

* these should be enabled

* bump panda

* bump

* allow in pre-enabled state

* bump panda

* add comment

* bump and update refs

* bump panda

* bump panda
old-commit-hash: 0f61a388c394ad5b6f25446c1e76558c1f4cead7
This commit is contained in:
Shane Smiskol
2022-04-07 20:44:09 -07:00
committed by GitHub
parent eeeec4c2f4
commit f49522474c
3 changed files with 6 additions and 5 deletions

2
panda

Submodule panda updated: ad4f69cd18...f088af5664

View File

@@ -63,7 +63,7 @@ class CarController:
# Gas/regen and brakes - all at 25Hz
if (self.frame % 4) == 0:
if not CC.longActive:
# Stock ECU sends max regen when not enabled.
# Stock ECU sends max regen when not enabled
self.apply_gas = self.params.MAX_ACC_REGEN
self.apply_brake = 0
else:
@@ -74,13 +74,14 @@ class CarController:
at_full_stop = CC.longActive and CS.out.standstill
near_stop = CC.longActive and (CS.out.vEgo < self.params.NEAR_STOP_BRAKE_PHASE)
# GasRegenCmdActive needs to be 1 to avoid cruise faults. It describes the ACC state, not actuation
can_sends.append(gmcan.create_gas_regen_command(self.packer_pt, CanBus.POWERTRAIN, self.apply_gas, idx, CC.enabled, at_full_stop))
can_sends.append(gmcan.create_friction_brake_command(self.packer_ch, CanBus.CHASSIS, self.apply_brake, idx, near_stop, at_full_stop))
can_sends.append(gmcan.create_gas_regen_command(self.packer_pt, CanBus.POWERTRAIN, self.apply_gas, idx, CC.longActive, at_full_stop))
# Send dashboard UI commands (ACC status), 25hz
if (self.frame % 4) == 0:
send_fcw = hud_alert == VisualAlert.fcw
can_sends.append(gmcan.create_acc_dashboard_command(self.packer_pt, CanBus.POWERTRAIN, CC.longActive,
can_sends.append(gmcan.create_acc_dashboard_command(self.packer_pt, CanBus.POWERTRAIN, CC.enabled,
hud_v_cruise * CV.MS_TO_KPH, hud_control.leadVisible, send_fcw))
# Radar needs to know current speed and yaw rate (50hz),

View File

@@ -1 +1 @@
c1a729c087e9f26e40d8f7db5bdfe62d12fb0bc9
c93e3735143a88f0088eb23e6fde56660d4a53e2