meminfls_mainfunction causes the hardfault

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

meminfls_mainfunction causes the hardfault

Jump to solution
590 Views
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 Kudos
Reply
1 Solution
553 Views
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

 

 

View solution in original post

0 Kudos
Reply
2 Replies
554 Views
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 Kudos
Reply
491 Views
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 Kudos
Reply