MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / uart_input_dma

Function uart_input_dma

bsp/hc32/tests/test_uart_v2.c:103–117  ·  view source on GitHub ↗

DMA接收数据回调函数 */

Source from the content-addressed store, hash-verified

101
102/* DMA接收数据回调函数 */
103static rt_err_t uart_input_dma(rt_device_t dev, rt_size_t size)
104{
105 struct rx_msg msg;
106 rt_err_t result;
107 msg.dev = dev;
108 msg.size = size;
109
110 result = rt_mq_send(&rx_mq, &msg, sizeof(msg));
111 if (result == -RT_EFULL)
112 {
113 /* 消息队列满 */
114 rt_kprintf("message queue full!\n");
115 }
116 return result;
117}
118
119/* INT接收数据回调函数 */
120static rt_err_t uart_input_int(rt_device_t dev, rt_size_t size)

Callers

nothing calls this directly

Calls 2

rt_mq_sendFunction · 0.85
rt_kprintfFunction · 0.85

Tested by

no test coverage detected