Custom 1764 schematic/board with LPC Expresso and LPC-LINK2 issues

Started by microx9000 July 22, 2013
Hey guys, I'm in need of some assistance with my setup. I am using the
LPC-Link 2 with LPC Expresso (v5.2.6) and SWD for programming
(SWIO,SWDCLK, and reset). Here is the schematic I have made and I am
currently following:

s259834bf.png.html>

I'm not 100% on the connections and would appreciate any feedback,
suggestions, etc. I have successfully gotten an LED blinking off of
p0.22, but I am now having difficulties. For instance, when going to
program I now get several errors ranging from target is not debuggable,
invalid processor ID, peripheral access denied, etc. Again, this wasn't
an issue before, but then these errors started to randomly occur when
trying to program, and now it happens all the time. The most common
error I now get when trying to program is "target is not degbugabble."
I have tried the ISP fix. However, the vector cache setting to True
doesn't seem to go through (it still says is it false), so I'm not sure
what I am doing wrong to set it as true (edit current launch, create
new, then under debug tab select vector cache as true). I really am
having a rough time with fixing this issue and could really use some
help from more experienced individuals. Thank you.
[Non-text portions of this message have been removed]

An Engineer's Guide to the LPC2100 Series

You might get more help posting on the dedicated LPCXpresso forum at
http://www.lpcware.com/forums/lpcxpresso/lpcxpresso-forum
--- In l..., "microx9000" wrote:
>
> Hey guys, I'm in need of some assistance with my setup. I am using the
> LPC-Link 2 with LPC Expresso (v5.2.6) and SWD for programming
> (SWIO,SWDCLK, and reset). Here is the schematic I have made and I am
> currently following:
>
> > s259834bf.png.html> I'm not 100% on the connections and would appreciate any feedback,
> suggestions, etc. I have successfully gotten an LED blinking off of
> p0.22, but I am now having difficulties. For instance, when going to
> program I now get several errors ranging from target is not debuggable,
> invalid processor ID, peripheral access denied, etc. Again, this wasn't
> an issue before, but then these errors started to randomly occur when
> trying to program, and now it happens all the time. The most common
> error I now get when trying to program is "target is not degbugabble."
> I have tried the ISP fix. However, the vector cache setting to True
> doesn't seem to go through (it still says is it false), so I'm not sure
> what I am doing wrong to set it as true (edit current launch, create
> new, then under debug tab select vector cache as true). I really am
> having a rough time with fixing this issue and could really use some
> help from more experienced individuals. Thank you.
> [Non-text portions of this message have been removed]
>

I have done so, but I only got one response that said check the crystal and my post has been there for a week. I have tried both 12MHz crystals and switched capacitors with no luck. These crystals were working before and now for some when I do program the target uC nothing happens.

I have made some progress with the erros mentioned above. Something I found interesting was that if I move RESET to pin 5 instead of 6 of the LPC-Link 2 it can program. However, there is no output (no LED blinking) on p0.22. I'm not sure of the cause.

--- In l..., "thenewfallguy" wrote:
>
> You might get more help posting on the dedicated LPCXpresso forum at
> http://www.lpcware.com/forums/lpcxpresso/lpcxpresso-forum
> --- In l..., "microx9000" wrote:
> >
> > Hey guys, I'm in need of some assistance with my setup. I am using the
> > LPC-Link 2 with LPC Expresso (v5.2.6) and SWD for programming
> > (SWIO,SWDCLK, and reset). Here is the schematic I have made and I am
> > currently following:
> >
> > > > s259834bf.png.html>
> >
> > I'm not 100% on the connections and would appreciate any feedback,
> > suggestions, etc. I have successfully gotten an LED blinking off of
> > p0.22, but I am now having difficulties. For instance, when going to
> > program I now get several errors ranging from target is not debuggable,
> > invalid processor ID, peripheral access denied, etc. Again, this wasn't
> > an issue before, but then these errors started to randomly occur when
> > trying to program, and now it happens all the time. The most common
> > error I now get when trying to program is "target is not degbugabble."
> > I have tried the ISP fix. However, the vector cache setting to True
> > doesn't seem to go through (it still says is it false), so I'm not sure
> > what I am doing wrong to set it as true (edit current launch, create
> > new, then under debug tab select vector cache as true). I really am
> > having a rough time with fixing this issue and could really use some
> > help from more experienced individuals. Thank you.
> >
> >
> > [Non-text portions of this message have been removed]
>
Hi,

