LPC-Link2 + LabTool is not recognize by LCPXpresso

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

LPC-Link2 + LabTool is not recognize by LCPXpresso

1,112 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SoftFace2 on Sun Nov 08 13:35:40 MST 2015
I've recently (last week)  bought LPC-Link 2 & LabTool which is based on the LPC4370 ‘- a 204 MHz Cortex-M4 with an 80 MHz ADC and two extra Cortex-M0 cores).
I didn't have any trouble to make it works with LabTool Application V1.2.
My main issue right now is that I can't make it recognize by LPCXpresso v7.9.2 [Build 493] [2015-09-14].
I made a lot of tests disconnected and reconnected USB cable, change connection port, shutdown the PC.
PC configuration Windows 10/64 bits/ Asus K30AD_M31AD_M41AD_M32AD

The hardware status is the following one
When connected LabTools board is connected Via LPC-Link2 on USB cable (keep in mind there are 3 LED 2 greens and a red one):
The green LED close to J4 is stay on
The green one located close to J13 is slowly flashing
The red one sometime stay on sometime it is flashing (Period #1s)
On application side I use a typical program Blinky extracted from lpcopen_2_12_lpcxpresso_nxp_lpclink2_4370.zip but I tried other ones without better success.
Different configurations appears when I try to launch a debug session:

If the red LED stay on:
A dialog box appears with the following message (Initializing CMSIS-DAP with LPC432x_CMSIS_DAP_V5_112.bin.hdr. Dialog box stay few second and is overlapped by another one with a Timeout message.
After that I have another dialog box “Connect to emulator: CMSIS-DAP indicating that no Compatible emulators available

If the red LED is flashing:
First dialog box display “Launching mc_sa_blinking_m4 Debug’ has encountered a problem/ Error in final launch sequence.
The message on second dialog box is:
  02: Failed on connect
  Could not connect to core.
  31: No connection to emulator device”
Obviously I read a lot of message on this forum with no success. I have been trying to see if the problem could come from my computer (the bios is last version). I ask windows for diagnose. Its error message is to say that the LPC_LINK2 does not support USB3. I very confuse because the labtool application works perfectly with this PC.
I took a lot of time with this problem is someone cant help me to identify the source of this problem.
Thanks a lot and sorry for my bad english
0 Kudos
10 Replies

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SoftFace2 on Tue Nov 17 14:55:38 MST 2015
Ouf Ouf Ouf .... J’ai finalement réussi à faire fonctionner cette satanée carte avec ce satané logiciel..
Oups! in English so I finally managed to get the board work with LPCXpresso.
The following message is for newbies like me.
The problem didn’t come from the hardware for sure (on the Pc and LPC_LINK side). I don’t know exactly where exactly the problem came from I can only describe what I did I uninstall LPCXpresso and associated driver because I detected that there were some troubles with some path (maybe because this installation was made on D not C drive). I reinstalled the same version on the same place but I replace the default name LPCXpresso v7.9.2  by LPCXpresso (to avoid problem with the directory parser). Then I included the LPC4370_LEDBlinky. Unfortunately there were again problems with directories and missing files. I imported the dedicated library for LPC4370 (CMSIS_CORE_XXX) as a project. The operation has solved the unresolved references and Eureka ! it has worked red LED blink. I can also push the program in flash memory to get the target board autonomous. One remark the good driver is "LPC18_43_SPIFI_1MB_4KB.cfx" not that I had after my first installation.
Probably this result is very trivial for many of readers but it was a great success for me. I spend many hours to come at this point.
I was about to give up and come back to my old companion KEIL IDE where I made a lot of work with LPC1768.
Now I could hopefully start to familiarize myself with the code and make some performance evaluation around high rate ADC.
Thanks for help
0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by vtw.433e on Sun Nov 15 14:39:52 MST 2015
You are missing a very basic understanding of this chip.

It is a dual core m4 and m0. On boot, the m0 is held in reset by the m4 until you write code to release it from reset. That is, you cannot run any code in the m0 (or connect a debugger) until you have 'booted' it by the m4. I.e. You cannot download code and run code in the m0, unless the m4 has run code to boot it.

What normally happens with LPCXpresso is that you have an m4 application and an m0 application that is linked into a single flash image that is downloaded by connecting the debugger to the m4. (Remember both cores share the same address space and same memories). Once the m4 has released the m0 from reset, you can then connect a debugger to it.

Suggest you use the dual core blinky supplied with the legacy examples in LPCXpresso.

And make sure you understand the lpc43xx chip and how it works - you clearly haven't.
0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SoftFace2 on Sun Nov 15 14:27:29 MST 2015
Thanks for your help.
I read the FAQ suggested and made some tests with recommended project.
I used mc_sa_blinkly_m0app. I'va also created another one from scratch. My problem is always the same I can't access to debug mode.
The error message is the following one :
15: Target error from Commit Flash write: Ef(34): Timed-out initializing flash. (crt_emu_cm_redlink) terminating on communication loss: Pipe has been closed by GDB.

I think the debug probe do not succeed in writing in SPI flash. I tried to program directly the SPI flash memory using “program flash” button. I get a bit more explicit message see MSG1 below.
I noticed that the flash driver used by default was “LPC18_43_SPIFI_16MB_64KB.cfx”.
My SPI flash (From schematic of LPC-LINK2) is SPW25Q80BVSSIGI which is a 8 M (1 M x 8) memory. I guessed that the default configuration was not the right one. You can select many other model but I didn’t find the right one; I tried many other (LPC18_43_SPIFI_1MB_4KB.cfx, LPC18_43_SPIFI_8MB_64KB.cfx …) without success.
For memory I have two LPC-Link2 one is used as a probe and another one as a target with JP1 closed.
Where I am wrong?. I don’t know anymore where I have to look for. Some suggestions or ideas were welcome. Thanks in advance for any helps.

MSG1:
Ni: LPCXpresso RedlinkMulti Driver v7.9 (Aug 11 2015 15:47:21 - crt_emu_cm_redlink.exe build 486)
Pc: (  0) Reading remote configuration
Nc: Found chip XML file in D:/Sync/Nxp/workspace/mc_sa_blinky_m0app/Debug/LPC4370-M0.xml

Pc: (  5) Remote configuration complete
Wc: ============= SCRIPT: LPC18LPC43ExternalFLASHBootResetscript.scp =============
Wc: Boot from FLASH image pc/sp reset script
Wc: PC = 0x00000001
Wc: SP = 0x00000000
Wc: XPSR = 0x00000000
Wc: VTOR = 0x00000000
Wc: ============= END SCRIPT =====================================================
Xe:
Nc: Probe Firmware: LPC-LINK2 CMSIS-DAP V5.112 (NXP Semiconductors)
Nc: VID:PID:  1FC9:0090
Nc: USB Path: \\?\hid#vid_1fc9&pid_0090&mi_00#7&29a525a&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
Pc: ( 30) Emulator Connected
Xc:
Pc: ( 40) Debug Halt
Pc: ( 50) CPU ID
Nc: Emu(0): Connected&Reset. DpID: 2BA01477. CpuID: 410FC240. Info: <None>
Nc: Debug protocol: SWD. RTCK: Disabled. Vector catch: Disabled.
Nc: loaded v.2 External Flash Device on SPI D:\nxp\LPCXpresso_7.9.2_493\lpcxpresso\bin\Flash\LPC18_43_SPIFI_16MB_64KB.cfx
Nc: image 'LPC18/43 16MB(64KB) SPIFI Aug 11 2015 16:54:12'
Pc: ( 65) Chip Setup Complete
Nt: Connected: was_reset=true. was_stopped=true
Cr:v LPCXpresso Free License - Download limit is 256K
Pc: ( 70) License Check Complete
Nt: Loading ELF file 'mc_sa_blinky_m0sub.axf' at location 14020000
Nc: AFTER driver startup timeout
Wc: Driver Register State
Wc:  R0:     10089000
Wc:  R1:     00000000
Wc:  R2:     00000000
Wc:  R3:     00000000
Wc:  R4:     00000000
Wc:  R5:     00000000
Wc:  R6:     00000000
Wc:  R7:     00000000
Wc:  R8:     00000000
Wc:  R9:     00000000
Wc:  R10:    00000000
Wc:  R11:    00000000
Wc:  R12:    00000000
Wc:  SP:     10080FE0
Wc:  LR:     FFFFFFF9 (exception from main thread)
Wc:  PC:     0F0E0D0C
Wc:  xPSR:   00000003
Wc:  MSP:    10080FE0
Wc:  PSP:    10081000
Wc:  CFBP:   00000001
Wc:Exception information:
Wc:10080FFC:  xPSR:   00000000
Wc:10080FF8:  VECTPC: 10000034
Wc:10080FF4:  LR:     10000035
Wc:10080FF0:  R12:    00000000
Wc:10080FEC:  R3:     00000000
Wc:10080FE8:  R2:     00000000
Wc:10080FE4:  R1:     00000000
Wc:10080FE0:  R0:     10089000
Wc:E000ED04:  ICSR:   00400803 (ISRPEND, VECTPEND=0, RETTOBASE, VECTACTIVE=3)
Wc:E000ED38:  BFAR:   E000EDF8
Wc:E000ED28:  CFSR:   00020000
Wc:E000ED2C:  HFSR:   40000000 ()
Wc:E000ED30:  DFSR:   00000000
Wc:E000ED3C:  AFSR:   00000000
Wc:E000ED24:  SHCSR:  00000000

Nc: Flash Driver V.2 startup failed - rc Ef(34): Timed-out initializing flash.
Pb: (100) Writing Flash ended with an error.
Ed:05: File 'mc_sa_blinky_m0sub.axf' load failure: Ef(34): Timed-out initializing flash.
Pc: (100) Target Connection Failed
0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by vtw.433e on Sun Nov 15 08:54:31 MST 2015
I think you have a misunderstanding on how this works. Suggest you read these FAQs
https://www.lpcware.com/content/faq/how-run-multicore-examples-provided-lpcopen-lpc43xx-packages
https://www.lpcware.com/content/faq/lpcxpresso/lpc43xx-multicore-apps
0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SoftFace2 on Sat Nov 14 14:36:23 MST 2015
I have now 2 LPC-LINK2 + labtool board.
To make a basic tests I use one as debugger probe and another one as a target
On the debugger probe JP2 is closed.
On the other LPC-Link2 target board JP1 is closed.
JP7 from debug probe is connected to J2 on target board.
I used basic examples provided with LPCXpresso IDEv7.9.2 namely mc_sa_blinky_m4, mc_sa_blinky_m0sub, and mc_sa_blinky_m0app respectively loaded on the good target (I guess) : .._m4 in 0 device cortex m4 (close to -->TD0) , ..m0app in 1 device cortex m0 and ..m0sub in 2 device cortex m0 (close to <--TDI) as explain in documentation.
The debugger seems to be active but “no source available for “0x0” is displayed on the LCPXpresso and I can’t understand why.
Probably this is a basic problem but I confess that I little bit lost with the huge amount of documentation everywhere.
I tried this one https://www.lpcware.com/content/faq/lpcxpresso/using-lpclink2-as-lpc4370-eval but it doesn’t work because a missing include file (LPC43xx.h)and is not clearly explain the target core to be used.
If some knows a place where I can find a step by step procedure to go from the hardware to software with a very basic program (for dummies) that would be very useful for a beginner like me.
Typically connected 2 LPC-Link2 one debugger probe and another one mounted as target use a very simple program, push this program on the target and start a debug session with breakpoint.
I’m a bit frustrated because I think this product should meet my requirement especially the fast ADC 12 bits. I spend many hours without result.

0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SoftFace2 on Tue Nov 10 11:49:17 MST 2015
Ok thanks a lot it's completely clear now, I will buy another LPC-Link2 board.
It's terrible to think that I spent many hours for that.
May be I'm not smart enough (probably), may be the documentation is not clear enough one this fundamental basic point.
In any case thanks a lot for your help.

0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by vtw.433e on Tue Nov 10 02:39:29 MST 2015
If you are trying to debug the Labtool, you need 2 lpc-link2 boards. One connected to the PC to act as the debug probe and the other one being the Labtool. When used as a Labtool, the lpc4370 is running the Labtool firmware and cannot be used to debug (itself) at the same time
0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SoftFace2 on Tue Nov 10 02:22:48 MST 2015
Thanks a lot for your replies,
Just to put appart the potential problem with PC I made these operation with 2 differents OS, with different USB port.
Some additionnal information about the Labtool kit the jumper JP1 and JP2 are unconnected (open).

I read the booting LPC-Link2, starting from this post I made the following operation:

  1 ) I plug for the first type the LabTool board I get the same Icon that  this shown on this post with LPC written below. In this case this identification is usb\vid_1fc9&pid_000c.

  2 ) I boot on it using the "boot debug probe" command on the LPCXpresso v7.9.2 the previous text "LPC" is replace by "LPC-LINK2 CMSIS-DAP V5.112" then the red LED located on LPC_Link2 blink. In this situation the text below icon on windows panel is "LPC-LINK2 CMSIS-DAP V5.112"

  3 ) I start debug session on LPCXpresso.
      - A dialog box "Connect to emulator : NXP LPC43xx" appears asking me to select the following device
               Emulator family : CMSIS_DAP/NAME : LPC-LINK2 CMSIS-DAP V5.112/Serial Number/ID : \\?\hid#vid_1fc9&pid_0090&mi_00#8..../Manufacturer : NXP Semiconductors
      - Another dialog box then come up to select JTAG or SWD  (I let the default value "JTAG")
           then a message appears which indicate that 0 JTAG device is detected

