Lakshman Rao

Codewarrior IDE 4.6: Erases all pages automatically

Discussion created by Lakshman Rao on Oct 23, 2008
Latest reply on Dec 6, 2008 by Neil Garner
Hi all,
 
I am trying to selectively erase flash pages when the IDE loads the program code.
 
I have the entry in the .ini file as NVMAEFSKIPSELECTION=FLASH AEFSKIPERASING  1 2 as I donot want the pages FF , FE (0xC000, 0x8000) to get erased as boot loader resides there.
But still the IDE erases all the pages
 
However, in my boot code, I have used the same option as
NVMAEFSKIPSELECTION=FLASH AEFSKIPERASING  0 3  and this works perfectly fine and does not erase any other page than FF and FE
 
I am using the micro MC9S12XEP100.
 
Is there any other numbering (exp. 3 - ppages) i should follow to get the first case working. please advice
Also, what is the most reliable way of resetting the micro through software.
I tried to enable cop and invalidate it by the following instructions
 
COPCTL = 0x83;
ARMCOP = 0x00;
 
But this is not very consistent and sometimes resets to address FFFF and halts there.
 
with regards,
Lak

Outcomes