Unable to modify FLASH from CodeWarrior v6.3

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

Unable to modify FLASH from CodeWarrior v6.3

Jump to solution
992 Views
lazde
Contributor II

Using CodeWarrior v6.3 with a USB Multi-link to a MC9S08QE8, should I be able to modify FLASH from the CodeWarrior memory window when the target program is halted?  Was able to do this with the MC908QB8 but not with the QE8.  I'm thinking CodeWarrior may have something to enable for the QE8.

Labels (1)
0 Kudos
1 Solution
397 Views
lazde
Contributor II

The Reference Manual for the QE8 does not explain Bit 6,the FLS bit, in the System Clock gating Control 2 register (SCGC2).  It covers all the other bits but not the FLS bit.  If the FLS bit is set to 0, this will disable reading the FLASH high registers in $1820-$182B.  Once enabled, FLASH can be erased and reprogrammed in-application.

View solution in original post

0 Kudos
4 Replies
397 Views
lazde
Contributor II

I was comparing FLASH access to the QB8 MCU using an FSIC emulator which will allow FLASH to be modified but it appears to be emulated FLASH (maybe with RAM on board the emulator).  QE8 uses its internal debugger and true FLASH that cannot be editted.

0 Kudos
398 Views
lazde
Contributor II

The Reference Manual for the QE8 does not explain Bit 6,the FLS bit, in the System Clock gating Control 2 register (SCGC2).  It covers all the other bits but not the FLS bit.  If the FLS bit is set to 0, this will disable reading the FLASH high registers in $1820-$182B.  Once enabled, FLASH can be erased and reprogrammed in-application.

0 Kudos
397 Views
bigmac
Specialist III

Hello,

 

I agree that this does seem to be an omission from the reference manual.  However, as a general rule, the state of any bit within a MCU hardware register that is undocumented, or even not properly understood, should always remain at its POR default value.  This was obviously not the caes for the instance that you describe.

 

Regards,

Mac

 

0 Kudos
397 Views
lazde
Contributor II

I would agree if it was not for the reference manual stating to disable gates from the system clock to conserve power and prevent unexpected results.  Gating of the system clock is a great design and provides tons of control.

0 Kudos