diff --git a/selfdrive/car/gm/carcontroller.py b/selfdrive/car/gm/carcontroller.py index 0b73cf55d..c7520ec18 100644 --- a/selfdrive/car/gm/carcontroller.py +++ b/selfdrive/car/gm/carcontroller.py @@ -449,7 +449,7 @@ class CarController(CarControllerBase): ) and CS.out.cruiseState.enabled: if (self.frame - self.last_button_frame) * DT_CTRL > 0.04: self.last_button_frame = self.frame - can_sends.append(gmcan.create_buttons(self.packer_pt, CanBus.POWERTRAIN, (CS.buttons_counter + 1) % 4, CruiseButtons.CANCEL)) + can_sends.append(gmcan.create_buttons(self.packer_pt, CanBus.CAMERA, (CS.buttons_counter + 1) % 4, CruiseButtons.CANCEL)) else: # While car is braking, cancel button causes ECM to enter a soft disable state with a fault status. diff --git a/selfdrive/car/gm/carstate.py b/selfdrive/car/gm/carstate.py index bb2ca43e4..bde897ca1 100644 --- a/selfdrive/car/gm/carstate.py +++ b/selfdrive/car/gm/carstate.py @@ -165,9 +165,9 @@ class CarState(CarStateBase): ret.cruiseState.speed = pt_cp.vl["ECMCruiseControl"]["CruiseSetSpeed"] * CV.KPH_TO_MS # Try ECM first for cars that might have it (like most GMs), fall back to ASCM try: - ret.cruiseState.enabled = pt_cp.vl["ECMCruiseControl"]["CruiseActive"] != 0 - except: ret.cruiseState.enabled = cam_cp.vl["ASCMActiveCruiseControlStatus"]["ACCCmdActive"] != 0 + except: + ret.cruiseState.enabled = pt_cp.vl["ECMCruiseControl"]["CruiseActive"] != 0 if self.CP.enableBsm: if self.CP.carFingerprint not in SDGM_CAR: