s32k312 erase flash

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

s32k312 erase flash

2,967 Views
fengba_360
Contributor III

Hello, I am developing a boot loader for the s32k312. During the update process, I want to erase the entire flash block using the s32k312 Mem_43_INFLS module. I have studied the official examples and have the following questions. For example, if I allocate an address space of 256kb for the APP, starting from the address 0x500000,

1.how can I erase this entire 256kb space at once using MEM_43_INFLS?

2.What is the byte alignment for the pflash on the s32312k?

3.What is the minimum writable size for the pflash on the s32k312?

微信图片_20241118090347.png

0 Kudos
Reply
5 Replies

2,931 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hello @fengba_360,

 

1. The HW Flash controller can erase either one sector (8KB) or one block (1000KB, in this case). To erase 256KB, use the Mem_43_InFls_Erase() with length equal to 256KB.

danielmartynek_0-1732028089382.png

2. 8 bytes

3. 8 bytes

 

Regards,

Daniel

0 Kudos
Reply

2,907 Views
fengba_360
Contributor III

"Thank you for your guidance. If I need to erase a flash memory of 256kb in size, do I need to make any additional configurations (for example, on the configuration interface where I upload settings)?"

0 Kudos
Reply

2,878 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @fengba_360,

Do you mean MemSectorBatch?

Refer to Autosar Specification of Memory Driver:

https://www.autosar.org/fileadmin/standards/R21-11/CP/AUTOSAR_SWS_MemoryDriver.pdf

And to the User Manual of the RTD driver:

RTD_MEM_43_INFLS_UM.pdf (in RTD installation directory)

 

BR, Daniel

0 Kudos
Reply

2,871 Views
fengba_360
Contributor III

Yes, the configuration of mem_43_infls Can you provide some guidance?

微信图片_20241125211936.png

0 Kudos
Reply

2,845 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @fengba_360,

Please refer to the documents I linked in my previous post,

 

Thank you

0 Kudos
Reply