Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

K64F UART Asynch API: Fix synchronization issue #3558

Merged
merged 1 commit into from
Jan 13, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -518,9 +518,10 @@ int serial_tx_asynch(serial_t *obj, const void *tx, size_t tx_length, uint8_t tx
}
}

obj->serial.txstate = kUART_TxBusy;

/* Start the transfer */
serial_send_asynch(obj);
obj->serial.txstate = kUART_TxBusy;

return 0;
}
Expand Down Expand Up @@ -583,9 +584,10 @@ void serial_rx_asynch(serial_t *obj, void *rx, size_t rx_length, uint8_t rx_widt
}
}

obj->serial.rxstate = kUART_RxBusy;

/* Start the transfer */
serial_receive_asynch(obj);
obj->serial.rxstate = kUART_RxBusy;
}

uint8_t serial_tx_active(serial_t *obj)
Expand Down