lpc5516 cannot be debugged twice

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

lpc5516 cannot be debugged twice

388 Views
Jesus92
Contributor I

Hi, I am using the lpc5516 on a custom board, I am using the SWDIO pins to program my lpc5516 but I am only able to program once, after that I am not able to program again but my code is still working, I create my code using MCUXpresso configuration tools to configure my lpc to 150MHz, the code is working fine even if I am not able to reprogram it again, I tried to use ISP mode but I have not been successful, I can't reprogram.

The same code works well and can be reprogramed without problems in the evaluation board LPC55S16-EVK (Using LinkServer Debug), the only difference is the LPC55S16 that use the evaluation board with my LPC5516 and my programmer that is Multilink Universal FX.

I am using:

MCUXpresso IDE v11.8.1_1197 (SDK_2.x_LPC55S16, Version 2.14.0)
Multilink Universal FX (To program the lpc)
[LPC5516JDBD100
TR7XB205.000 01
sSD24140A]

Can you give me some direction or some idea of ​​what might be happening?

SWDIO.png

If I change the microcontroller, it will be programmed only once or twice. The error that appears is: 
SWDIO1.pngSWDIO2.png
Thanks

0 Kudos
Reply
5 Replies

354 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @Jesus92 


Please try the following possible reasons and solutions。

1. Program a simple hello world or led SDK demo to test.

2. "I tried to use ISP mode but I have not been successful, I can't reprogram."

->> Please describe your detail steps about using ISP mode. Still unable to program after erase by ISP mode?

3. How abut using another debugger to test?

 

BR

Alice

0 Kudos
Reply

339 Views
Jesus92
Contributor I

I programmed a simple example of an LED and I had no problems, when I programmed my code which was generated by MCUXpresso Config Tools is when I could not program again, doing tests I changed the micro and commented the FLEXCOMM0_UART_Init() function; after commenting it I have been able to reprogram many times, when uncommenting it and programming is when I can no longer program again. I try to enter ISP mode by pulling pin 88 to ground to try to program again but I have not been successful. Is it possible that a bad code blocks the reprogramming with my Universal Multilink? I have not moved registers corresponding to the debug or the SWDIO pins.

Jesus92_0-1723817154924.png

Jesus92_1-1723817166983.png

 

What I find strange is that even though I can't reprogram, the code works, that is, I can transmit at the baudrate I configured and I can receive the data in my interrupt, I used the oscilloscope to make sure that FLEXCOMM0 was working properly. I will configure everything without using MCUXpress Config tools and I will do some tests, maybe I have something wrong.

is there any way to recover my microcontroller? Even with pin 88 (ISP Mode) grounded i can't reprogram it again.

Thanks.

 

0 Kudos
Reply

305 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @Jesus92 

Thanks for your reply.

What is the whole part number of your chip?

Please choose the right MCU (includes part number and package) when using MCUXpresso Config Tools .

 

BR

Alice

0 Kudos
Reply

266 Views
Jesus92
Contributor I
What is the whole part number of your chip? -->
| LPC5516JDBD100 |
| TR7XB205.000 01 |
| sSD24140A |

Please choose the right MCU (includes part number and package) when using MCUXpresso Config Tools.
---> I Select the SDK for the evaluation board, the only difference is the letter S, the code should work for both, the manual documentation handles both LPC55S1x/LPC551x

Is there any way to recover my chip, ISP mode does not work for me to recover it (Place pin 88 to ground) using Universal Multilink?

Today i will reprogram but configuring without MCUXpresso Config Tools.

Thanks.
0 Kudos
Reply

241 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @Jesus92 

1> "Is there any way to recover my chip, "

->>Yes, you can use ISP mode. It is no need any debugger in ISP mode. Just low the pin PIO0_5 (pin 88), then using UART or usb port to erase flash. The tool on PC you can use Flash Magic.

Another method is using MCUXpesso IDE, pressing ISP pin (pio0_5) when reset. Pay attention DO NOT release ISP pin.  Then using GUI Flash Tool inside MCUXpresso to erase. 

Alice_Yang_0-1724381993381.png

2> If you create a new project, please choose LPC5516. If you import a SDK demo for lpc55S16, you can try to change the chip to LPC5516 as below.

Alice_Yang_1-1724383858256.png

Alice_Yang_2-1724383905971.png

 

BR

Alice

 

 

 

 

 

0 Kudos
Reply