cancel
Showing results for 
Search instead for 
Did you mean: 

Receive into external RAM via DMCI

Florian Moser
Senior

uC: STM32H725AEI
Toolchain / IDE: STM32CubeIDE
CubeMX version: 6.8.0
I'm using CubeMX for code generation with HAL drivers.

I'm currenty receiving a JPEG from a camera via DCMI with 640x480.
I'd like to step up the game to 1280x960, but the picture would not fit in my internal RAM.
Luckily I'm using an external 8MB RAM (via FMC) for this project, where 6MB are still emtpy.

Now my question is: How do i use DCMI with this external RAM?

I implemented location pragmas which are working with normal memory operations:

 

LOCATION_XRAM_PRAGMA
cam_jpegBuffer_t picture_jpegBuffer LOCATION_XRAM_ATTRIBUTE; // external RAM

cam_jpegBuffer_t picture_jpegBuffer; // internal RAM

 

The whole setup is working with the buffer in the internal RAM, but as soon as i move it to the external RAM it stops receiving data.
Since the function for receiving is called HAL_DCMI_Start_DMA i guess, that the problem could be the external RAM not beeing DMA capable.

1. Is there an option to make the external RAM DMA capable?
2. Is there an option to receive smaller pieces (not the full frame) in the internal RAM and collect them to a full frame in the external RAM?
3. Does someone have another idea to make this possible?

Thanks!

3 REPLIES 3

Which STM32?

What toolchain?

JW

Thanks for your response!
I've edited my post and added the missing information.

SofLit
ST Employee

Hello,

You didn't mention if you've already configured the FMC interface for the external memory! 

Did you already do that? If yes did you try to write and read back written data? (please disable the D-cache in this test)

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.