diff --git a/can/interfaces/pcan/pcan.py b/can/interfaces/pcan/pcan.py index 52dbb49b0..4f7be0e89 100644 --- a/can/interfaces/pcan/pcan.py +++ b/can/interfaces/pcan/pcan.py @@ -45,6 +45,7 @@ PCAN_ERROR_BUSLIGHT, PCAN_ERROR_OK, PCAN_ERROR_QRCVEMPTY, + PCAN_ERROR_ILLDATA, PCAN_FD_PARAMETER_LIST, PCAN_LANBUS1, PCAN_LISTEN_ONLY, @@ -555,6 +556,10 @@ def _recv_internal( elif result & (PCAN_ERROR_BUSLIGHT | PCAN_ERROR_BUSHEAVY): log.warning(self._get_formatted_error(result)) + elif result == PCAN_ERROR_ILLDATA: + # Ignore this + pass + else: raise PcanCanOperationError(self._get_formatted_error(result))