Use the JTAG of LPCXpresso

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

Use the JTAG of LPCXpresso

657 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by ngoncalves on Wed Feb 15 07:56:26 MST 2012
Hello,

We bought two LPCXpresso boards (with the LPC179 processor) and used them to develop our application, using also CodeRed IDE.

Now we have designed our own PCB board and wanted to test the code on there. We broke the connection on the LPCXpresso board between the JTAG and the processor, then connected the JTAG pins to our board.

The problem is that when we tried to download and debug the code, we got an error saying that the ID of the processor was different than expected.

Is the JTAG tool of the LPCXpresso board fixed to use only the processor that comes with this board ?

  Thanks,

   Nelson
0 Kudos
6 Replies

505 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Wed Feb 15 12:10:07 MST 2012
Note#1:[INDENT] As described in http://www.arm.com/products/system-ip/debug-trace/coresight-soc-components/serial-wire-debug.php


Quote:

Serial Wire Debug technology is available as part of the CoreSightâ„¢ Debug Access Port and provides a 2-pin debug port, the low pin count and high-performance alternative to JTAG.

So SWD is not JTAG :eek:
[/INDENT]Note#2:[INDENT]As described in http://knowledgebase.nxp.com/showthread.php?t=635

it's also useful to connect Reset :) and use a simple 4-wire connection.
[/INDENT]
0 Kudos

505 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by ex-kayoda on Wed Feb 15 12:07:29 MST 2012
What about Reset :eek:
0 Kudos

505 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Rob65 on Wed Feb 15 11:14:23 MST 2012

Quote: Zero
Are you sure that you are using JTAG?



Of course he is sure about this.
If the debug configuration is set to "NXP LPC17xx (JTAG)" that means JTAG is being used (Yes, I can be a smartypants too :D).

SWD just uses a subset of the JTAG pins (only SWDIO and SWCLK are being used) so if all JTAG pins are connected this will just work.
NXP calls it "JTAG connector" so it's understandable that users just call it a JTAG connection - even though most of us just use SWD.

Using SWD just means that we could use the extra pins for our own program.

My eye just glanced across the terminology section in the Getting Started manual and there I read the following:

Quote:

SWD
Serial Wire Debugging (Single Wire Debugging). This is a debug connection technology available on the Cortex-M3 that allows debug through just 2-wires unlike 5 for JTAG.

Isn't that fun: [COLOR=Red][B]Single [/B][/COLOR]Wire Debug ... [COLOR=Red][B]2[/B][/COLOR] wires :eek:

I have only 3 wires running from the LPC-Link to my target board: SWDIO, SWCLK and Gnd.

Regards,
[INDENT]Rob
[/INDENT]
0 Kudos

505 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Wed Feb 15 10:17:42 MST 2012

Quote: ngoncalves
...that the JTAG...



Are you sure that you are using JTAG? Probably you are using SWD :)
0 Kudos

505 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by ngoncalves on Wed Feb 15 10:12:50 MST 2012
Ups, you're right. :o

The first time we tried, we got an "unknown ID xxxx, expecting xxxx" and though that the JTAG could be blocked to the processor on the LPCXpresso board.

We are using a different processor, but still in the same family, on our board. As soon as we changed the compilation settings, it worked.

Thanks
0 Kudos

505 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Wed Feb 15 08:05:03 MST 2012
No, there's nothing fixed. SWD is debugging / flashing everything :eek:

Probably you have selected wrong MCU setting in properties :)
0 Kudos