OpenSDA port error when IDE debugging

cancel
Showing results for 
Search instead for 
Did you mean: 

OpenSDA port error when IDE debugging

861 Views
hedj
Contributor I

OpenSDA_error.PNG

When I tried to debug my app using MCUXpresso IDE, I have this error.

My board is MK22FN512VLH12.

In my device manager, I can see a "OpenSDA CDC serial port".

Can anyone tell me what went wrong?

Labels (1)
0 Kudos
15 Replies

499 Views
lpcxpresso_supp
NXP Employee
NXP Employee

Some older Kinetis boards ship appear to ship with OpenSDA firmware supporting P&E VCOM but with no actual debug support. I suspect that this is what you have.

To update this firmware, please visit the OpenSDA Firmware Update pages linked to within the IDE menu:

  • Help -> Additional Resources -> OpenSDA Firmware Updates

Regards,

MCUXpresso IDE Support

0 Kudos

499 Views
hedj
Contributor I

pastedImage_2.png

My IDE (v11.0.1 [Build 2563] [2019-09-01]) shows me the above choices.

By clicking "OpenSDA probe firmware", I was redirected to a web page "OpenSDA Serial and Debug Adapter | NXP ". But I cannot find my board in the drop down list.

pastedImage_4.png

0 Kudos

499 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi,

K22 please use TWR-K22F120 or FRDM-K22F.

pastedImage_1.png

Regards,

Jing

0 Kudos

499 Views
hedj
Contributor I

Now when I connect the board to my computer through USB, what I get is a "maintenance" drive; however I don't get COM port; and I still cannot debug with MCUxpresso. 

In the drive, there are two files: details.txt and help_faq.html.

the content of details.txt is as follows:

# DAPLink Firmware - see https://mbed.com/daplink
Unique ID: 0000000034544e45005f00028aa900282011000097969900
HIC ID: 97969900
Auto Reset: 0
Automation allowed: 1
Overflow detection: 0
Daplink Mode: Bootloader
Bootloader Version: 0244
Git SHA: d3095115fcc01da408dc6f9663596d69a4d4959d
Local Mods: 0
USB Interfaces: MSD
Bootloader CRC: 0xbd0abee1
Interface CRC: 0x308c203a
Remount count: 0

How can I get the serial port to work??

0 Kudos

499 Views
ErichS
Senior Contributor III

If the board shows up with 'maintenance', it is in bootloader mode. This means you have not loaded the debug (Segger, P&E or CMSIS-DAP) firmware to it?

In order to debug the board and to have a VCOM, you need a debug firmware loaded.

See Illustrated Step-by-Step Instructions: Updating the Freescale Freedom Board Firmware | MCU on Eclips...  if you are not familiar with the process.

I hope this helps,

Erich

0 Kudos

499 Views
hedj
Contributor I

I use MCUXpresso to launch J-Link Segger GDB server; however there is connection error:

Error in final launch sequence:

Failed to execute MI command:
-target-select remote localhost:2331

Error message from debugger back end:
localhost:2331: No connection could be made because the target machine actively refused it.
Failed to execute MI command:
-target-select remote localhost:2331

Error message from debugger back end:
localhost:2331: No connection could be made because the target machine actively refused it.
localhost:2331: No connection could be made because the target machine actively refused it.

0 Kudos

499 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi,

You can download a jlink tool (JLink_Windows_Vxxx.exe) from https://www.segger.com/downloads/jlink/JLink_Windows.exe 

It is the driver and tool that can test and control jlink interface.

Regards,

Jing

0 Kudos

499 Views
hedj
Contributor I

pastedImage_1.png

I downloaded and tried to use the J-Link app to connect to the board, got similar error.

0 Kudos

499 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi,

In j-link commander, please try "unlock kinetis".

If it can't work, please try "connect". Then follow it step by step.

Regards,

Jing

0 Kudos

499 Views
hedj
Contributor I

when I run J-Link command, I was prompted with this: 

pastedImage_3.png

what is the IP address I shall put in?

0 Kudos

499 Views
hedj
Contributor I

I also ran into this:

pastedImage_2.png

Is there something wrong with my board?

0 Kudos

499 Views
converse
Senior Contributor V

Mk22 (and any other Cortex-M device) does not support JTAG. You must use SWD instead.

0 Kudos

499 Views
hedj
Contributor I

pastedImage_1.png

SWD also failed

0 Kudos

499 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi,

This is maybe a hardware issue or the chip is locked. Please refer to below link

Communication error while accessing MDM-AP. 

Communication error while accessing MDM-AP 

If everything fails - the soldering iron is only option. 

Regards,

Jing

0 Kudos

499 Views
hedj
Contributor I

I managed to get a JLink CDD UART port by copying Jlink_OpenSDA_V2_1.bin into the maintenance drive; after that the drive name becomes FRDM-k22FJ. I want to use MCUXpresso to flash my app firmware into the board, please suggest what I should do. 

Many thanks.

0 Kudos