LPC1764 SWD program

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

LPC1764 SWD program

559 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 09:20:17 MST 2012
Greetings,

I try to get my LPC1764 working. Its placed on a custom board, the connections between the (separated) LPC-Link are designed like showed in the LPC-Link schematic, using the 10-pin JTAG connector.

For some reason, when I try to program/debug the device LPCXpresso gets stuck (not responding) at "15% [Connect] nSRST assert (if available)" and begins to reset the µC every second.

Can anyone help me here?

Regards,
Frank
0 Kudos
12 Replies

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 14:33:29 MST 2012
HOLY CRAP!
Well, I am very sorry for wasting your time like that. I have no idea how that happened :(
Thanks for your help, I appreciate it.

Regards,
Frank
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Feb 23 13:26:05 MST 2012
Sorry for that dump question :rolleyes:

Are you sure that you've soldered in your 1764 correctly?

If you've mixed up pin 1 mark that would explain why you are measuring a VDD connection, that's not pin 53, that's pin 28 = VDD :eek:

Picture: http://flic.kr/p/bxSbea
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 13:14:27 MST 2012
Vector catch did not work.

So I tried to switch to ISP.  But I can't pull Pin 53 to GND without causing a short.

No supply on the board -> short between ISP pin and VCC
Supply -> short between ISP pin and VCC
Supply, applied RESET -> short between ISP pin and VCC

Interestingly Pin 54 is connected to VCC, so I watched at Pin 53 via a microscope. I cant see any evidence for a unmeant short.

Fortunately I have another board right here. Checked if there a short beween VCC an that Pad. No allusion to that.
Took another LPC1764 and placed it (not soldered, just put it on the footprint) -> short between ISP pin and VCC.

I'm not sure but is it possible that Pins do that while not powered?

It strange enough that the µC is marked not debuggable . It was brand new..
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Feb 23 11:55:28 MST 2012

Quote: Frank26094
Target marked as not debuggable?



At this point I would strongly suggest to:

#1 Switch Vector catch on

#2 Switch to ISP and try to debug then

described in: http://support.code-red-tech.com/CodeRedWiki/DebugAccessChip

If that fails, use FlashMagic and delete the complete flash:

http://www.flashmagictool.com/
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Feb 23 11:48:20 MST 2012

Quote: Frank26094
Pin 53. Funny thing is, that its directly connected to VCC (internal, not on the pcb). Pulling it down will force a short? I don't get that.



Nonsense :) Usually this pin is pulled up (10k) external and grounded to switch to ISP.

User manual:

Quote:

Pin P2.10 is used as a hardware request signal for ISP and therefore requires special attention. Since P2.10 is in[COLOR=Red] high impedance mode[/COLOR] after reset, it is important that the user provides external hardware (a pull-up resistor or other device) to put the pin in a defined state. Otherwise unintended entry into ISP mode may occur.

0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 11:40:06 MST 2012
Updated to LPCXpresso 4.1.5

Now it doesn't get stuck an I'm getting a error message:


Quote:
Pc: (  0) Reading remote configuration
Ni: LPCXpresso Debug Driver v4.0 (Dec  9 2011 09:48:15)
Nc: Looked for chip XML file in C:/NXP/LPCXpresso_4.1.5_219/lpcxpresso/bin/LPC1764.xml

Nc: Looked for vendor directory XML file in C:/NXP/LPCXpresso_4.1.5_219/lpcxpresso/bin/nxp_directory.xml

Nc: Found generic directory XML file in C:/NXP/LPCXpresso_4.1.5_219/lpcxpresso/bin/crt_directory.xml

Pc: (  5) Remote configuration complete
Xe:
Pc: ( 15) nSRST assert (if available)
Ed:02: Failed on connect: Ep(01). Target marked as not debuggable.
Et: Emu(0): Connected. Was: None. DpID:     EDB6. Info: T1S6RGRIA
Error 0: (null)
Last sticky: 0. AIndex: 0
No MemAp selected
No Speed test
SWD Frequency: 250 KHz. RTCK: False. Vector catch: False.
Packet delay: 0  Poll delay: 0.
Pc: (100) Target Connection Failed

Target marked as not debuggable?
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 11:19:59 MST 2012
#1 http://files.kahl-com.de/Frank/scope_0.png
http://files.kahl-com.de/Frank/scope_1.png
http://files.kahl-com.de/Frank/scope_2.png

Hope that's better.
Looks kind of strange to me...

#2 SWCLK and SWDIO are coming from the JTAG-Connector and are directly connected to Pin 5 and 3.

#3 Did not try that. As far as I know u have to pull down the ISP Pin P2[10] Pin 53. Funny thing is, that its directly connected to VCC (internal, not on the pcb). Pulling it down will force a short? I don't get that.

//Messed up the pictures. Try again... Done
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Feb 23 10:16:23 MST 2012
#1 I'm missing Reset in your picture :)  http://flic.kr/p/9eJazy

#2 How did you connect SWCLK and SWDIO?

#3 Did you try to use UART bootloader already?
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 10:08:55 MST 2012
Its a LQFP100, sorry for not mentioning that.

RST_N is pulled up.
I scoped SWDIO and it looks like he tries to submit data.


[IMG]http://files.kahl-com.de/Frank/setup_0.png[/IMG]
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Feb 23 09:45:36 MST 2012

Quote: Frank26094
#1 Pin 10 of the JTAG-Interface?



Don't ask me :)


Quote: Frank26094
I connected that to Pin 17 of the LPC1764. Additionally there a tri-state buffer for a manual reset over a button.



So I assume it's a LQFP100. Reset is pin 17 there. Is it pulled up and did you scope SWD behaviour ? LPC-Link is trying to reset (=low) several times :rolleyes:


Quote: Frank26094
And im pretty sure that the pcb is ok.



1 cent for every time I hear that...
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Frank26094 on Thu Feb 23 09:35:09 MST 2012
#1 Pin 10 of the JTAG-Interface?
     I connected that to Pin 17 of the LPC1764. Additionally there a tri-state buffer for a manual reset over a button.
#2 There a more components on this board, but there are not placed yet. And im pretty sure that the pcb is ok.
0 Kudos

516 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Feb 23 09:26:01 MST 2012
#1 So what did you connect to your custom board RST_N pin?

#2 Is it a working custom board or are you even unsure if hardware is working?
0 Kudos