diff --git a/canopen/sdo/client.py b/canopen/sdo/client.py index 17d6774e..a1437828 100644 --- a/canopen/sdo/client.py +++ b/canopen/sdo/client.py @@ -109,8 +109,9 @@ def read_response(self): async def aread_response(self): try: - response = await self.aresponses.get() - except queue.Empty: + response = await asyncio.wait_for( + self.aresponses.get(), timeout=self.RESPONSE_TIMEOUT) + except TimeoutError: raise SdoCommunicationError("No SDO response received") res_command, = struct.unpack_from("B", response) if res_command == RESPONSE_ABORTED: