You copied the Doc URL to your clipboard.

How can I use the ULINK adapter to collect the debug log in Arm DS?

Information in this article applies to:

  • Arm Development Studio

Problem/Question

How can I use the ULINK adapter to collect the debug log in Arm DS?

Scenario

When using the ULINK adapter to debug target in Arm DS, users might encounter problems connecting to their target, timeouts, or autodetection failures.

To diagnose connectivity issues, users want to record Debug Access Port (DAP) register transactions between ULINK and CoreSight targets, and store the transactions into a text file. Users wonder how they can use the ULINK adapter to collect the debug log in Arm DS.

Answer

Follow these steps to collect the debug log in Arm DS:

  1. Upgrade your Arm DS to the version Arm DS 2019.1 or later versions.
    The ULINKpro log feature was introduced in Arm DS 2019.1.
  2. Close Arm DS before setting environment variables.
  3. Specify the following environment variables to enable the log capture:
  • DS_DEBUGSERVER_LOGFILE

The environment variable specifies the log file path. No intermediate directories are created when the log file is created. You must set it to a path that already exists in your system.

  • DS_DEBUGSERVER_LOGLEVEL

The environment variable sets the debug level for the log. The value can be OFF, INFO WARN, ERROR, DEBUG, TRACE. You can set it to the INFO level, which provides a quicker experience than other values.

  • RVILOG_STYLE

The console view of the DS does not process ANSI escape characters. Therefore, you can disable the ANSI escape characters by setting the environment variable to avoid the unreadable code.

For example, you can set the three environment variables as you can see here:

  • DS_DEBUGSERVER_LOGFILE=C:\Temp\ulink.txt

  • DS_DEBUGSERVER_LOGLEVEL=INFO

  • RVILOG_STYLE=STANDARD

After you set the three environment variables and debug again, the target console in Arm DS displays the following information:

```

Starting debug server

Waiting for debug server to start accepting connections

Debug server started successfully

```
  • Reproduce the failing scenario with Arm DS. For example, you can attempt to connect if a connection failure is the issue under investigation.
  • Go to the folder that stores the log file, compress the generated log file to the ZIP format, and send the file to Arm Support at Support-software@arm.com for investigation.
  • If you use the DSTREAM family, you can use the DAP logger tool to record the DAP register transactions between DSTREAM probe and CoreSight targets. For details about the steps to follow, see How to use the DAP logger tool.

    Workaround

    N/A

    Example

    N/A

    Related Information

    N/A