From ff158bd39f206291ffade3d69a8bde5fca7b0577 Mon Sep 17 00:00:00 2001 From: oystub Date: Wed, 18 Dec 2024 22:03:43 +0100 Subject: [PATCH] driver/python_can: use correct timeout for pyhon-can recv() python-can's recv function is supposed to take a timeout in seconds, or None, not in milliseconds or -1. --- dronecan/driver/python_can.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/dronecan/driver/python_can.py b/dronecan/driver/python_can.py index a457d73..d7be798 100644 --- a/dronecan/driver/python_can.py +++ b/dronecan/driver/python_can.py @@ -136,8 +136,6 @@ def close(self): def receive(self, timeout=None): self._check_write_feedback() - timeout = -1 if timeout is None else (timeout * 1000) - try: msg = self._bus.recv(timeout=timeout) if msg is not None: