2020-11-15 04:01 PM
I have a problem with the sdcard, so I was looking for the community and they said I can change the DMA's DTCM variable, so I'm trying to insert the code, but I'm wondering how to change the IAR code in CUBEIDE and where to put it.
This is the code.
And I think we can put it in RAM.id, so I wrote it down first, but I don't know if it's right.
I don't know much because I just started STM.
But I really want to solve the problem of Sdcard!
Thank you.
2020-11-15 04:54 PM
No, you can't just stuff that in like that.
You'd want to add a DTCMRAM section, like the RAM one, and move the RAM one to 0x20020000 and shrink it's size
You'd then create SECTIONS for the DTCMRAM, and direct content in there.
If it is initialized, rather than NOLOAD, then you'd need to add code to startup.s to copy content.
Probably want to use __attribute__ on the C side to direct or name section to use.