nrf/drivers/usb: Fix reading of a single USB CDC character.
This commit is contained in:
parent
be6f0f3b3b
commit
cca2305211
|
@ -126,9 +126,7 @@ static void cdc_task(bool tx)
|
||||||
if ( tud_cdc_connected() ) {
|
if ( tud_cdc_connected() ) {
|
||||||
// connected and there are data available
|
// connected and there are data available
|
||||||
while (tud_cdc_available()) {
|
while (tud_cdc_available()) {
|
||||||
int c;
|
int c = tud_cdc_read_char();
|
||||||
uint32_t count = tud_cdc_read(&c, 1);
|
|
||||||
(void)count;
|
|
||||||
if (c == mp_interrupt_char) {
|
if (c == mp_interrupt_char) {
|
||||||
rx_ringbuf.iget = 0;
|
rx_ringbuf.iget = 0;
|
||||||
rx_ringbuf.iput = 0;
|
rx_ringbuf.iput = 0;
|
||||||
|
|
Loading…
Reference in New Issue