AnsweredAssumed Answered

EEPROM emulation problems

Question asked by Bengt Andersson on Mar 28, 2018

I have implemented an emulated EEPROM in M(S)PC5602B using CW 11.0 and I think I have some problem connected to this implementation.

 

When one of the DFLASH sectors used for EEPROM has been corrupted for some reason, probably after power loss during sector erase, a read from an address in this sector will cause a "data storage interrupt". As the implementation is done now the execution will be trapped inside ivor_branch_table (in file ivor_branch_table.c) forever.

 

asm void ivor_branch_table_p0(void) {

nofralloc

       .align SIXTEEN_BYTES

IVOR0trap:  b  IVOR0trap /* Critical Input interrupt handler */

 

      .align SIXTEEN_BYTES

IVOR1trap:  b  IVOR1trap /* Machine check / (NMI) interrupt handler */

 

      .align SIXTEEN_BYTES

IVOR2trap: b  IVOR2trap /* Data Storage interrupt handler */

 

I have tried to find some information about this interrupt in the reference Manual (MPC5604B/C Microcontroller Reference Manual) but I have find nothing. But It is clearly possible to miss something when reading almost 1000 pages!

Do you now where the information could be found?

 

Is this behaviour right when having problems in the DFLASH or is it possible to end up here for other reasons?

 

/Bengt

Outcomes