Add tx callback to cdc device

Useful for continuous transmission of data, which is difficult currently
because there is no notification of tx completion.
This commit is contained in:
Gavin Li
2020-06-18 01:13:44 -07:00
parent 2b27eed01a
commit 8fe887198b
2 changed files with 6 additions and 0 deletions

View File

@@ -128,6 +128,9 @@ TU_ATTR_WEAK void tud_cdc_rx_cb(uint8_t itf);
// Invoked when received `wanted_char`
TU_ATTR_WEAK void tud_cdc_rx_wanted_cb(uint8_t itf, char wanted_char);
// Invoked when space becomes available in TX buffer
TU_ATTR_WEAK void tud_cdc_tx_cb(uint8_t itf);
// Invoked when line state DTR & RTS are changed via SET_CONTROL_LINE_STATE
TU_ATTR_WEAK void tud_cdc_line_state_cb(uint8_t itf, bool dtr, bool rts);