Description
Bug description
I was testing out the experimental DMA TX stream buf from @Dominaezzz (I originally found this in a discussion). I have esp32-s3 and a lcd driven by st7701s (datasheet). The screen has a parallel RGB (DPI) with 3-wire SPI interface. The example in the code works well and I do get the expected pure red and blue flashing screen. But whenever I add some time-consuming logic (initialize and update slint, for example) between start of transmission and subsequent data push, the screen turned dark.
I created a MRE repo, however it is just for showcasing the code more easily and I don't expect anyone to happen to have the exact same hardware. After some digging, I found all subsequent pushes was eventually early-returned by following code that was supposed to reclaim buffer from DMA:
That's how I come to the conclusion that DMA hangs, since auto write back is turned on but the descriptor was never given back to CPU and no bytes was written to the screen after the delay.
To Reproduce
- Run
cargo run --release
- The screen should turn red and blue normally
- Uncomment
src/main.rs:159
, which delays 10ms before the main loop starts - DMA hangs and nothing got transmitted to the screen
Expected behavior
The descriptor should have owner bit set to CPU and data should be transmitted to LCD_CAM normally.
Environment
- Target device: esp32s3 (revision v0.2)
- Crate name and version: esp-hal 1.0.0-beta.0
Metadata
Metadata
Assignees
Type
Projects
Status