\r
/* Finalize the stream transfer to send the last packet */\r
Endpoint_ClearCurrentBank();\r
+\r
+ /* Wait until the endpoint is ready for another packet */\r
+ while (!(Endpoint_ReadWriteAllowed()));\r
+ \r
+ /* Send an empty packet to ensure that the host does not buffer data sent to it */\r
+ Endpoint_ClearCurrentBank();\r
}\r
\r
/* Select the Serial Rx Endpoint */\r