Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Panel
bgColor#ffffff
titleQ

How to debug netX 90 application side with J-Link debug probe from SEGGER?

Panel
bgColor#ffffff
titleA

Table of Contents

Hilscher provides netX Studio CDT IDE (Integrated Development Environment) for customers for developing application software for the netX 90 SoC. The main goal is to provide an out-of-the-box working solution for building and debugging applications for the netX SoC. netX Studio CDT is provided to customers free of charge and aims to make it easy for them to evaluate netX as a platform for their custom designs. The software (https://kb.hilscher.com/display/NDT) and Documentation are available on Hilscher Knowledgebase(https://kb.hilscher.com/).

SEGGER's J-Link supports a wide range of CPUs and is very popular with some netX customers. Since SEGGER added support for netX 90, which allows customers to use the tools from the J-Link Software and Documentation Pack and the Ozone J-Link Debugger, we provide here a step-by-step guide for debugging the netX 90 application side with J-Link.

Prerequisites

Please use J-Link Software and Documentation Pack v7.60 or later.

The v7.60 release includes the following fixes for netX 90:

  • Hilscher NetX90 Com Core RAM base address for RAMCode was wrong. Fixed.
  • Hilscher NetX90 Com core reset and halt after bootloader handling, fixed.
  • Hilscher NetX90 Com core used software reset instead of reset pin toggling within reset routine. Fixed.

For use case B and use case C with an external SQI flash, please use J-Link Software and Documentation Pack v7.86c or later.

The v7.86c release includes the following new feature for netX 90:

  • Hilscher NetX90: Added SQI(QSPI) flash programming support.

J-Link support in netX Studio CDT

Currently, netX Studio CDT supports debugging with J-Link in one of the following two ways:

  • J-Link with OpenOCD (not recommended)
  • J-Link with GDB Server (not recommended)

Using J-Link with OpenOCD

In general, it is possible to use J-Link with OpenOCD, but it's not recommended due to the following main reason:

  • To use the J-Link debug probe with OpenOCD, you have to replace the original J-Link USB driver with WinUSB using a tool like Zadig.
  • It does not make use of any high level logic etc. and therefore is much slower than the proprietary SEGGER J-Link DLL / GDBServer / ... implementation.
  • Once the J-Link USB driver has been replaced, no SEGGER software from the J-Link software package will be able to communicate with J-Link anymore. To use SEGGER J-Link software again, the USB driver needs to be switched back to its default.

Please see further limitations and support from SEGGE: https://wiki.segger.com/OpenOCD

Using J-Link with GDB Server

netX Studio CDT supports debugging with a different GDB server backend than OpenOCD, e.g. SEGGER J-Link GDB Server. (Please refer to the attached example project, which has ready-to-use batch scripts for programming the flash and starting the gdb server etc by calling the batch file in the Terminal of netX Studio CDT.)

It's not recommended as well, since to use the full feature of J-Link Debugger, Ozone is supposed to be used. If you still want to use netX Studio CDT as a frontend, please note the following:

  • Start J-Link GDB Server (Run jlinkgdbserver_run.bat) before starting debugging in netX Studio CDT
  • Disable "Start OpenOCD automatically" in Debug Settings →Target Settings
  • Don't choose "Load image (gdb load)" if the application is running directly in internal flash (The NAI firmware must be flashed manually before debugging.)
  • Remote Target's "Host name or IP address" should be localhost and the Port number should be 3333.
  • To debug application on SDRAM, the SDRAM muss be available and configured correctly. (NXHX-SDRSPM extension board must be connected if NXHX 90-JTAG board is in use.)

Using J-Link with J-Link Debugger (Ozone)

Before debugging, the netX 90 internal flash needs to be programmed with the required files. See Using J-Flash to set up the netX 90 internal flash above.


References

Panel
bgColorwhite
titleBGColordefault
titleOverview netX 90 tutorials

Page Properties Report
showLabelsfalse
headingsAuthor, Date, Source
sortByDate
showSpacefalse
operatorAND
cqllabel = "netx_tutorials" and label = "netX_tutorials"
labelsapplication,netx52

Panel
bgColor#ffffff
titleSee also...

Filter by label (Content by label)
showLabelsfalse
spaces@self
showSpacefalse
cqllabel = "faq" and space = currentSpace()
labelsfaq