Skip to main content
Bli.11
Associate II
March 26, 2020
Question

What is the specific process of accessing SRAM fixed address under CUBEIDE?

Hi

Under the CUBEIDE tool, I'm doing an access to D2SRAM1~3 storage Spaces of H743I EVAL2.Use " uint8_t liku [] __attribute__ ((section (". ARM __at_0x30020000"))) = {' A ', 'B', 'C', 'D'};"Statement, but the data returned through UART1 does not match the actual data.

What is the specific process of accessing SRAM fixed address under CUBEIDE?

​ BzLi

​

This topic has been closed for replies.

3 replies

TDK
March 26, 2020

I'm not sure if "__attribute__ ((section (". ARM __at_0x30020000")))" works or not.

But to access a specific memory address, the syntax is very simple:

uint8_t * ptr = (uint8_t *) 0x30020000;

You could use that to check if the linker did what you asked it to do.

"If you feel a post has answered your question, please click ""Accept as Solution""."
berendi
Principal
March 26, 2020

The simple syntax is working only for synchronous transfers, neither for DMA nor interrupt based ones.

For interrupt or DMA based transfers, the declaration must be volatile.

DMA transfers need some cache management too.