LPCXpresso - Difference between "Program Flash" and "Debug"

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

LPCXpresso - Difference between "Program Flash" and "Debug"

1,230 Views
vincentvuarnoz
Contributor I

Hi,

What is the difference between using the "Program Flash" facility and using the "Debug" facility in LPCXpresso?

What exactly is loaded to the target's flash memory when using debug (Debug and Release)?

 

The reason behind the question is that "Program Flash" fails because my hardware setup only allows a Wire speed of 300KHz. And changing the wire speed in the Redlink options did not help... So any suggestions on that one would be very helpful too!

 

Kind Regards

Vincent V.

0 Kudos
5 Replies

729 Views
lpcxpresso_supp
NXP Employee
NXP Employee

I find it suspect your debug connection is only reliable at 300 KHz. It should support a much higher wire speed. If you are able to boot the part into the ISP (see https://community.nxp.com/message/630601), can you use a higher wire speed? An alternative method to boot the part into the ISP is to first erase flash, then cycle power.

Thanks and regards,

LPCXpresso Support

0 Kudos

729 Views
lpcxpresso_supp
NXP Employee
NXP Employee

Clicking Debug starts a debug session, which as part of its startup triggers the flash to be programmed, whereas the "Program Flash" button invokes the flash programming routine directly.

Are you saying that if you start a Debug session, all works correctly? But if you use the "Program Flash" button, then you see issues?

In the first place, I suggest that you tell us:

  • What version of LPCXpresso IDE you are using?
  • What host OS you are running LPCXpresso IDE on?
  • What debug probe you are using?

And provide the debug log from your debug session, and the log file from the "Program Flash" utility.

The Debug Log

Using the GUI flash programming tool

Regards,

LPCXpresso Support

0 Kudos

728 Views
vincentvuarnoz
Contributor I

Thanks for your prompt reply!

I'm using LPCXpresso v8.1.4 [Build 606] [2016-03-14] on Windows 10.

I'm using a OM13058 board to debug an external target (LPC 1768) on a custom board.

Yes, Debug session works fine but I needed to set the Wirespeed to 300KHz in the Debugger options. Otherwise I also get the "verify Population of memory and peripherals" error...

Anyway in attachement is the log of the Program Flash, where the same error pops up.

As a reaction to that I tried to change the Wirespeed of the Redlink/LinkServer options but this time it didn't help.

In a Debug session, what is actually programmed to the flash? Is it the same as if I used the "Program Flash" (with .axf or .bin?)  ?

I am currently having trouble to jump to the application from the bootloader. Could it be because programming the chip with a Debug session gets on the way of a clean stack pointer jump?

Thanks you!

Vincent V.

0 Kudos

728 Views
avt
Contributor III

Debug and "program flash" program the same contents to the devices flash. However, Debug does set the initial PC and stack for you (from the values in the image). If your boot loader is not working, it is probably because you are not setting something up correctly. Search this forum for boot loader for lots of information ...

0 Kudos

728 Views
lpcxpresso_supp
NXP Employee
NXP Employee

Please post your debug log as well, for comparison purposes

Regards,

LPCXpresso Support

0 Kudos