ESP32-S3 GDMA descriptor error

Baldhead
Posts: 471
Joined: Sun Mar 31, 2019 5:16 am

ESP32-S3 GDMA descriptor error

Postby Baldhead » Thu Dec 16, 2021 11:11 pm

Hi,

I am trying to use gdma in esp32-S3 chip.

I configured the gdma output channel 0.
I enabled the interrupt "out_dscr_err", and that interrupt is being called.

I am allocating the dma descriptor and buffer dynamically ( maybe that's the problem ? ).

Code: Select all

    dma_desc_buf_a = (dma_descriptor_t*) heap_caps_calloc( descriptor_size, sizeof(dma_descriptor_t), MALLOC_CAP_8BIT | MALLOC_CAP_DMA | MALLOC_CAP_INTERNAL );
    p_buffer_a = (uint16_t*) heap_caps_malloc( 19200 * sizeof(uint16_t), MALLOC_CAP_8BIT | MALLOC_CAP_DMA | MALLOC_CAP_INTERNAL );
edit:
I tested it with static allocation and same problem.

Code: Select all

    static DMA_ATTR dma_descriptor_t dma_desc_a[descriptor_size];                          
    dma_desc_buf_a = &dma_desc_a[0];
    
    static DMA_ATTR uint16_t buffer_a[pixels_size];                          
    p_buffer_a = &buffer_a[0];
What are the possible causes of GDMA out descriptor error ?

Thank's.

ESP_Sprite
Posts: 9770
Joined: Thu Nov 26, 2015 4:08 am

Re: ESP32-S3 GDMA descriptor error

Postby ESP_Sprite » Fri Dec 17, 2021 4:55 am

Both should work. Can you post more code, e.g. how you fill in the descriptors?

User avatar
ESP_krzychb
Posts: 400
Joined: Sat Oct 01, 2016 9:05 am
Contact:

Re: ESP32-S3 GDMA descriptor error

Postby ESP_krzychb » Fri Dec 17, 2021 5:58 am

Another tip is to check "2.4.6 Linked List Reading Process" in https://www.espressif.com/sites/default ... ual_en.pdf for a description of what kind of errors trigger this interrupt.

Baldhead
Posts: 471
Joined: Sun Mar 31, 2019 5:16 am

Re: ESP32-S3 GDMA descriptor error

Postby Baldhead » Fri Dec 17, 2021 11:45 pm

Sorry,

I was measuring gpio 20 (always 1, usb D+ signal) instead of gpio 13 in ESP32-S3-DevKitC-1.

I tested it and dma is not firing LCD_CAM peripheral io and gdma interrupt is not being called(none of the avaiable interrupts, i enabled all to test).

So i assume that descriptor are ok.
I'm using the same approach i used in esp32 to fill the descriptors.

Some suggestion why dma are not firing ?
Any very specific configuration on LCD_CAM peripheral or GDMA peripheral ?

Thank's.

Who is online

Users browsing this forum: No registered users and 31 guests