diff options
Diffstat (limited to 'os/hal')
-rw-r--r-- | os/hal/src/serial_usb.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/os/hal/src/serial_usb.c b/os/hal/src/serial_usb.c index 9b36be413..9cef45524 100644 --- a/os/hal/src/serial_usb.c +++ b/os/hal/src/serial_usb.c @@ -260,6 +260,11 @@ void sduConfigureHookI(USBDriver *usbp) { chIQResetI(&sdup->iqueue);
chOQResetI(&sdup->oqueue);
chnAddFlagsI(sdup, CHN_CONNECTED);
+
+ /* Starts the first OUT transaction immediately.*/
+ usbPrepareQueuedReceive(usbp, USB_CDC_DATA_AVAILABLE_EP, &sdup->iqueue,
+ usbp->epc[USB_CDC_DATA_AVAILABLE_EP]->out_maxsize);
+ usbStartReceiveI(usbp, USB_CDC_DATA_AVAILABLE_EP);
}
/**
|