Skip to content

Commit

Permalink
missed a busTime (#1990)
Browse files Browse the repository at this point in the history
* whoops

* addr dat src
  • Loading branch information
sshane authored Jul 31, 2024
1 parent 8c3bb01 commit daa739e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/uds.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ def get_dtc_status_names(status):
return result

class CanClient():
def __init__(self, can_send: Callable[[int, bytes, int], None], can_recv: Callable[[], list[tuple[int, int, bytes, int]]],
def __init__(self, can_send: Callable[[int, bytes, int], None], can_recv: Callable[[], list[tuple[int, bytes, int]]],
tx_addr: int, rx_addr: int, bus: int, sub_addr: int | None = None, debug: bool = False):
self.tx = can_send
self.rx = can_recv
Expand Down Expand Up @@ -339,7 +339,7 @@ def _recv_buffer(self, drain: bool = False) -> None:
print(f"CAN-RX: drain - {len(msgs)}")
self.rx_buff.clear()
else:
for rx_addr, _, rx_data, rx_bus in msgs or []:
for rx_addr, rx_data, rx_bus in msgs or []:
if self._recv_filter(rx_bus, rx_addr) and len(rx_data) > 0:
rx_data = bytes(rx_data) # convert bytearray to bytes

Expand Down

0 comments on commit daa739e

Please sign in to comment.