From e19db6a5eb315ce3d42ad9b5ecada7b52a7ccd8f Mon Sep 17 00:00:00 2001 From: Shane Smiskol Date: Fri, 16 Aug 2024 00:58:53 -0700 Subject: [PATCH] ecu_addrs.py: fix function argument typing old-commit-hash: a255b8043aa26c569e947e5e44e8f1dab29d45a5 --- selfdrive/car/ecu_addrs.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/selfdrive/car/ecu_addrs.py b/selfdrive/car/ecu_addrs.py index 064b3e9258..6eba864c46 100644 --- a/selfdrive/car/ecu_addrs.py +++ b/selfdrive/car/ecu_addrs.py @@ -1,13 +1,12 @@ -import capnp import time from panda.python.uds import SERVICE_TYPE from openpilot.selfdrive.car import make_tester_present_msg, carlog -from openpilot.selfdrive.car.can_definitions import CanRecvCallable, CanSendCallable +from openpilot.selfdrive.car.can_definitions import CanData, CanRecvCallable, CanSendCallable from openpilot.selfdrive.car.fw_query_definitions import EcuAddrBusType -def _is_tester_present_response(msg: capnp.lib.capnp._DynamicStructReader, subaddr: int = None) -> bool: +def _is_tester_present_response(msg: CanData, subaddr: int = None) -> bool: # ISO-TP messages are always padded to 8 bytes # tester present response is always a single frame dat_offset = 1 if subaddr is not None else 0