Start a SPI DMA transmission by GPIO trigger ? - ESP32-S3 Forum
Posted: Tue Dec 31, 2024 11:39 am
Dear espressif programmers,
I would like to trigger SPI DMA transmission by a GPIO - data ready DRDY falling edge from a SPI slave device. The DRDY is set by the SPI slave device every 1ms with 27 bytes of data ready to readout by the SPI master (ESP32-S3). The goal is to use DMA to automatically trigger SPI DMA transmittions in 27 bytes blocks to sequentially fill up two 1350 bytes ping-pong buffers and trigger an interrupt only when one of the ping-pong buffers is filled without the CPU interaction in each DRDY event.
1. Is it possible to directly connect a GPIO to trigger SPI DMA transmissions (e.g. by gpio_matrix_in) in ESP32-S3 ?
2. Or is it possible to use RMT module for this purpose instead ? Are there any disadvantages compared to direct GPIO-DMA connection ?
3. DMA-Controlled Configurable Segmented Transfer - is it possible to start transfer of individual segments using DMA RMT ?
4. Is there any other better solution ?
Thank you,
best regards,
Jan Kijonka
I would like to trigger SPI DMA transmission by a GPIO - data ready DRDY falling edge from a SPI slave device. The DRDY is set by the SPI slave device every 1ms with 27 bytes of data ready to readout by the SPI master (ESP32-S3). The goal is to use DMA to automatically trigger SPI DMA transmittions in 27 bytes blocks to sequentially fill up two 1350 bytes ping-pong buffers and trigger an interrupt only when one of the ping-pong buffers is filled without the CPU interaction in each DRDY event.
1. Is it possible to directly connect a GPIO to trigger SPI DMA transmissions (e.g. by gpio_matrix_in) in ESP32-S3 ?
2. Or is it possible to use RMT module for this purpose instead ? Are there any disadvantages compared to direct GPIO-DMA connection ?
3. DMA-Controlled Configurable Segmented Transfer - is it possible to start transfer of individual segments using DMA RMT ?
4. Is there any other better solution ?
Thank you,
best regards,
Jan Kijonka