We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a4576a5 commit 02afb3aCopy full SHA for 02afb3a
hardware/arduino/avr/cores/arduino/CDC.cpp
@@ -206,7 +206,7 @@ size_t Serial_::write(const uint8_t *buffer, size_t size)
206
// TODO - ZE - check behavior on different OSes and test what happens if an
207
// open connection isn't broken cleanly (cable is yanked out, host dies
208
// or locks up, or host virtual serial port hangs)
209
- if (_usbLineInfo.lineState > 0) {
+ if (USBDevice.configured()) {
210
int r = USB_Send(CDC_TX,buffer,size);
211
if (r > 0) {
212
return r;
0 commit comments