diff --git a/selfdrive/car/isotp_parallel_query.py b/selfdrive/car/isotp_parallel_query.py index 2fc0f1752f..5d7d41fb08 100644 --- a/selfdrive/car/isotp_parallel_query.py +++ b/selfdrive/car/isotp_parallel_query.py @@ -72,7 +72,7 @@ class IsoTpParallelQuery: messaging.drain_sock(self.logcan) self.msg_buffer = defaultdict(list) - def get_data(self, timeout): + def get_data(self, timeout, total_timeout=60.): self._drain_rx() # Create message objects @@ -146,4 +146,8 @@ class IsoTpParallelQuery: cloudlog.warning(f"iso-tp query timeout after receiving response: {tx_addr}") break + if cur_time - start_time > total_timeout: + cloudlog.warning("iso-tp query timeout while receiving data") + break + return results