Browse Source

Merge pull request #81 from jbliesener/master

Fix packet stuffing in usb_flightsim_flush_callback
teensy4-core
Paul Stoffregen 9 years ago
parent
commit
474f2823bd
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      teensy3/usb_flightsim.cpp

+ 1
- 1
teensy3/usb_flightsim.cpp View File

void usb_flightsim_flush_callback(void) void usb_flightsim_flush_callback(void)
{ {
if (tx_noautoflush || !tx_packet || tx_packet->index == 0) return; if (tx_noautoflush || !tx_packet || tx_packet->index == 0) return;
for (int i=tx_packet->index; i < FLIGHTSIM_TX_ENDPOINT; i++) {
for (int i=tx_packet->index; i < FLIGHTSIM_TX_SIZE; i++) {
tx_packet->buf[i] = 0; tx_packet->buf[i] = 0;
} }
tx_packet->len = FLIGHTSIM_TX_SIZE; tx_packet->len = FLIGHTSIM_TX_SIZE;

Loading…
Cancel
Save