2023-07-04 05:27 AM - edited 2023-07-05 01:20 AM
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!
2023-07-04 10:16 AM
Which STM32?
What toolchain?
JW
2023-07-05 01:18 AM
Thanks for your response!
I've edited my post and added the missing information.
2023-07-05 06:49 AM
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)