meminfls_mainfunction causes the hardfault

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

meminfls_mainfunction causes the hardfault

跳至解决方案
868 次查看
qimao-marvin
Contributor II

RTD:3.0.0 P07

AR:9.30.1

EB:29.0

as the function described below,when uses the iar to download and debug,it will cause hardfault;but if i try tu debug with hal_dataflash_write,everything works well.

can any one give me some advices?

Thanks

qimaomarvin_1-1749042902713.png

 

qimaomarvin_0-1749042792028.png

qimaomarvin_2-1749043011466.png

 

0 项奖励
回复
1 解答
831 次查看
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @qimao-marvin,

Hard to say just from the description, but the driver must not be in the programmed flash block.

I see you program block_0 at 0x400000 where the application typically is.

The Mem_43_INFSL driver can use SRAM (below S32DS IDE configurator).

danielmartynek_0-1749196896211.png

 

Regards,

Daniel

 

 

在原帖中查看解决方案

0 项奖励
回复
2 回复数
832 次查看
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @qimao-marvin,

Hard to say just from the description, but the driver must not be in the programmed flash block.

I see you program block_0 at 0x400000 where the application typically is.

The Mem_43_INFSL driver can use SRAM (below S32DS IDE configurator).

danielmartynek_0-1749196896211.png

 

Regards,

Daniel

 

 

0 项奖励
回复
769 次查看
qimao-marvin
Contributor II

Because the address i try to erase and prohran in at the bank of the functiob, the 0x400000 - 0x500000 is the one bank, but even i put the code in the ram ,it caused the hardfault too,however ,if i erase at the 0x500000,the function runs well.

So why even the code runs in sram,it will cause hardfault when tried to program at 0x400000?

0 项奖励
回复