S32K3 FLASH DRIVER

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

S32K3 FLASH DRIVER

2,620 Views
PINKMAN
Contributor III

HELLO EXPERT:

Is there any example of how to make a flash driver for the S32K3 chip? Currently, our practice is to allocate a piece of RAM to store the flash driver, and when it needs to be erased or written, use a function pointer to point to this RAM address to execute it. However, these modifications are implemented in C40IP.C, and when the code is regenerated, all the modifications will not be retained.    In fact, the so-called flash driver in my opinion is C40_Ip_pFlashBaseAddress->MCR |= FLASH_MCR_EHV_MASK;

0 Kudos
Reply
4 Replies

2,596 Views
Senlent
NXP TechSupport
NXP TechSupport

Hi@PINKMAN

I have described it in detail in the comments of this document.

https://community.nxp.com/t5/S32K-Knowledge-Base/Unified-bootloader-Demo/ta-p/1423099

Also, more detail regarding making flash driver for S32K1, which is simiar to all MCU.

https://community.nxp.com/t5/S32K-Knowledge-Base/S32K-How-to-make-Flash-Driver-image/ta-p/1630873

Please note that we have limtied support for this, this is just for reference only.

0 Kudos
Reply

2,541 Views
PINKMAN
Contributor III

I carefully studied the demo you provided, and I realized that you didn't use the FEE and MemAcc modules, you used the C40IP directly.

in fact, we need to use the EEPROM for our boot.


My question is, before the flash driver is downloaded into RAM, if the DFLASH has overflowed and SWAP is needed, how should I deal with this situation when I need to erase the DFLASH, but there is no driver?

0 Kudos
Reply

2,515 Views
Senlent
NXP TechSupport
NXP TechSupport

Hi@PINKMAN

My question is, before the flash driver is downloaded into RAM, if the DFLASH has overflowed and SWAP is needed, how should I deal with this situation when I need to erase the DFLASH, but there is no driver?

If all operations in your program depend on the flash driver, but your flash driver is not stored in RAM, it will certainly not be able to perform any flash operations.

This problem itself is problematic.

 

 

0 Kudos
Reply

2,582 Views
PINKMAN
Contributor III

THANKS

Tags (1)
0 Kudos
Reply