I checked schematic uploaded by you. There is wrong connections Reset pin
of LPC1764. Capacito C6 should come after Resistor R2. You directly
connected Capacito to VDD. Because of that during power on proper time
delayed Reset Pulse is not generating. Placing Resistor between VDD and
Capacitor C6 create delayed reset pulse. Which is must.
On Mon, Jul 22, 2013 at 9:50 PM, microx9000 wrote:

> **
> I have done so, but I only got one response that said check the crystal
> and my post has been there for a week. I have tried both 12MHz crystals and
> switched capacitors with no luck. These crystals were working before and
> now for some when I do program the target uC nothing happens.
>
> I have made some progress with the erros mentioned above. Something I
> found interesting was that if I move RESET to pin 5 instead of 6 of the
> LPC-Link 2 it can program. However, there is no output (no LED blinking) on
> p0.22. I'm not sure of the cause.
>
> --- In l..., "thenewfallguy" wrote:
> >
> > You might get more help posting on the dedicated LPCXpresso forum at
> > http://www.lpcware.com/forums/lpcxpresso/lpcxpresso-forum
> >
> >
> > --- In l..., "microx9000" wrote:
> > >
> > > Hey guys, I'm in need of some assistance with my setup. I am using the
> > > LPC-Link 2 with LPC Expresso (v5.2.6) and SWD for programming
> > > (SWIO,SWDCLK, and reset). Here is the schematic I have made and I am
> > > currently following:
> > >
> > > <
> http://s51.photobucket.com/user/XMachine9000/media/LPC1764schematic1_zp\
> >
> > s259834bf.png.html>
> > >
> > > I'm not 100% on the connections and would appreciate any feedback,
> > > suggestions, etc. I have successfully gotten an LED blinking off of
> > > p0.22, but I am now having difficulties. For instance, when going to
> > > program I now get several errors ranging from target is not debuggable,
> > > invalid processor ID, peripheral access denied, etc. Again, this wasn't
> > > an issue before, but then these errors started to randomly occur when
> > > trying to program, and now it happens all the time. The most common
> > > error I now get when trying to program is "target is not degbugabble."
> > > I have tried the ISP fix. However, the vector cache setting to True
> > > doesn't seem to go through (it still says is it false), so I'm not sure
> > > what I am doing wrong to set it as true (edit current launch, create
> > > new, then under debug tab select vector cache as true). I really am
> > > having a rough time with fixing this issue and could really use some
> > > help from more experienced individuals. Thank you.
> > >
> > >
> > > [Non-text portions of this message have been removed]
> > >
> >
>

--
From,
Naresh Panchal
[Non-text portions of this message have been removed]

On Tue, 2013-07-23 at 10:16 +0530, Naresh Panchal wrote:
> I checked schematic uploaded by you. There is wrong connections
> reset pin of LPC1764.

> > Something I
> > found interesting was that if I move RESET to pin 5 instead of
> > 6 of the LPC-Link 2 it can program.

Are you sure you connected the reset input to the correct
pin of the jtag header ?
It seems to be connected to ext_pow instead of jtag_reset
according to the picture (of the link in the OP).

And yes, the capacitor is connected to the wrong side of
the reset input pull up resistor. It should be connected
directly between the input pin and gnd, the resistor
between the input pin and +3V3.

roelof

Sorry about that. I have it wrong on the schematic but right on my bread board. I have changed the orientation of the reset 100nF capacitor as well. However, I am still not getting my LED to blink. I am able to flash properly, but could that still mean something hardware-wise is off?

