Browse Source

USB MIDI - don't hog transmit buffers

teensy4-core
PaulStoffregen 6 years ago
parent
commit
87f6186546
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      teensy3/usb_midi.c

+ 2
- 2
teensy3/usb_midi.c View File

} else { } else {
tx_packet->len = MIDI_TX_SIZE; tx_packet->len = MIDI_TX_SIZE;
usb_tx(MIDI_TX_ENDPOINT, tx_packet); usb_tx(MIDI_TX_ENDPOINT, tx_packet);
tx_packet = usb_malloc();
tx_packet = NULL;
} }
tx_noautoflush = 0; tx_noautoflush = 0;
} }
if (tx_noautoflush == 0 && tx_packet && tx_packet->index > 0) { if (tx_noautoflush == 0 && tx_packet && tx_packet->index > 0) {
tx_packet->len = tx_packet->index * 4; tx_packet->len = tx_packet->index * 4;
usb_tx(MIDI_TX_ENDPOINT, tx_packet); usb_tx(MIDI_TX_ENDPOINT, tx_packet);
tx_packet = usb_malloc();
tx_packet = NULL;
} }
} }



Loading…
Cancel
Save