Segger Logo Embedded Software Solutions
Software productsHardware productsDownloadsPricesCustomersOur PartnersSitemapForumAbout us
J-Link GDB Server
| J-Link software overview | J-Link General Information | Performance comparison | USB driver installation | J-Mem | J-Link DLL | Flash programming overview | J-Flash ARM | Flash SDK | Using J-Link with IAR "C"-Spy | ARM-RDI | ARM-RDI-Flash BPs | JTAG Isolator | J-Link Adapters | Troubleshooting | J-Link FAQs | J-Link Pricing | GDB Server |

The J-Link GDB Server is a remote server for the GDB. The GDB and GDB Server communicate via a TCP/IP connection, using the standard GDB remote serial protocol. The GDB Server translates the GDB monitor commands into J-Link commands.

GDB / GDB Server overview

The GNU Project Debugger (GDB) is a freely available debugger, distributed under the terms of the GPL. It connects to an emulator via a TCP/IP connection. It can connect to every emulator for which a GDB server software is available. The latest Unix version of the GDB is freely available from the GNU commitee under: http://www.gnu.org/software/gdb/download/

Hardware requirements

To use the J-Link GDB Server, you have to meet the following hardware requirements:

  • PC running Win2K / XP
  • USB port
  • J-Link / J-Trace

User interface

The J-Link GDB Server's user interface shows information about the debugging process and the target connected via JTAG.

It shows:

  • host IP address, that is connected to the J-Link GDB Server
  • connection status of J-Link
  • information about the target core
  • measured target voltage
  • bytes that have been downloaded
  • status of target
  • log output of the J-Link GDB Server (optional, if log window is checked)
  • initial and current JTAG speed
  • target endianess

If a J-Link and target system is connected, the J-Link GDB Server should look similar to the following screen shot:

Setting up the J-Link GDB Server

Typically, most of the GDB setup is done from GDB via remote commands (monitor) in the ".gdbinit" file. However it is also possible to do the setup manually via user interface:

Via the JTAG speed drop down box the JTAG speed can be selected and with the box below the endianess of the target can be set. These two boxes will be grayed out while debugging, although their values can be changed from the debugger console using remote commands.

Log window

The log window is only visible if the checkbox Log window is selected. The log window shows all commands which the GDB sends to the GDB Server. The log window is primarily usefull for troubleshooting.

Log file

If log to file is checked, the GDB Server generates the log file C:\JLinkGDB.log.

Supported remote commands

J-Link GDB Server supports several remote commands from the GDB. This commands can be used from within a gdbinit file or the GDB console to initialize the target board and to setup J-Link GDB Server specific parameters.

Remote command Explanation
ClrBP Removes an instruction breakpoint.
Endian Sets endianess of the target.
Go Starts the target CPU.
Halt Halts the target CPU.
JTAGConf Configures a JTAG scan chain with multiple devices on it.
Long Reads or writes from/to given address.
Reg Reads or writes from/to given register.
Reset Resets and halts the target CPU.
Select Selects the way J-Link is connected to host system.
SetBP Sets an instruction breakpoint at a given address.
Sleep Sleeps for a given time period.
Speed Sets the JTAG speed of J-Link / J-Trace.
Step Performs one or more single instruction steps.
WaitHalt Waits for target to halt code execution.
WIce Writes to given IceBreaker register.

Copyright SEGGER Microcontroller GmbH & Co.KG. All rights reserved.
For more information, please visit our web site www.segger.com or contact us at info@segger.com
Last update: January 8, 2008