This commit is contained in:
Your Name
2024-05-04 02:51:58 -05:00
parent 6191a455dd
commit 481d9cf29e
2 changed files with 9 additions and 9 deletions

View File

@@ -122,8 +122,8 @@ class CarController(CarControllerBase):
# LFA and HDA icons # LFA and HDA icons
if self.frame % 5 == 0 and (not hda2 or hda2_long): if self.frame % 5 == 0 and (not hda2 or hda2_long):
# CLEARPILOT TEST self.CS.lkas_enabled # CLEARPILOT TEST self.CS.lkas_enabled
# can_sends.append(hyundaicanfd.create_lfahda_cluster(self.packer, self.CAN, CC.enabled, CC.latActive)) can_sends.append(hyundaicanfd.create_lfahda_cluster(self.packer, self.CAN, CC.enabled, CC.latActive))
can_sends.append(hyundaicanfd.create_lfahda_cluster(self.packer, self.CAN, CS.lkas_enabled, CS.lkas_enabled)) # can_sends.append(hyundaicanfd.create_lfahda_cluster(self.packer, self.CAN, CS.lkas_enabled, CS.lkas_enabled))
# blinkers # blinkers
if hda2 and self.CP.flags & HyundaiFlags.ENABLE_BLINKERS: if hda2 and self.CP.flags & HyundaiFlags.ENABLE_BLINKERS:
@@ -139,9 +139,9 @@ class CarController(CarControllerBase):
else: else:
# Clearpilot # Clearpilot
# If cruise control was enabled or idle on start, force cancel # If cruise control was enabled or idle on start, force cancel
if CS.fix_main_enabled_cancel_main: # if CS.fix_main_enabled_cancel_main:
CS.fix_main_enabled_cancel_main = False # CS.fix_main_enabled_cancel_main = False
CC.cruiseControl.cancel = True # CC.cruiseControl.cancel = True
# button presses # button presses
can_sends.extend(self.create_button_messages(CC, CS, use_clu11=False)) can_sends.extend(self.create_button_messages(CC, CS, use_clu11=False))
else: else:

View File

@@ -58,7 +58,7 @@ class CarState(CarStateBase):
# FrogPilot variables # FrogPilot variables
self.main_enabled = False self.main_enabled = False
# Clearpilot variables # Clearpilot variables dev
self.fix_main_enabled_check = True self.fix_main_enabled_check = True
self.fix_main_enabled_executed = False self.fix_main_enabled_executed = False
self.fix_main_enabled_cancel_main = False self.fix_main_enabled_cancel_main = False
@@ -305,9 +305,9 @@ class CarState(CarStateBase):
self.lkas_enabled = lkas_enabled self.lkas_enabled = lkas_enabled
if self.lkas_enabled and not self.lkas_previously_enabled: # if self.lkas_enabled and not self.lkas_previously_enabled:
self.fix_main_enabled_cancel_main = True # self.fix_main_enabled_cancel_main = True
self.lkas_was_pressed = True # self.lkas_was_pressed = True
# print('Hello World', file=sys.stderr) # print('Hello World', file=sys.stderr)
# sys.stderr.write(str({k: v for k, v in vars(ret).items() if isinstance(v, (int, float, str, bool))}) + '\n') # sys.stderr.write(str({k: v for k, v in vars(ret).items() if isinstance(v, (int, float, str, bool))}) + '\n')