Searched refs:tx_idx (Results 1 – 4 of 4) sorted by relevance
/Zephyr-latest/samples/drivers/i2s/output/src/ |
D | main.c | 64 uint32_t tx_idx; in main() local 89 for (tx_idx = 0; tx_idx < NUM_BLOCKS; tx_idx++) { in main() 90 ret = k_mem_slab_alloc(&tx_0_mem_slab, &tx_block[tx_idx], in main() 96 fill_buf((uint16_t *)tx_block[tx_idx], tx_idx % 3); in main() 99 tx_idx = 0; in main() 101 ret = i2s_write(dev_i2s, tx_block[tx_idx++], BLOCK_SIZE); in main() 103 printf("Could not write TX buffer %d\n", tx_idx); in main() 113 for (; tx_idx < NUM_BLOCKS; ) { in main() 114 ret = i2s_write(dev_i2s, tx_block[tx_idx++], BLOCK_SIZE); in main() 116 printf("Could not write TX buffer %d\n", tx_idx); in main()
|
/Zephyr-latest/tests/drivers/i2s/i2s_speed/src/ |
D | test_i2s_speed.c | 280 int tx_idx; in ZTEST() local 286 for (tx_idx = 0; tx_idx < NUM_BLOCKS; tx_idx++) { in ZTEST() 287 ret = k_mem_slab_alloc(&tx_0_mem_slab, &tx_block[tx_idx], in ZTEST() 290 fill_buf((uint16_t *)tx_block[tx_idx], tx_idx % 3); in ZTEST() 293 tx_idx = 0; in ZTEST() 296 ret = i2s_write(dev_i2s_tx, tx_block[tx_idx++], BLOCK_SIZE); in ZTEST() 299 ret = i2s_write(dev_i2s_tx, tx_block[tx_idx++], BLOCK_SIZE); in ZTEST() 310 for (; tx_idx < NUM_BLOCKS; ) { in ZTEST() 311 ret = i2s_write(dev_i2s_tx, tx_block[tx_idx++], BLOCK_SIZE); in ZTEST() 335 TC_PRINT("%d TX blocks sent\n", tx_idx); in ZTEST() [all …]
|
/Zephyr-latest/drivers/can/ |
D | can_mcp2515.c | 289 static void mcp2515_tx_done(const struct device *dev, uint8_t tx_idx, int status) in mcp2515_tx_done() argument 292 can_tx_callback_t callback = dev_data->tx_cb[tx_idx].cb; in mcp2515_tx_done() 295 callback(dev, status, dev_data->tx_cb[tx_idx].cb_arg); in mcp2515_tx_done() 296 dev_data->tx_cb[tx_idx].cb = NULL; in mcp2515_tx_done() 299 dev_data->tx_busy_map &= ~BIT(tx_idx); in mcp2515_tx_done() 534 uint8_t tx_idx = 0U; in mcp2515_send() local 562 for (; tx_idx < MCP2515_TX_CNT; tx_idx++) { in mcp2515_send() 563 if ((BIT(tx_idx) & dev_data->tx_busy_map) == 0) { in mcp2515_send() 564 dev_data->tx_busy_map |= BIT(tx_idx); in mcp2515_send() 571 if (tx_idx == MCP2515_TX_CNT) { in mcp2515_send() [all …]
|
D | can_mcan.c | 335 uint32_t tx_idx; in can_mcan_stop() local 361 for (tx_idx = 0U; tx_idx < cbs->num_tx; tx_idx++) { in can_mcan_stop() 362 tx_cb = cbs->tx[tx_idx].function; in can_mcan_stop() 365 cbs->tx[tx_idx].function = NULL; in can_mcan_stop() 366 tx_cb(dev, -ENETDOWN, cbs->tx[tx_idx].user_data); in can_mcan_stop() 460 uint32_t tx_idx; in can_mcan_state_change_handler() local 483 for (tx_idx = 0U; tx_idx < cbs->num_tx; tx_idx++) { in can_mcan_state_change_handler() 484 tx_cb = cbs->tx[tx_idx].function; in can_mcan_state_change_handler() 487 cbs->tx[tx_idx].function = NULL; in can_mcan_state_change_handler() 488 tx_cb(dev, -ENETUNREACH, cbs->tx[tx_idx].user_data); in can_mcan_state_change_handler() [all …]
|