EmbeddedRelated.com
Forums

LPC2378 programming pitfalls

Started by varuzhandanielyan March 21, 2007
Today I unsuccessfully tried to program LPC2378 with
FlashMagic and H-JTAG.

FlashMagic report that it "failed to autobaud", though
with scope I can see a response of the chip.

H-JTAG detects target as ARM7TDMI-S 0x4F1F0F0F, but
when I try to program, or just to erase the flash, I
receive message: "can't halt target and make it enter DEBUG state".

I use a board of my own design with 12MHz quartz. On my
previous designs with LPC2129, LPC2138 and LPC2148 I had
no problems with programming.

Questions:
1. Is anybody familiar with the same problem?
2. Does anybody succeed to program the LPC2378 chip in
similar conditions?
3. Is it possible to damage permanently the chip by
wrong programming.

Great thanks in advance,
Varuzhan

An Engineer's Guide to the LPC2100 Series

--- In l..., "varuzhandanielyan" wrote:
>
> Today I unsuccessfully tried to program LPC2378 with
> FlashMagic and H-JTAG.
>
...

> Questions:
> 1. Is anybody familiar with the same problem?
> 2. Does anybody succeed to program the LPC2378 chip in
> similar conditions?
> 3. Is it possible to damage permanently the chip by
> wrong programming.
>
> Great thanks in advance,
> Varuzhan

Hi Varuzhan,

Another user here reported identically the same problem. This user
was able to recover from the problem using a version of SILL I sent
privately.

I have incorporate these changes (for LPC2378) to free version you can
get from here or in the FILEs page under "BootImages" director:

http://www.cse.unsw.edu.au/~jayas/esdk/sill.html

Running it as "sill -r comX" should erase your part and get it going
again.

If it does not work, please drop me an email as I may have missed out
propagating all the changes. I know for a fact the diagnostic I sent
this other user worked on MCB2300? board with LPC2378.

Regards,

Jaya
Hy Jaya,

I have the same problem with an LPC2103 but I use a parallel j-tag from Olimex (http://www.olimex.com/dev/arm-jtag.html) so I cant use SILL.

It worked fine until a tried to change the fervency ( I did PLLCFG_bit.MSEL = 10 instead of PLLCFG_bit.MSEL = 4, the crystal fervency is ~14Mhz) from that moment I recived this error message from IAR:

FATAL ERROR
WinRDI OpenProc failed
[RDI Error: 602] Cant halt target and make it enter DEBUG state
Session aborted!

Sat Apr 28 14:41:32 2007: Failed to load flash loader: C:\Program Files\IAR Systems\Embedded Workbench 4.0 Kickstart\ARM\config\flashloader\NXP\FlashNXPLPC32k.d79
Is the controller damaged ?

--- In l..., "varuzhandanielyan" wrote:
>>
>> Today I unsuccessfully tried to program LPC2378 with
>> FlashMagic and H-JTAG.
>>
>...
>
>> Questions:
>> 1. Is anybody familiar with the same problem?
>> 2. Does anybody succeed to program the LPC2378 chip in
>> similar conditions?
>> 3. Is it possible to damage permanently the chip by
>> wrong programming.
>>
>> Great thanks in advance,
>> Varuzhan
>
>Hi Varuzhan,
>
>Another user here reported identically the same problem. This user
>was able to recover from the problem using a version of SILL I sent
>privately.
>
>I have incorporate these changes (for LPC2378) to free version you can
>get from here or in the FILEs page under "BootImages" director:
>
> http://www.cse.unsw.edu.au/~jayas/esdk/sill.html
>
>Running it as "sill -r comX" should erase your part and get it going
>again.
>
>If it does not work, please drop me an email as I may have missed out
>propagating all the changes. I know for a fact the diagnostic I sent
>this other user worked on MCB2300? board with LPC2378.
>
>Regards,
>
>Jaya
>
--- In l..., cata_tm_83@... wrote:
>
> Hy Jaya,
>
> I have the same problem with an LPC2103 but I use a parallel j-tag
> from Olimex (http://www.olimex.com/dev/arm-jtag.html) so I can't use
SILL.
>
> It worked fine until a tried to change the fervency ( I did
> PLLCFG_bit.MSEL = 10 instead of PLLCFG_bit.MSEL = 4, the crystal
> fervency is ~14Mhz) from that moment I recived this error message
from IAR:
>
> FATAL ERROR
> WinRDI OpenProc failed
> [RDI Error: 602] Can't halt target and make it enter DEBUG state
> Session aborted!
>
> Sat Apr 28 14:41:32 2007: Failed to load flash loader:
> C:\Program Files\IAR Systems\Embedded Workbench 4.0
> Kickstart\ARM\config\flashloader\NXP\FlashNXPLPC32k.d79
> Is the controller damaged ?
>
> --- In l..., "varuzhandanielyan" wrote:
> >>
> >> Today I unsuccessfully tried to program LPC2378 with
> >> FlashMagic and H-JTAG.
> >>
> >...
> >
> >> Questions:
> >> 1. Is anybody familiar with the same problem?
> >> 2. Does anybody succeed to program the LPC2378 chip in
> >> similar conditions?
> >> 3. Is it possible to damage permanently the chip by
> >> wrong programming.
> >>
> >> Great thanks in advance,
> >> Varuzhan
> >
> >Hi Varuzhan,
> >
> >Another user here reported identically the same problem. This user
> >was able to recover from the problem using a version of SILL I sent
> >privately.
> >
> >I have incorporate these changes (for LPC2378) to free version you can
> >get from here or in the FILEs page under "BootImages" director:
> >
> > http://www.cse.unsw.edu.au/~jayas/esdk/sill.html
> >
> >Running it as "sill -r comX" should erase your part and get it going
> >again.
> >
> >If it does not work, please drop me an email as I may have missed out
> >propagating all the changes. I know for a fact the diagnostic I sent
> >this other user worked on MCB2300? board with LPC2378.
> >
> >Regards,
> >
> >Jaya
> >

Hello,

I recall in the previous instance that the user was able to recover
from this problem with SILL -- so it does not look like your MCU is
damaged.

I dont know what board you are using, but if you have access to the
serial port, then SILL is your quick way out.

I think when it locks up, there are issues with the PLL that somehow
is not properly reset on power cycling that causes this problem but I
cannot be sure.

Jaya
Hy Jaya,

This is my board & jtag that I’m using:

http://www.olimex.com/dev/lpc-h2103.html
http://www.olimex.com/dev/arm-jtag.html with H-JTAG driver

Could you give me some advise ? Another solution is to buy
another board but this should take two weeks which is not ok because
I’m already late with my diploma project.

Great thanks in advance,
Cata
--- In l..., "Mihai Catalin" wrote:
>
> Hy Jaya,
>
> This is my board & jtag that I’m using:
>
> http://www.olimex.com/dev/lpc-h2103.html
> http://www.olimex.com/dev/arm-jtag.html with H-JTAG driver
>
> Could you give me some advise ? Another solution is to buy
> another board but this should take two weeks which is not ok because
> I’m already late with my diploma project.
>
> Great thanks in advance,
> Cata

Hi Cata,

It does not look like this board has level translators to connect it
directly to PC serial port. Unless you know and can build one, SILL
recover option is not going to be of much use I am afraid.

Regards,

Jaya

PS: I thought your board had 2378 but I see from the schematics it is
2103. The recover option in SILL will work, but install option does
not (yet) work for LPC2103.