Content originally posted in LPCWare by s.achterop@rug.nl on Tue Aug 28 10:34:15 MST 2012
Dear list,
I cannot debug my custom lpc1768 board with the LPC-Link part of a LPCXpresso (LPC1114)
I separated the LPC1114 from the LPCXPRESSO and connected the lpc-link to my target.
I did not use the 10-pins header, but used the connections from the interface to the LPC1114 side
of my lpcxpresso. So signal RTCK is not used, but that is OK. And all 5 JTAG connections are properly
connected to the lpc1768 (pin 1 to 5) on my custom board.
I am working on Linux and the following happens:
$ crt_emu_cm3_nxp -info-scan
Ni: LPCXpresso Debug Driver v4.0 (Dec 12 2011 10:43:04)
Ee(05). No matching emulator found - make sure power is on and not in use already.
$ crt_emu_cm3_nxp -info-emu
Ni: LPCXpresso Debug Driver v4.0 (Dec 12 2011 10:43:04)
0 Emulators available:
It seems as if the lpc1768 is not recognized, but each time I boot the lpc1768 in bootmode using
pin P2_10 is seems that it can be flashed ONE SINGLE time!
So the lpc1768 seems to be working at least partly.
Here the first two invocations of the bootloader AFTER starting the ISP command handler using P2_10:
$ crt_emu_cm3_nxp -2 -pLPC1768 -vendor=NXP -wire=winusb -flash-load-exec=ledjes.bin
Ni: LPCXpresso Debug Driver v4.0 (Dec 12 2011 10:43:04)
Nc: Looked for chip XML file in /usr/local/lpcxpresso_4.1.5_187/lpcxpresso/bin/LPC1768.xml
Nc: Looked for vendor directory XML file in /usr/local/lpcxpresso_4.1.5_187/lpcxpresso/bin/nxp_directory.xml
Nc: Found generic directory XML file in /usr/local/lpcxpresso_4.1.5_187/lpcxpresso/bin/crt_directory.xml
Nc: Emu(0): Conn&Reset. DpID: 2BA01477. Info: LPCLINK_1_1
Nc: SWD Frequency: 3000 KHz. RTCK: False. Vector catch: False.
Nc: Packet delay: 0 Poll delay: 0.
Nc: NXP: LPC1768 Part ID: 0x26013F37
Nt: Connected: was_reset=true. was_stopped=false
Cr:v Registered license, download limit of 128K
Nt: Loading binary file 'ledjes.bin' at location 00000000
Nt: Writing 660 bytes to 0000 in Flash (assumed clock: 14.748MHz)
Nt: Verified-same page 0-0 with 660 bytes in 260msec
Nt: Flash write Done
Nc: nSRST assert (if available)
Nc: Executing in bootloader.
Nt:
Nc: nSRST assert (if available)
Nc: Executing in bootloader.
$ crt_emu_cm3_nxp -2 -pLPC1768 -vendor=NXP -wire=winusb -flash-load-exec=ledjes.bin
Ni: LPCXpresso Debug Driver v4.0 (Dec 12 2011 10:43:0 Nc: Looked for chip XML file in /usr/local/lpcxpresso_4.1.5_187/lpcxpresso/bin/LPC1768.xml
Nc: Looked for vendor directory XML file in /usr/local/lpcxpresso_4.1.5_187/lpcxpresso/bin/nxp_directory.xml
Nc: Found generic directory XML file in /usr/local/lpcxpresso_4.1.5_187/lpcxpresso/bin/crt_directory.xml
Xw:
Ed:02: Failed on connect: Ep(04). Cannot halt processor.
Et: Emu(0): Conn&Reset. Was: None. DpID: 2BA01477. Info: LPCLINK_1_1
Error 0: (null)
Last sticky: 16. AIndex: 0
MemAp selected: 0
Speed test resends: 0
SWD Frequency: 3000 KHz. RTCK: False. Vector catch: False.
Packet delay: 0 Poll delay: 0.
The first time seems OK, but after that the target cannot be used anymore.
Using gdb gives something similar, the first time it seems to flash ok, but after the first "stepi" it does
not return.
It is not related to file to be flashed, because that works properly on a lpcxpresso with a lpc1768.
It could be that my hardware is broken, but I don't think so.
Does anyone has an idea what is wrong, or how to test any further?
Thanks in advance.
Sietse Achterop