mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-31 14:22:14 +00:00
rmt: Adds a simple handler that can be called when transmission ends.
Merges https://github.com/espressif/esp-idf/pull/1174
This commit is contained in:

committed by
Angus Gratton

parent
30aacb79d5
commit
1066c74b74
@@ -119,6 +119,8 @@ typedef struct {
|
||||
|
||||
typedef intr_handle_t rmt_isr_handle_t;
|
||||
|
||||
typedef void (*rmt_tx_end_t)(rmt_channel_t channel);
|
||||
|
||||
/**
|
||||
* @brief Set RMT clock divider, channel clock is divided from source clock.
|
||||
*
|
||||
@@ -702,6 +704,20 @@ esp_err_t rmt_wait_tx_done(rmt_channel_t channel, TickType_t wait_time);
|
||||
*/
|
||||
esp_err_t rmt_get_ringbuf_handle(rmt_channel_t channel, RingbufHandle_t* buf_handle);
|
||||
|
||||
/**
|
||||
* @brief Registers a callback that will be called when transmission ends.
|
||||
*
|
||||
* Called by rmt_driver_isr_default in interrupt context.
|
||||
*
|
||||
* @note Requires rmt_driver_install to install the default ISR handler.
|
||||
*
|
||||
* @param fn Function to be called from the default interrupt handler or NULL.
|
||||
*
|
||||
* @return the previous handler (or NULL if there was none)
|
||||
*/
|
||||
rmt_tx_end_t rmt_register_tx_end_callback(rmt_tx_end_t fn);
|
||||
|
||||
|
||||
/*
|
||||
* ----------------EXAMPLE OF RMT INTERRUPT ------------------
|
||||
* @code{c}
|
||||
|
Reference in New Issue
Block a user