Code downloaded to LPC4370flash is copied to run on SRAM

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Code downloaded to LPC4370flash is copied to run on SRAM

507件の閲覧回数
ALOONG
Contributor I

I now find a problem, I use LPC4370 MCU HSADC+DMA, in the simulation code, the code is running on SRAM(0x10000000), at this time my HSADC speed can really reach 80MHZ, But if I download the program to flash(0x14000000) without emulation, HSADC speed is only about 60MHZ, I look for the relevant information, the code running on ROM and RAM running code rate is indeed there is a difference, RAM running code faster. Now want to copy the code on the ROM to run on RAM, tried a lot of methods are not successful, have friends do similar things, hope to get your help, thank you first here!

ラベル(1)
0 件の賞賛
返信
2 返答(返信)

488件の閲覧回数
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @ALOONG 

The issue you're encountering is quite common when dealing with high-speed peripherals like the HSADC on microcontrollers. The difference in performance between running code from SRAM and Flash is due to the access times and the memory architecture. Flash memory typically has higher latency compared to SRAM, which can result in slower execution speeds.

In MCUXpresso IDE, to copy and execute code from SRAM, try the following configuration

ram.jpg

 

BR

Alice 

 

0 件の賞賛
返信

449件の閲覧回数
ALOONG
Contributor I

Thank you brother Alice_Yang, I am trying to use MCUXpresso IDE, previously I used IAR.

0 件の賞賛
返信