AnsweredAssumed Answered

Target Emulation?

Question asked by Laz on Apr 4, 2011
Latest reply on Apr 7, 2011 by Prashant

Now that I have real hardware, I'm loading my code into Flash and trying to Run/Debug.  The code works fine on the emulator, but not from Flash.  I have confirmed that the Flash image matches the LDR file.  I am using a the simplest code from main() - turn on an LED and then while(1).

 

To debug this, I connected the session but did not load code, and the clicked Run from 0xFFA00000.  When I stopped, the Program Counter was illegal: 0xEF123456.  After further review, I learned that the boot-loader calls the first init code as a subroutine, and manipulates the return address, which is not done when running from the emulator.

 

Any suggestions on how to debug this?  I am using this option in the loader: -noSecondStageLoader -init ezkitBF561_initcode.dxe

 

TIA.

Dan

Outcomes