How to do for FLASH、RAM check?

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

How to do for FLASH、RAM check?

363 Views
fengchaozhang
Contributor I

Hi,Team I'm using S912ZVML12/S912ZVML64 to do a safe related system,so I must do FLASH、RAM check during running to verify whether there are injured area of S912ZVML12/S912ZVML64 in the long term run.

What should I do in my codes? 

0 Kudos
3 Replies

338 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @fengchaozhang,

The MC9S12ZVM includes error correction code (ECC) on RAM and flash memory, EEPROM for diagnostic or data storage.

https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12Z-machine-exception-caused-by-ECC-issue-...

Please refer to the MC9S12ZVx Safety Manual for more information about functional safety.

It is available in S12ZVC Secure File under NDA:

https://www.nxp.com/products/processors-and-microcontrollers/additional-mpu-mcus-architectures/s12-m...

danielmartynek_0-1711460937626.png

 

Regards,

Daniel

 

0 Kudos

271 Views
fengchaozhang1
Contributor I

Hi, danielmartyne

Thank you for your reply.

I want to use the S912ZVML12 chip to do initialize perform a RAM check. The method for checking is
Firstly, write RAM to 0 and check if 0 is read out until all RAM is confirmed
Secondly, write RAM to 1 and check if 1 is read out until all RAM is confirmed
Thus completing the initialization check of RAM.

But I have 2 following questions: 
Question 1: I don't know how to write assembly code for writing and reading to RAM. How should I write it.
Question 2: Where should this detection method be placed, I think this part of the code should be placed in the position shown in the following figure,is that right?

fengchaozhang1_2-1712480903595.png

 

0 Kudos

248 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @fengchaozhang1,

The MCU initializes the SRAM to all zeros after each Power-on reset.

It is discussed here:

https://community.nxp.com/t5/S12-MagniV-Microcontrollers/initialization-RAM-check-for-S12ZVL128/m-p/...

If you decide to do it in SW, it should be done after RDY = 1, refer to the DoZeroOut() routine.

 

Regards,

Daniel

 

0 Kudos