mirror of
https://github.com/MoreTore/openpilot.git
synced 2026-08-05 08:16:06 +08:00
IsoTpParallelQuery: extend timeout for each ISO-TP frame (#25897)
* raise timeouts * extend timeout for each message/frame (not multi-frame full response) * bump panda * 100 ms timeout between frames (max I've seen is 20, should be good) * bump panda * remove unused * Add tester present to HKG queries (temp) * send tester present to all ecus first * vin and fw_versions.py sleep, should figure out why sendcan drops packets * None is wildcard (some ecus respond with negative code, that's fine) * typing * try bus 0 * revert brand-specific changes * Update selfdrive/car/isotp_parallel_query.py
This commit is contained in:
+1
-1
Submodule panda updated: 10c0991666...5984fd3509
@@ -1,7 +1,6 @@
|
||||
import time
|
||||
from collections import defaultdict
|
||||
from functools import partial
|
||||
from typing import Optional
|
||||
|
||||
import cereal.messaging as messaging
|
||||
from system.swaglog import cloudlog
|
||||
@@ -107,12 +106,15 @@ class IsoTpParallelQuery:
|
||||
|
||||
for tx_addr, msg in msgs.items():
|
||||
try:
|
||||
dat: Optional[bytes] = msg.recv()
|
||||
dat, updated = msg.recv()
|
||||
except Exception:
|
||||
cloudlog.exception(f"Error processing UDS response: {tx_addr}")
|
||||
request_done[tx_addr] = True
|
||||
continue
|
||||
|
||||
if updated:
|
||||
response_timeouts[tx_addr] = time.monotonic() + timeout
|
||||
|
||||
if not dat:
|
||||
continue
|
||||
|
||||
@@ -121,7 +123,6 @@ class IsoTpParallelQuery:
|
||||
response_valid = dat[:len(expected_response)] == expected_response
|
||||
|
||||
if response_valid:
|
||||
response_timeouts[tx_addr] = time.monotonic() + timeout
|
||||
if counter + 1 < len(self.request):
|
||||
msg.send(self.request[counter + 1])
|
||||
request_counter[tx_addr] += 1
|
||||
|
||||
Reference in New Issue
Block a user