aboutsummaryrefslogtreecommitdiff
path: root/cores/arduino/USBCore.cpp
diff options
context:
space:
mode:
authorPaul Brook <paul@nowt.org>2014-03-21 18:43:19 +0000
committerCristian Maglie <c.maglie@bug.st>2014-05-24 00:34:56 +0200
commit5962f155f70a5c67d14280d1b178f5197fb00df4 (patch)
treee694f5cda26d5c3bb9b090c1b896020bcf3c43ff /cores/arduino/USBCore.cpp
parentb57b2ae3c163a855efca331bf817d566e328f88b (diff)
Improve CDC read code
Read CDC data from USB FIFO on demand instead of in ISR. Remove superfluous ring buffer. Signed-off-by: Paul Brook <paul@nowt.org>
Diffstat (limited to 'cores/arduino/USBCore.cpp')
-rw-r--r--cores/arduino/USBCore.cpp2
1 files changed, 0 insertions, 2 deletions
diff --git a/cores/arduino/USBCore.cpp b/cores/arduino/USBCore.cpp
index 76ceb01..f8123e5 100644
--- a/cores/arduino/USBCore.cpp
+++ b/cores/arduino/USBCore.cpp
@@ -614,8 +614,6 @@ ISR(USB_GEN_vect)
{
#ifdef CDC_ENABLED
USB_Flush(CDC_TX); // Send a tx frame if found
- if (USB_Available(CDC_RX)) // Handle received bytes (if any)
- Serial.accept();
#endif
// check whether the one-shot period has elapsed. if so, turn off the LED