From 978b321f80603a08ff1b61cfbfb11c3ef2c64906 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Tue, 2 Oct 2018 21:54:46 -0400 Subject: [PATCH] avr: Disable usb serial interrupts while processing data There's no need to keep taking interrupts if the high-level code is busy processing messages. Signed-off-by: Kevin O'Connor --- src/avr/usbserial.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/avr/usbserial.c b/src/avr/usbserial.c index 6ee60841..7405e534 100644 --- a/src/avr/usbserial.c +++ b/src/avr/usbserial.c @@ -48,12 +48,14 @@ int_fast8_t usb_read_bulk_out(void *data, uint_fast8_t max_len) { UENUM = USB_CDC_EP_BULK_OUT; - if (!(UEINTX & (1<