EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Switch to bootloader (ISP mode) on LPC2368

Started by "Jorge S." September 30, 2008
Hi all,

Is there any example on how to switch to bootloader from user code on the
LPC2368?

Googling around i've only found some examples for the LPC21xx family.

Thanks in advance,

Regards,
Jorge.

An Engineer's Guide to the LPC2100 Series

There is an ISP call (Reinvoke ISP) which restarts the bootloader in ISP
mode. There are some technical notes on this call in the UM.

Steve C.

-----Original Message-----
From: l... [mailto:l...] On Behalf
Of Jorge S.
Sent: Tuesday, September 30, 2008 10:33 AM
To: l...
Subject: [lpc2000] Switch to bootloader (ISP mode) on LPC2368

Hi all,

Is there any example on how to switch to bootloader from user code on
the
LPC2368?

Googling around i've only found some examples for the LPC21xx family.

Thanks in advance,

Regards,
Jorge.




On Tue, 30 Sep 2008 14:52:12 -0700, you wrote:

>There is an ISP call (Reinvoke ISP) which restarts the bootloader in ISP
>mode. There are some technical notes on this call in the UM.

Don't know how similar this is to the LPC213x, but on the latter part there are some undocumented
issues with this call that took me ages to find - you need to set up the stack pointer, disable fast
IO and the fractional baudrate divider. R1 must also be initialised to point somewhere sensible
despite the call not returning.

>
>Steve C.
>
>-----Original Message-----
>From: l... [mailto:l...] On Behalf
>Of Jorge S.
>Sent: Tuesday, September 30, 2008 10:33 AM
>To: l...
>Subject: [lpc2000] Switch to bootloader (ISP mode) on LPC2368
>
>Hi all,
>
>Is there any example on how to switch to bootloader from user code on
>the
>LPC2368?
>
>Googling around i've only found some examples for the LPC21xx family.
>
>Thanks in advance,
>
>Regards,
>Jorge.
>
>
>
>
>
I am planning to try the same proc with a 2119. From the docs:

-The boot sector is 8 kB in size and resides in the top portion

i.e. 0x0003 E000 in the LPC2119 256kb Flash part. During booting this sector is mirrored in the lower part.
and:

-ISP programming: "G 0 A" branches to address 0x0000 0000 in ARM mode. The code read protection must be disabled if it is a protected area.

I would assume that branching in the program with an absolute jump without a return instruction should do the job too. I will find out soon enough,. but if you succeed before me, let me know.

Ed


The 2024 Embedded Online Conference