I soldered the processor onto a custom breakout board. Could it be that one of the pins is not soldered properly. I check it out and it looks OK, and I have done this before with a PIC32 and I was able to solder it fine and it worked.

--- In l..., roelof 't Hooft wrote:
>
> On Tue, 2013-07-23 at 10:16 +0530, Naresh Panchal wrote:
> > I checked schematic uploaded by you. There is wrong connections
> > reset pin of LPC1764.
>
> > > Something I
> > > found interesting was that if I move RESET to pin 5 instead of
> > > 6 of the LPC-Link 2 it can program.
>
> Are you sure you connected the reset input to the correct
> pin of the jtag header ?
> It seems to be connected to ext_pow instead of jtag_reset
> according to the picture (of the link in the OP).
>
> And yes, the capacitor is connected to the wrong side of
> the reset input pull up resistor. It should be connected
> directly between the input pin and gnd, the resistor
> between the input pin and +3V3.
>
> roelof
>

On Wed, 2013-07-24 at 22:00 +0000, microx9000 wrote:
> Sorry about that. I have it wrong on the schematic but
> right on my bread board. I have changed the orientation
> of the reset 100nF capacitor as well. However, I am still
> not getting my LED to blink. I am able to flash properly,
> but could that still mean something hardware-wise is off ?

Yes it could be but most likely it is just the program
that wont start. Try to toggle all/more IO pins as a
test and use an oscilloscope or logic analyzer to see
what happens (a multimeter might work if you set the
toggle rate low).
> I soldered the processor onto a custom breakout board. Could
> it be that one of the pins is not soldered properly. I check
> it out and it looks OK,

I solder ICs in lqfp44 and up on a regular bases. Use a 10x
magnification lens to check the solder joints.
You can even test the solder joints by applying pressure
on the pin with a little wooden stick while the program
is running.

And as a last resort you could show your program to us to
see if we can spot an error (no more then a few lines of
code !).

roelof

--- In l..., roelof 't Hooft wrote:
>
> On Wed, 2013-07-24 at 22:00 +0000, microx9000 wrote:
> > Sorry about that. I have it wrong on the schematic but
> > right on my bread board. I have changed the orientation
> > of the reset 100nF capacitor as well. However, I am still
> > not getting my LED to blink. I am able to flash properly,
> > but could that still mean something hardware-wise is off ?
>
> Yes it could be but most likely it is just the program
> that wont start. Try to toggle all/more IO pins as a
> test and use an oscilloscope or logic analyzer to see
> what happens (a multimeter might work if you set the
> toggle rate low).
> > I soldered the processor onto a custom breakout board. Could
> > it be that one of the pins is not soldered properly. I check
> > it out and it looks OK,
>
> I solder ICs in lqfp44 and up on a regular bases. Use a 10x
> magnification lens to check the solder joints.
> You can even test the solder joints by applying pressure
> on the pin with a little wooden stick while the program
> is running.
>
> And as a last resort you could show your program to us to
> see if we can spot an error (no more then a few lines of
> code !).
>
> roelof
>
Thank you so much for the replies. I am making some progress. However, in case I don't figure it out, I ordered another board with uC soldered on for me this time. So, if it doesn't work with the new board I know it is most likely a software issue. In the mean time I will try and troubleshoot my current setup as well.

I did manage to get flash magic to work as well. After using the hex file from the project, the debug errors have stopped and I can use pin 6 as reset and SWD again. The program I am using is an unaltered code of the LPC17xx_cmsis2_systick. The only thing I changed was the target microcontroller from LPC1768 to LPC1764.

I also have another program that I am using based off of the LPC1764 (that did work before, but now doesn't). So, it looks like a hardware issue, but I'm still not 100%.

I've got it working. I brought a newer chip and it's fine. It may have been a soldering issue and one of the pins was sorted or not properly connected. Thanks everyone for there responses and helpful tips/advice.