replace hardcoded SPI DMA parameter
This commit is contained in:
parent
8cbbc299e9
commit
8d1fbcf5c4
|
@ -176,7 +176,7 @@ bool lvgl_spi_driver_init(int host,
|
||||||
|
|
||||||
ESP_LOGI(TAG, "Initializing SPI bus...");
|
ESP_LOGI(TAG, "Initializing SPI bus...");
|
||||||
#if defined (CONFIG_IDF_TARGET_ESP32C3)
|
#if defined (CONFIG_IDF_TARGET_ESP32C3)
|
||||||
dma_channel = 3;
|
dma_channel = SPI_DMA_CH_AUTO;
|
||||||
#endif
|
#endif
|
||||||
esp_err_t ret = spi_bus_initialize(host, &buscfg, (spi_dma_chan_t)dma_channel);
|
esp_err_t ret = spi_bus_initialize(host, &buscfg, (spi_dma_chan_t)dma_channel);
|
||||||
assert(ret == ESP_OK);
|
assert(ret == ESP_OK);
|
||||||
|
|
Loading…
Reference in a new issue