You copied the Doc URL to your clipboard.

How to use the DAP logger tool

Article ID: 103489827

Published date: 25 Aug 2017

Last updated: -

Applies to: DS-5 Development Studio , DSTREAM

Question

How can I use the DAP logger tool?

Answer

You can use the DAP Logger tool to record DAP register transactions between DSTREAM/RealView ICE and CoreSight targets. The transactions can be logged to a text file, which can be very helpful when diagnosing connectivity issues.

If you are experiencing problems with connecting to your target, time outs, autodetection failures (using Platform Configuration Editor), or even trace issues, a DAP log can provide invaluable information to our Support Engineers.

 

Note: The DAP Logger does not support the ULINK family of devices.

Steps for all DS-5 versions:

A) Power cycle the target and the DSTREAM/RVI unit.

B) Start the DAP logging process by following the instructions that follow for your version of DS-5:

For DS-5 v5.26 and later versions:

Open a command line interface and navigate to your DS-5 installation folder's bin directory. The default installation directory is typically 'C:\Program Files\DS-5 v5.26.2\bin'

Issue either of the two following commands depending on your DSTREAM/RVI-to-PC connection type:

For USB connection:

C:\Program Files\DS-5 v5.26.2\bin> dbghw_log_client -daplog full -logfile C:\temp\dstream.log USB

For Ethernet connection (aaa.bbb.ccc.ddd is the DSTREAM/RVI TCP/IP address):

C:\Program Files\DS-5 v5.26.2\bin> dbghw_log_client -daplog full -logfile C:\temp\dstream.log TCP:aaa.bbb.ccc.ddd

Continue from Step C.

For DS-5 v5.19 to v5.25:

Open a command line interface and navigate to your DS-5 installation folder's bin directory. The default installation directory is typically 'C:\Program Files\DS-5 v5.25.0\bin'

Issue either of the two following commands depending on your DSTREAM/RVI-to-PC connection type:

For USB connection (nnnnnnnn is the DSTREAM/RVI USB number):

C:\Program Files\DS-5 v5.25.0\bin> dbghw_log_client -daplog full USB:nnnnnnnn
C:\Program Files\DS-5 v5.25.0\bin> dbghw_log_client USB:nnnnnnnn > C:\temp\dstream.log

For Ethernet connection (aaa.bbb.ccc.ddd is the DSTREAM/RVI TCP/IP address):

C:\Program Files\DS-5 v5.25.0\bin> dbghw_log_client -daplog full TCP:aaa.bbb.ccc.ddd
C:\Program Files\DS-5 v5.25.0\bin> dbghw_log_client TCP:aaa.bbb.ccc.ddd > C:\temp\dstream.log

Continue from step C.


C) Recreate the failing scenario with DS-5 (for example, attempt to connect if that is the issue under investigation).

D) Exit the logging application by pressing CTRL-C in the command window.

E) Zip the resulting log file and send to ARM Support for investigation.

F) Power-cycle the DSTREAM/RVI.

Modifying the debug acceleration level:

Note: It is not necessary to perform this task unless an ARM Support representative has asked you to perform it.

Note: This does not apply to:

  • Any Cortex-M class cores.
  • Cores on the JTAG-AP.
  • Any ARMv8 Architecture cores.

Because of optimizations at the DSTREAM/RVI level, some extra modification on the platform support files for the target might be necessary before the DAP Logger can show relevant transactions. These changes ensure that DAP accesses are not optimized and the full detail is displayed.

1. Locate the Debug Configuration entry for your target.

2. Copy the debug configuration files (.rvc, .rcf, .py, .xml files) to a new folder located in the same top directory structure, and append "with_logging" to the name of the folder.

3. Use a text editor to open up the .rvc file. If there is no .rvc file, open the .rcf file instead.

4. For .rvc: Locate and modify the string:

<DEBUG_ACCEL Type = "Str">0</DEBUG_ACCEL>

to the following:

<DEBUG_ACCEL Type = "Str">2</DEBUG_ACCEL>  



For .rcf: Locate the core (or cores) that you will be connecting to, and add the line:

     <config_item name="DEBUG_ACCEL">2</config_item>  

under <config_items>

For example:
                   <device name="Cortex-A15" type="Cortex-A15">
            <config_items>
                <config_item name="CORESIGHT_BASE_ADDRESS">0x80001000</config_item>
                <config_item name="CORESIGHT_AP_INDEX">0</config_item>
                <config_item name="DEBUG_ACCEL">2</config_item>

5. Save the changes you made.    

6. Start DS-5, select Window -> Preferences -> DS-5 -> Configuration Database, click the Rebuild database button, click Apply button, and click OK

Your configuration database rebuilds to include the new configuration you have created.

Perform steps A to F at the beginning of this article to record a DAP log. Make sure you connect to your target at step C using this new debug configuration with the modified acceleration level.  

Related information

Was this page helpful? Yes No