projects
/
pub
/
USBasp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Minor cleanups to DualCDC ClassDriver device demo for clarity.
[pub/USBasp.git]
/
Demos
/
Device
/
ClassDriver
/
CDC
/
CDC.c
diff --git
a/Demos/Device/ClassDriver/CDC/CDC.c
b/Demos/Device/ClassDriver/CDC/CDC.c
index
836a6e0
..
1bcb464
100644
(file)
--- a/
Demos/Device/ClassDriver/CDC/CDC.c
+++ b/
Demos/Device/ClassDriver/CDC/CDC.c
@@
-92,6
+92,7
@@
int main(void)
{
\r
CheckJoystickMovement();
\r
\r
{
\r
CheckJoystickMovement();
\r
\r
+ /* Must throw away unused bytes from the host, or it will lock up while waiting for the device */
\r
while (CDC_Device_BytesReceived(&VirtualSerial_CDC_Interface))
\r
CDC_Device_ReceiveByte(&VirtualSerial_CDC_Interface);
\r
\r
while (CDC_Device_BytesReceived(&VirtualSerial_CDC_Interface))
\r
CDC_Device_ReceiveByte(&VirtualSerial_CDC_Interface);
\r
\r