Unable to Connect to Target

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

Unable to Connect to Target

3,005 Views
munjal
Contributor II

I am using LPC54606J512BD100 microcontroller and facing a very serious issue.

The issue is that after successful programming the controller and working at random time I am unable to upload the code again and getting error.

 

Regarding Programming board:

Using LPC-Link 2 Rev B (https://www.nxp.com/design/software/development-software/mcuxpresso-software-and-tools-/lpc-link2:OM...) debug board for programming.

Tried in CMSIS-DAP and J-Link (SW) mode.

Board Connection:

  • JP1 - Closed
  • JP2 - Open
  • Using J6 Connector (1 - V_REF, 2 - SWDIO, 3 - SWCLK, 6 - RESET, 8 - GND)

 

Regarding Controller LPC54606J512BD100:

PIO0_2 to PIO0_6 are left unconnected.

 

Regarding IDE:

I am using Keil uVision5.

 

I need help as I am unable to program the microcontroller. Please let me know if any further detail is required if any.

Labels (1)
0 Kudos
13 Replies

2,955 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi munjal 

1. Why don't use use LPC-Link2 J7 as debug interface? Please try J7 debug interface instead.

2. refer attached video, if Jlink commander can detect LPC Core?

3. If 2 fails, Please use LPCScypt update LPC-Link2 firmware, try both CMSIS-DAP and Jlink interface respectively, to make sure LPC-Link2 onboard firmware no issue.

4. If 2 detects LPC core successfully, try to use MCUXpresso IDE to test the connect, MCUXpresso IDE can detect debug interface automatically without other setting.

5. Is your LPC54608 board custom designed PCB? If yes, refer this article to check the interface design

https://community.nxp.com/t5/LPCXpresso-IDE-FAQs/Design-Considerations-for-Debug/m-p/469565#M44

 

Thanks,

Jun Zhang

 

 

 

 

0 Kudos

2,944 Views
munjal
Contributor II

Hi @ZhangJennie 

Earlier the board design was using the J7 connector only and there were multiple issue. At that time we were using MCUXpresso and we were getting the same issue with different error name as wire ack fault in dap access. Also the connector was not reliable and broke more often. Then as per the discussion with NXP FAE we switched to using J6 and after 3 months of working with the same hardware and configuration this issue has came again were the controller's are working with the existing code but we are unable to program the new one code. FAE visited our site and no permanent or proper solution were provided. We have almost changed around 50+ controller with the same issue and now it is becoming pain. Need help to identify the problem whether in hardware/Microcontroller/Debugger or in Driver.

0 Kudos

2,935 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

From your description, I wonder your custom board SWD design could have problem.

Again, please follow this article to check SWD design. Or post your SWD design here, I will help to check.

Thanks,

Jun Zhang

0 Kudos

2,919 Views
munjal
Contributor II

I have attached the image of the custom board circuit. In this all the pin's that are not mentioned are used as inputs and outputs. Please suggest if there is any problem. Also while programming 3.3V is given externally to the controller.

0 Kudos

2,887 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

HI

There is problem on your reset circuit design

ZhangJennie_0-1685600463862.png

 

please use RC circuit to produce reset . suggest R=100kΩ, C=0.1~1uF

Thanks,

Jun Zhang

0 Kudos

2,882 Views
munjal
Contributor II

The 100nF capacitor was added after the FAE suggested.

Earlier we were not using this. Only there was a power on Reset circuitry that was in use.

0 Kudos

2,872 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

So in your reset circuit, R=1K, C=0.1uF?

0 Kudos

2,866 Views
munjal
Contributor II

Yes, this is used at power on basically.

0 Kudos

2,835 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

The value of R*C is not enough. 

Please try combination of R=100kΩ, C=0.1uF to make reset low longer.

Thanks,

Jun Zhang

0 Kudos

2,755 Views
munjal
Contributor II

Tried with the combination no luck, still unable to program the controller with the issue.

0 Kudos

2,738 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi

To identify the problem is caused by IDE or driver, please update LPC-Link firmwire to Jlink.Then refer attached video, if Jlink commander can detect LPC Core?

Thanks,

Jun Zhang

0 Kudos

2,731 Views
munjal
Contributor II

Tried with the JLink Commander and in this it was not able to connect and displayed the message Connect under reset failed. At this time one of the SWDIO or SWCLK is low.

Also In some controller was successfully able to establish core connection.

                                         Performed Following
Board (with microcontroller)External Supply (3.3V)ProgrammerOutput/Controller Programmed
Board Connected with 10K pullup on CLK and SWDIO pinGiven to boardJP2 OpenFail
Board Connected with 10K pullup on CLK and SWDIO pinNot GivenJP2 OpenFail
Board Connected with 10K pullup on CLK and SWDIO pinNot GivenJP2 CloseFail
Board Connected with 10K pullup on CLK and SWDIO pinGiven to boardJP2 CloseFail
Board Connected with no pullup on CLK and SWDIO pinGiven to boardJP2 OpenFail
Board Connected with no pullup on CLK and SWDIO pinNot GivenJP2 OpenFail
Board Connected with no pullup on CLK and SWDIO pinNot GivenJP2 CloseFail
Board Connected with no pullup on CLK and SWDIO pinGiven to boardJP2 CloseFail

 

0 Kudos

2,667 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi munjal 

What's the persentage of "connection failure" boards?

Did you test the board with another emulator? like MCU-Link, Jlink? How is it?

Please test connectin in ISP mode, see if any change?

if still failed, pls upload a photo of Jlink commander error message. 

Thanks,

Jun Zhang

0 Kudos