How to clear EEE Nonvolatile Information register fields - MC9S12XET256

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

How to clear EEE Nonvolatile Information register fields - MC9S12XET256

655 Views
subashr
Contributor III

I have partitioned the Dflash for emulation. DFPART:116, ERPART:1

Once partitioned, the information is not deleted.

I'm aware that it is stored in Global address, 0x12_0000 (as per table 25.7 in the controller datasheet - EEE Nonvolatile Information register fields). So on reset, these values are restored.

If I try to erase these values using command "Erase All Blocks Command - 0x08" or "Unsecure Flash Command - 0x0B", the ECU goes to Illegal break point. ie., it looks the code is erased.

 

Q1) How to clear the values in EEE Nonvolatile Information register fields without affecting the code?

Q2) What is use of commands "Set User Margin Level Command - 0x0D, Set Field Margin Level Command - 0x0E"? Can this commands help in blocking the erase of the program code (If it is deleted).

Q3) Can I erase the EEE IFR only on start up or during run time (in some scenario)

Labels (1)
Tags (1)
0 Kudos
2 Replies

455 Views
RadekS
NXP Employee
NXP Employee

Hi Subash,

Yes, the EEE at S12XE is typically partitioned just once per lifetime.

Yes, the only way how to clear partitioning is complete mass erase of whole MCU.

 

The simplest way how to do it is execution unsecure procedure.  

In Code Warrior debugger menu ->MultilinkCyclonePro->Unsecure…

If not work you can use unsecure12 from P&E (only for PEmicro BDM interfaces):

http://www.pemicro.com/downloads/download_file.cfm?download_id=16

That will complete erasing the whole MCU include partitioning information.

 

The execution "Erase All Blocks Command - 0x08" directly by MCU code goes to Illegal break point because you erase code which you execute. The execution "Erase All Blocks Command - 0x08" directly by MCU code doesn’t have so much sense except “self-destruction” application. ;-)

 

Q1)

Not possible due to safety reason. The only way is through complete mass erase in a special mode.

Q2)

The commands "Set User Margin Level Command - 0x0D, Set Field Margin Level Command - 0x0E" are designed for flash reliability testing – test whether memory cells are enough charged/discharged.

They cannot help in such manner.

For more details about Margin Level commands, please check AN3419 System Integrity Techniques for the S12XE:
http://www.nxp.com/files/microcontrollers/doc/app_note/AN3419.pdf

Q3)

Not possible due to safety reason. The only way is through complete mass erase in a special mode.

 

 

More details about EEE at S12XE may be found in attached short description and example codes.

I hope it helps you.

Have a great day,
Radek

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

455 Views
subashr
Contributor III

Hi Radek,

Thanks for your reply.

Subash

0 Kudos