We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c99ab12 commit 817d700Copy full SHA for 817d700
hardware/arduino/avr/cores/arduino/USBCore.cpp
@@ -255,7 +255,9 @@ u8 USB_SendSpace(u8 ep)
255
LockEP lock(ep);
256
if (!ReadWriteAllowed())
257
return 0;
258
- return USB_EP_SIZE - FifoByteCount();
+ // subtract 1 from the EP size to never send a full packet,
259
+ // this avoids dealing with ZLP's in USB_Send
260
+ return USB_EP_SIZE - 1 - FifoByteCount();
261
}
262
263
// Blocking Send of data to an endpoint
0 commit comments