diff --git a/pybricksdev/connections/ev3.py b/pybricksdev/connections/ev3.py index 9c4e2ac..a8e899f 100644 --- a/pybricksdev/connections/ev3.py +++ b/pybricksdev/connections/ev3.py @@ -84,10 +84,17 @@ def _send_command(self, command: Command, payload: bytes | None = None) -> int: length += len(payload) + # report_id is not used by the EV3 but is required by HIDAPI on Windows. + # It does no harm on Linux, so we include it unconditionally. Note that + # the report ID is automatically stripped from incoming messages by + # HIDAPI on all platforms. + report_id = 0 + message_number = next(self._msg_count) message = struct.pack( - "