diff --git a/opendbc b/opendbc index 8f245e6ef5..7bd94e3ff4 160000 --- a/opendbc +++ b/opendbc @@ -1 +1 @@ -Subproject commit 8f245e6ef5e25814d8e6e1f096221f6dfeefe86b +Subproject commit 7bd94e3ff4a2890eb69118f0dfadb64f9d32d618 diff --git a/panda b/panda index 54f9390ff5..fcb1a5a8e2 160000 --- a/panda +++ b/panda @@ -1 +1 @@ -Subproject commit 54f9390ff51b4fb0c2b3a81b9cde8727acdd1977 +Subproject commit fcb1a5a8e233a8b520c42c58cf8bfaa82753ac5a diff --git a/selfdrive/car/hyundai/carstate.py b/selfdrive/car/hyundai/carstate.py index 60d434a603..e27432e23b 100644 --- a/selfdrive/car/hyundai/carstate.py +++ b/selfdrive/car/hyundai/carstate.py @@ -159,7 +159,7 @@ class CarState(CarStateBase): elif self.CP.carFingerprint in HYBRID_CAR: ret.gas = cp.vl["ACCELERATOR_ALT"]["ACCELERATOR_PEDAL"] / 1023. ret.gasPressed = ret.gas > 1e-5 - ret.brakePressed = cp.vl["BRAKE"]["BRAKE_PRESSED"] == 1 + ret.brakePressed = cp.vl["TCS"]["DriverBraking"] == 1 ret.doorOpen = cp.vl["DOORS_SEATBELTS"]["DRIVER_DOOR_OPEN"] == 1 ret.seatbeltUnlatched = cp.vl["DOORS_SEATBELTS"]["DRIVER_SEATBELT_LATCHED"] == 0 @@ -415,7 +415,6 @@ class CarState(CarStateBase): ("WHEEL_SPEED_4", "WHEEL_SPEEDS"), ("GEAR", "GEAR_SHIFTER"), - ("BRAKE_PRESSED", "BRAKE"), ("STEERING_RATE", "STEERING_SENSORS"), ("STEERING_ANGLE", "STEERING_SENSORS"), @@ -423,7 +422,8 @@ class CarState(CarStateBase): ("STEERING_OUT_TORQUE", "MDPS"), ("LKA_FAULT", "MDPS"), - ("CRUISE_ACTIVE", "SCC1"), + ("DriverBraking", "TCS"), + ("COUNTER", cruise_btn_msg), ("CRUISE_BUTTONS", cruise_btn_msg), ("ADAPTIVE_CRUISE_MAIN_BTN", cruise_btn_msg), @@ -443,7 +443,7 @@ class CarState(CarStateBase): ("BRAKE", 100), ("STEERING_SENSORS", 100), ("MDPS", 100), - ("SCC1", 50), + ("TCS", 50), (cruise_btn_msg, 50), ("CLUSTER_INFO", 4), ("BLINKERS", 4), diff --git a/selfdrive/debug/can_print_changes.py b/selfdrive/debug/can_print_changes.py index b883fbc23f..ff98c20e60 100755 --- a/selfdrive/debug/can_print_changes.py +++ b/selfdrive/debug/can_print_changes.py @@ -54,6 +54,7 @@ def can_printer(bus=0, init_msgs=None, new_msgs=None, table=False): update(new_msgs, bus, dat, low_to_high, high_to_low) else: # Live mode + print(f"Waiting for messages on bus {bus}") try: while 1: can_recv = messaging.drain_sock(logcan) @@ -89,14 +90,17 @@ if __name__ == "__main__": formatter_class=argparse.ArgumentDefaultsHelpFormatter) parser.add_argument("--bus", type=int, help="CAN bus to print out", default=0) parser.add_argument("--table", action="store_true", help="Print a cabana-like table") - parser.add_argument("init", type=str, nargs='?', help="Route or segment to initialize with") + parser.add_argument("init", type=str, nargs='?', help="Route or segment to initialize with. Use empty quotes to compare against all zeros.") parser.add_argument("comp", type=str, nargs='?', help="Route or segment to compare against init") args = parser.parse_args() init_lr, new_lr = None, None if args.init: - init_lr = logreader_from_route_or_segment(args.init) + if args.init == '': + init_lr = [] + else: + init_lr = logreader_from_route_or_segment(args.init) if args.comp: new_lr = logreader_from_route_or_segment(args.comp)