At this stage it is not possible to reconnect I get "Failed to connect" each time I try again. Complete message can be shown below lib MSG1.
after all these operations Nothing can be done to bring me back in N°3 of the described previous stage. I tried to close application, unplugged Labtool board, change USB port without good result.
It is a nightmare for me I can't understand. Is someone has already used this board LabTool (LPC4370) with LPCXpresso v7.9.2. If so could you give me your hardaware and software configuration?
Thanks for your help

MSG1:
[color=#c33]               Error in final launch sequence
              Failed to execute MI command:
    -target-select extended-remote | crt_emu_cm_redlink -msg-port=59260 -g -mi -2 -pLPC4370 -vendor=NXP -ResetScript=LPC18LPC43ExternalFLASHBootResetscript.scp -reset= -   ProbeHandle=1 -CoreIndex=0 -cache=disable -flash-driver=LPC18_43_SPIFI_16MB_64KB.cfx -x C:/Sync/Nxp/mc_sa_blinky_m4/Debug
             Error message from debugger back end:
            Remote communication error.  Target disconnected.: No error.
            Remote communication error.  Target disconnected.: No error.
[/color]




0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by LessThanZero on Sun Nov 08 22:42:04 MST 2015

Did you read this FAQ?

Booting LPC-Link2

Do you see the LPC device when you first connect a USB cable to the Link2? If not, the board is probably not jumped to DFU. Perhaps CMSIS-DAP is already programmed into flash. Once you see a CMSIS-DAP connected device, check the process list to make certain you have no orphaned redlinkserv.exe processes before starting a debug session. Last check your USB and JTAG/SWD cables.

LessThanZero
0 Kudos

868 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by vtw.433e on Sun Nov 08 15:16:24 MST 2015
Try a different (USB 2) port.
0 Kudos