debugging bootloader code with OBDM s12g128 AN4258

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

debugging bootloader code with OBDM s12g128 AN4258

776 Views
secrob
Contributor II

Dear all,

 

I am facing with some issues when trying to debug/execute bootloader derived from AN4258. I only have OBDM as a flashing tool so CW has provided me a new prm file that I modify following its rules. What I am trying to do is just sending a flash erase command "sector by sector". I tried both using app note routines and IFsh Processor Expert generated routines to give such erase cmd.

In particular it seems that when trying to erase the block from 0x20000 to 0x03EFDF, moving by 0x200, with Real-time CW debugger in running mode, I obtain an invalid break-point condition while, giving the erase command via SCI as the AN suggested, I do not reach the end of the procedure. The original code doesn't seem to have any interrupts protection (disabling them) but what I don't figure out is if, when passing to OBDM, I erroneusly made any error. Any suggestion would be appreciated

Labels (1)
0 Kudos
Reply
1 Reply

573 Views
secrob
Contributor II

Update: I found that when porting code to run with OBDM, I made a mistake with memory region overlapping in an area I was trying to erase (ROM_C000 0xC000-0xFCFF has to be 0xF000-0xFCFF). Feeding COP is also requested in the while loops in flash erasing routines)

0 Kudos
Reply