88
Hexagon Debugger 1 ©1989-2019 Lauterbach GmbH Hexagon Debugger TRACE32 Online Help TRACE32 Directory TRACE32 Index TRACE32 Documents ...................................................................................................................... ICD In-Circuit Debugger ................................................................................................................ Processor Architecture Manuals .............................................................................................. Hexagon ................................................................................................................................... Hexagon Debugger .............................................................................................................. 1 Brief Overview of Documents for New Users ................................................................. 5 Warning .............................................................................................................................. 6 Quick Start of the ICD Debugger for Hexagon ............................................................... 7 1. Hexagon Conceptual Basics 7 2. Prepare the Start 8 3. Select the Device Prompt for the ICD Debugger 8 4. Select the Clock for the JTAG Communication 8 5. Configure the Debugger According to the Needs of the Application 9 6. Enter Debug Mode 9 7. Load the Application 9 8. View the Source Code 9 9. Write a Start-up Script 10 Debugger Basics ............................................................................................................... 11 Memory Classes and Memory Access 11 Stack Display 11 Hexagon Security 11 Virtual Hardware Threads 12 Thread Compounds 12 Thread States 12 On-chip Breakpoints 13 Program Breakpoints 14 Read and Write Breakpoints 14 Data Breakpoints 14 Restrictions 14 Troubleshooting ................................................................................................................ 15 SYStem.Up Errors 15 FAQ ..................................................................................................................................... 16

Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

  • Upload
    others

  • View
    38

  • Download
    3

Embed Size (px)

Citation preview

Page 1: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Hexagon Debugger

TRACE32 Online Help

TRACE32 Directory

TRACE32 Index

TRACE32 Documents ......................................................................................................................

ICD In-Circuit Debugger ................................................................................................................

Processor Architecture Manuals ..............................................................................................

Hexagon ...................................................................................................................................

Hexagon Debugger .............................................................................................................. 1

Brief Overview of Documents for New Users ................................................................. 5

Warning .............................................................................................................................. 6

Quick Start of the ICD Debugger for Hexagon ............................................................... 7

1. Hexagon Conceptual Basics 7

2. Prepare the Start 8

3. Select the Device Prompt for the ICD Debugger 8

4. Select the Clock for the JTAG Communication 8

5. Configure the Debugger According to the Needs of the Application 9

6. Enter Debug Mode 9

7. Load the Application 9

8. View the Source Code 9

9. Write a Start-up Script 10

Debugger Basics ............................................................................................................... 11

Memory Classes and Memory Access 11

Stack Display 11

Hexagon Security 11

Virtual Hardware Threads 12

Thread Compounds 12

Thread States 12

On-chip Breakpoints 13

Program Breakpoints 14

Read and Write Breakpoints 14

Data Breakpoints 14

Restrictions 14

Troubleshooting ................................................................................................................ 15

SYStem.Up Errors 15

FAQ ..................................................................................................................................... 16

Hexagon Debugger 1 ©1989-2019 Lauterbach GmbH

Page 2: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CPU specific SYStem Settings ......................................................................................... 18

SYStem.CONFIG.state Display target configuration 18

SYStem.CONFIG Configure debugger according to target topology 19

<parameters> describing the “DebugPort” 26

<parameters> describing the “JTAG” scan chain and signal behavior 31

<parameters> describing a system level TAP “Multitap” 35

<parameters> configuring a CoreSight Debug Access Port “DAP” 37

<parameters> describing debug and trace “Components” 41

<parameters> which are “Deprecated” 51

SYStem.CONFIG MSA Enable translation by system MMU 55

SYStem.CPU Select CPU type 56

SYStem.CpuAccess Run-time CPU access (intrusive) 56

SYStem.JtagClock Select clock for JTAG communication 57

SYStem.LOCK Tristate the JTAG port 57

SYStem.MemAccess Run-time memory access (non-intrusive) 58

SYStem.Option MMUSPACES Separate address spaces by space IDs 58

SYStem.Mode Select target reset mode 60

SYStem.Option CPU specific commands 61

SYStem.Option BUGFIX Workaround for single-stepping an RTE instruction 61

SYStem.Option DCFREEZE Do not invalidate cache 61

SYStem.Option CLADE Enable debugger support for CLADE 62

SYStem.Option CLADEDICT Loade CLADE dictionary from file 62

SYStem.Option CLADEPARAM Define the CLADE address parameters 62

SYStem.Option CLADEREAD Use hardware for reading compressed RAM 63

SYStem.Option ICFLUSH Flush instruction cache at “Go” or “Step” 63

SYStem.Option IMASKASM Disable interrupts while single stepping 64

SYStem.Option IMASKHLL Disable interrupts while HLL single stepping 64

SYStem.Option ISDBSoftBreakFix Workaround for prefetch issue 65

SYStem.Option PC PC parking position 65

SYStem.RESetOut Reset target without reset of debug port 66

SYStem.Option REVision Define default value for REV register 66

SYStem.Option SRST Reset via SRST line 66

SYStem.StuffInstruction Execute stuff instruction 67

SYStem.Option TCMBase Base address of the TCM 67

SYStem.Option TLBINV Invalidate TLB while MMU is off 67

SYStem.state Display SYStem.state window 67

CPU specific MMU Commands ........................................................................................ 68

MMU.DUMP Page wise display of MMU translation table 68

MMU.List Compact display of MMU translation table 70

MMU.MAP Translations from ELF file memory load map 71

MMU.MAP.dump Display addresses from ELF file memory load map 71

MMU.MAP.SCAN Load MMU table from ELF file 71

MMU.SCAN Load MMU table from CPU 72

Hexagon Debugger 2 ©1989-2019 Lauterbach GmbH

Page 3: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

MMU.Set Write to MMU on processor 74

MMU.TLB Scan or dump MMU TLB entries 74

MMU.VTLB Scan or dump VTLB entries 75

CPU specific BenchMarkCounter Commands ................................................................ 76

BMC.COUNTER<n> Specify event count 76

BMC.CyclePeriod Specify export rate 77

BMC.OFF Disable benchmark counters 77

BMC.ON Enable benchmark counters 77

BMC.SELect Select counter for statistic analysis 77

BMC.SPDM Specify profiler control 78

BMC.SPLIT Specify export rate 79

TrOnchip Commands ........................................................................................................ 80

TrOnchip.ASID Extend on-chip breakpoint/trace filter by ASID 80

TrOnchip.ContextID Extend on-chip breakpoint/trace filter by TID 80

TrOnchip.CONVert Adjust on-chip breakpoint to resources 81

TrOnchip.MatchASID Extend on-chip breakpoint/trace filter by ASID 81

TrOnchip.RESet Reset “TrOnchip” settings 81

TrOnchip.StepException Single stepping of exceptions and interrupts 82

TrOnchip.state Display on-chip trigger window 82

JTAG Connector ................................................................................................................ 83

Mechanical Description of the 20-pin Debug Cable 83

Electrical Description of the 20-pin Debug Cable 84

Support ............................................................................................................................... 85

Available Tools 85

Compilers 85

Target Operating Systems 85

3rd-Party Tool Integration 86

Products ............................................................................................................................. 88

Product Information 88

Order Information 88

Hexagon Debugger 3 ©1989-2019 Lauterbach GmbH

Page 4: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Hexagon Debugger

Version 06-Nov-2019

Hexagon Debugger 4 ©1989-2019 Lauterbach GmbH

Page 5: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Brief Overview of Documents for New Users

Architecture-independent information:

• “Debugger Basics - Training” (training_debugger.pdf): Get familiar with the basic features of a TRACE32 debugger.

• “T32Start” (app_t32start.pdf): T32Start assists you in starting TRACE32 PowerView instances for different configurations of the debugger. T32Start is only available for Windows.

• “General Commands” (general_ref_<x>.pdf): Alphabetic list of debug commands.

Architecture-specific information:

• “Processor Architecture Manuals”: These manuals describe commands that are specific for the processor architecture supported by your debug cable. To access the manual for your processor architecture, proceed as follows:

- Choose Help menu > Processor Architecture Manual.

• “OS Awareness Manuals” (rtos_<os>.pdf): TRACE32 PowerView can be extended for operating system-aware debugging. The appropriate OS Awareness manual informs you how to enable the OS-aware debugging.

Hexagon Debugger 5 ©1989-2019 Lauterbach GmbH

Page 6: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Warning

WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the debug cable only while the target power is OFF.

Recommendation for the software start:

1. Disconnect the debug cable from the target while the target power is off.

2. Connect the host system, the TRACE32 hardware and the debug cable.

3. Power ON the TRACE32 hardware.

4. Start the TRACE32 software to load the debugger firmware.

5. Connect the debug cable to the target.

6. Switch the target power ON.

7. Configure your debugger e.g. via a start-up script.

Power down:

1. Switch off the target power.

2. Disconnect the debug cable from the target.

3. Close the TRACE32 software.

4. Power OFF the TRACE32 hardware.

Hexagon Debugger 6 ©1989-2019 Lauterbach GmbH

Page 7: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Quick Start of the ICD Debugger for Hexagon

This chapter should help you to prepare your Debugger for Hexagon. Depending on your application not all steps might be necessary. For some applications additional steps might be required that are not described in this Quick Start section.

1. Hexagon Conceptual Basics

Especially when starting to get familiar with the Hexagon architecture these points are of exceptional importance:

• Hexagon is a secure platform: by default, debugging is prohibited. Whether the user can debug a specific application or not is configured by the application which is executed.

If you write your own application, please consult the Hexagon documentation on how to enable debugging. If you are using a third-party application please contact the vendor of this application for a debug-enabled version.

• Beside from “debugging not allowed” there are two debugging levels:

- Untrusted debugging requires a debug monitor running under the control of the application and RTOS.

- Trusted debugging allows full control over the Hexagon core. See also Hexagon Security for more information on the Hexagon debug modes.

• Because the debugger does not have any access to the core by default, Hexagon needs to be configured via some external “instance”. Normally an ARM core is responsible for configuration and loading at least an initial application for enabling debugging. Please see the chipset’s documentation on how to do this.

So before being able to establish a debug communication, e.g. by a SYStem.Mode Up command, the following steps have to be performed:

1. Prepare an application that has debugging enabled (trusted mode debugging)

2. Configure the Hexagon core via the ARM core or debugger and load the application to the DSP.

3. After configuration, release the Hexagon core from reset (via ARM core) so the application can enable debugging.

4. Establish debug connection via the Hexagon debugger.

Hexagon Debugger 7 ©1989-2019 Lauterbach GmbH

Page 8: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

2. Prepare the Start

1. Connect the debug cable to your target. Check the orientation of the connector. Pin 1 of the debug cable is marked with a small triangle next to the nose of the target connector.

2. Power up your TRACE32 system.

3. Start the TRACE32 Debugger Software for Hexagon.

4. Power up your target.

On some target systems, Hexagon and its JTAG port may have to be enabled by the ARM core first. Please refer to the documentation of your target system and/or contact the manufacturer to obtain information on how this has to be done.

3. Select the Device Prompt for the ICD Debugger

On all TRACE32 tool configurations except for the emulator device B:: is already selected.

4. Select the Clock for the JTAG Communication

You can select the JTAG clock frequency which the Debugger uses to communicate with the target. This can be either done in the JtagClock field in the SYStem window, or by using the command line with the command SYStem.JtagClock. The maximum clock frequency depends on your target board design. The default clock frequency is 1 MHz.

Examples:

To prevent damage please take care to follow this sequence all the time you are preparing a start.

B:: ; Select device prompt

SYStem.JtagClock 3.0MHz ; Use 3 MHz as debug clock.

SYStem.JtagClock RTCK ; Use the return clock for; adjusting the debug clock.

Hexagon Debugger 8 ©1989-2019 Lauterbach GmbH

Page 9: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

5. Configure the Debugger According to the Needs of the Application

Most of the available settings can be configured with the SYStem window. Set the SYStem options in this window according to application program. The default values should be fine for most cases.

6. Enter Debug Mode

This command asserts a reset to the Hexagon core. After the reset is deasserted, the DSP will enter debug mode and start executing. When there is valid startup code which enables debugging, the core will stop at an built-in software breakpoint.

7. Load the Application

To load an image to the target, use command Data.Load.<file_format> <file>. The debugger supports various file formats:

On Hexagon platforms, the Hexagon code is normally loaded via an ARM core and not via the Hexagon debugger, so you will also need the following load options to load only the symbol information (see Data.Load for details):

8. View the Source Code

Use the command Data.List to view the source code at the location of the program counter.

SYStem.Option PC 0x0 ; Park PC at a save location; while thread is in debug mode.

SYStem.Up ; Enter debug mode.

Data.Load.ELF <file> /Verify ; Load application file in ELF format.

/NoCODE ; Do not load any code or data.

/NoReg ; Do not set registers.

Hexagon Debugger 9 ©1989-2019 Lauterbach GmbH

Page 10: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

9. Write a Start-up Script

Now the quick start is done. If you were successful you can start to debug. LAUTERBACH recommends that you prepare a start-up script (a PRACTICE file) to be able to do all the necessary actions with only one command. Here is a typical start sequence:

*) These commands open windows on the screen. The window position can be specified with the WinPOS command.

For information about how to build a start-up script (*.cmm file), refer to “Debugger Basics - Training” (training_debugger.pdf). There you can also find some information on basic actions with the debugger.

B:: ; Select the ICD device prompt.

WinCLEAR ; Clear all windows.

SYStem.Reset ; Set all options in the SYStem; window to default values.

SYStem.Up ; Reset the target and enter; debug mode.

Data.LOAD.ELF application.elf ; Load application from; object file (ELF file).

PER.view ; Show clearly arranged peripherals ; in window *)

Data.List ; Open disassembly window. *)

Register.view /SpotLight ; Open register window. *)

Var.Local ; Open window with local; variables. *)

Frame.view /Locals /Caller ; Open the stack frame with ; local variables *)

Var.Watch %Spotlight flags ast ; Open watch window for variables *)

Break.Set main ; Set software breakpoint to; address of symbol main.

Please keep in mind that only the Processor Architecture Manual (the document you are reading at the moment) is CPU specific, while all other parts of the online help are generic for all CPUs. So if there are questions related to the CPU the Processor Architecture Manual should be your first choice.

Hexagon Debugger 10 ©1989-2019 Lauterbach GmbH

Page 11: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Debugger Basics

This chapter provides an introduction into the Hexagon specific debugger basics.

Memory Classes and Memory Access

Prefixing an E as attribute to the memory class will make memory accesses possible even when the CPU is running. See SYStem.MemAccess and SYStem.CpuAccess for more information.

Stack Display

Hexagon has a stack which is displayed at the right side of the register window. When SP points to D:0x00000000 nothing is displayed.

Hexagon Security

Hexagon has three debug modes:

1. No debugging allowed.

2. Untrusted debug.

The debugger communicates with a debug monitor integrated in the kernel. This allows debugging of only a few resources, e.g. some dedicated user applications or tasks.

3. Trusted debug.

The debugger has full access and control over Hexagon.

TRACE32 only supports trusted debug.

The application running on the target selects the debug mode in its startup code. After this is done, a hard-coded software breakpoint will halt the DSP.

Memory Class Description

P: Program memory.

D: Data memory.

SD: Data memory using on-chip System MMU.

REG: Pseudo memory class for CPU Register set. No real-time access while CPU is running.

Hexagon Debugger 11 ©1989-2019 Lauterbach GmbH

Page 12: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Virtual Hardware Threads

The debugger supportsup to the eight virtual hardware threads, the real number of threads is decided after CPU selection or based onthe value of REVID register. The PowerView GUI only shows one thread at a time. Threads can be switched with the CORE command:

Currently all breakpoints take effect on all running threads: if only one thread breaks all other threads will also break. When a breakpoint is hit, PowerView will automatically switch to the thread responsible for the break. If more than one thread hits a breakpoint at the same time, it will switch to the thread with the lowest thread number. While single stepping no automatic thread switch is performed, even when a breakpoint is hit.

Thread Compounds

Threads can be assigned to a thread compound. If any of the Go, Step or Break command is executed to virtual hardware thread, the command is applied to all the threads in this compound simultaneously.

By default, all virtual hardware threads are assigned to the same thread compound. Only in very few and special cases it may be necessary to remove or add a thread to the thread compound by using the CORE command group.

Note that breakpoints - especially software breakpoints are always assigned to all virtual hardware threads, no matter whether a thread is assigned to a thread compound or not.

Thread States

The debugger displays the Hexagon’s current state in the status bar. Beside from the global states, e.g. Power Down or Reset, which are the same for all threads, each one can have its own state independently form the other states:

A thread may be in a special state where it can not be debugged. These states are special implementations of the running state. In these states a thread can not be debugged, also a Break command does not have any effect. Other threads or an SoC event may release the thread from its state.

CORE 2 ; switch to hardware thread 2.

stopped The thread is stopped for debug. The debugger can access memory, registers and peripherals.

running The thread is currently executing code. Memory, registers and peripherals can not be accessed. Program execution can be interrupted.

Hexagon Debugger 12 ©1989-2019 Lauterbach GmbH

Page 13: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

All these states are read from core- or thread internal status registers and not from any hardware signals. The SoC is basically available: in case of a core status the entire Hexagon is not enabled, in power down or reset by another SoC component. In case of a thread status only the specific thread is affected.

Refer to the Hexagon Architecture Documentation for more information on the modes and transitions.

On-chip Breakpoints

The Hexagon core supports two on-chip program breakpoints.

The Hexagon ETM supports up to 8 read-, write- or read/write (access) breakpoints on single addresses or 4 on ranges with the following restriction:

Hexagon ETM has 4 trigger units which can implement either one address range or up to two single addresses. Each range or single address can be programmed as read- or write breakpoint or combined read/write (access) breakpoint. An optional data condition (data breakpoint) can be added.

running(reset) The core reported to be in reset state.

running(pwr_down) The core (and register ISDBCST) is unreachable so we assume a power down mode.

running(no power) JTAG-AP of DAP controller not responding, we assume power down as reason

running(res/pwr_down) The core reported via ISDBCST register to be in reset or power collapse mode.

running(off) The thread is currently in OFF mode. This reflects the E-bit of the MODECTL register.

running(waiting) The thread is in WAIT mode, waiting to be resumed. This reflects the W-bit of the MODECTL register.

running(all_wait) All threads are in WAIT mode. The core may perform special power saving functions.

running(no_access) The debugger is unable to access the core or thread.

Hexagon Debugger 13 ©1989-2019 Lauterbach GmbH

Page 14: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Program Breakpoints

By default the In-Circuit Debugger for Hexagon uses software breakpoints to implement program breakpoints. Software breakpoint means that the code at the desired memory location is modified by the debugger to make the CPU break when the program counter hits this address. After a break the original contents of the memory location are restored.

Read and Write Breakpoints

Read or write breakpoints are set up as follows:

Data Breakpoints

Data breakpoints are set up as follows. Note that a data breakpoint always has to be combined with a read-, write or read/write breakpoint.

Restrictions

Break.Set P:0x00000012 ; Set a Software breakpoint.

Break.Set P:0x00000212 /Onchip ; Set an on-chip breakpoint.

Break.Set <symbol> ; Set a breakpoint to <symbol>.

Break.Set D:0x00000010 /Read ; Set a breakpoint on a read access; for a data address.

Break.Set D:0x00000212 /ReadWrite ; Set a breakpoint on a read or; write access for a data address.

Break.Set DA:0x00000010 /Read/DATA.Word 0xCAFE

; Set a Breakpoint on a 16 bit; data read access of 0xCAFE on; data address 0x00000010:

Break.Set myVariable /Write/DATA.auto 0xAFFE

; Set a breakpoint on any write; access 0xAFFE to myVariable.; Length information is taken; from object file.

On-chipBreakpoints

For Hexagon there are only two on-chip breakpoint available. If more on-chip breakpoints are used the debugger will report an invalid breakpoint configuration. The on-chip breakpoint can only be set on code and not on data.

Hexagon Debugger 14 ©1989-2019 Lauterbach GmbH

Page 15: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Troubleshooting

SYStem.Up Errors

The SYStem.UP command is the first command of a debug session where communication with the target is required. If you receive error messages while executing this command this may have the following reasons:

• The target has no power.

• There is a short-circuit on at least one output line of the CPU.

• There is a problem with the electrical connection between the debug module and the target - check if the debug cable is plugged correctly and if the target is built corresponding to the definition of the used JTAG connector.

Hexagon Debugger 15 ©1989-2019 Lauterbach GmbH

Page 16: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

FAQ

Debugging via VPN

Ref: 0307

The debugger is accessed via Internet/VPN and the performance is very slow. What can be done to improve debug performance?

The main cause for bad debug performance via Internet or VPN are low data throughput and high latency. The ways to improve performance by the debugger are limited:

In PRACTICE scripts, use "SCREEN.OFF" at the beginning of the scriptand "SCREEN.ON" at the end. "SCREEN.OFF" will turn off screenupdates. Please note that if your program stops (e.g. on error) without exe-cuting "SCREEN.OFF", some windows will not be updated.

"SYStem.POLLING SLOW" will set a lower frequency for target statechecks (e.g. power, reset, jtag state). It will take longer for the debugger torecognize that the core stopped on a breakpoint.

"SETUP.URATE 1.s" will set the default update frequency ofData.List/Data.dump/Variable windows to 1 second (the slowest possiblesetting).

Prevent unneeded memory accesses using "MAP.UPDATEONCE<address_range>" for RAM and "MAP.CONST <address_range>" forROM/FLASH. Address ranged with "MAP.UPDATEONCE" will read thespecified address range only once after the core stopped at a breakpoint ormanual break. "MAP.CONST" will read the specified address range onlyonce per SYStem.Mode command (e.g. SYStem.Up).

Hexagon Debugger 16 ©1989-2019 Lauterbach GmbH

Page 17: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Setting a Software Breakpoint fails

Ref: 0276

What can be the reasons why setting a software breakpoint fails?

Setting a software breakpoint can fail when the target HW is not able to implement the wanted breakpoint. Possible reasons:

The wanted breakpoint needs special features that are only possible torealize by the trigger unit inside the controller.

Example: Read, write and access (Read/Write) breakpoints ("type" in Break.Set window). Breakpoints with checking in real-time for data-values ("Data"). Breakpoints with special features ("action") like TriggerTrace, TraceEnable, TraceOn/TraceOFF.

TRACE32 can not change the memory.Example: ROM and Flash when no preparation with FLASH.Create, FLASH.TARGET and FLASH.AUTO was made. All type of memory if the memory device is missing the necessary control signals like WriteEnable or settings of registers and SpecialFunctionRegisters (SFR).

Contrary settings in TRACE32.Like: MAP.BOnchip for this memory range. Break.SELect.<breakpoint_type> Onchip (HARD is only available for ICE and FIRE).

RTOS and MMU:If the memory can be changed by Data.Set but the breakpoint doesn't work it might be a problem of using an MMU on target when setting the breakpoint to a symbolic address that is different than the writable and intended memory location.

Hexagon

ISDB locked, core not ready

Ref: 0384

When attaching to the Hexagon core, I get an error message: "ISDB locked, core not ready". What does this mean and how can I debug my application?

Attaching to the Hexagon core failed, because the on-chip debug interface is locked. By default, the In-Silicon Debugger (ISDB) of the Hexagon core is locked for security reasons. Only the application which is loaded to the Hexagon Core by the ARM application can unlock the ISDB from internal. In order to debug your application, you have to modify it so that it enables the ISDB and permits debugging. See the Hexagon Architecture Manuals for more information.

Hexagon Debugger 17 ©1989-2019 Lauterbach GmbH

Page 18: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CPU specific SYStem Settings

SYStem.CONFIG.state Display target configuration

Opens the SYStem.CONFIG.state window, where you can view and modify most of the target configuration settings. The configuration settings tell the debugger how to communicate with the chip on the target board and how to access the on-chip debug and trace facilities in order to accomplish the debugger’s operations.

Alternatively, you can modify the target configuration settings via the TRACE32 command line with the SYStem.CONFIG commands. Note that the command line provides additional SYStem.CONFIG commands for settings that are not included in the SYStem.CONFIG.state window.

Format: SYStem.CONFIG.state [/<tab>]

<tab>: DebugPort | Jtag | MultiTap | DAP | COmponents

<tab> Opens the SYStem.CONFIG.state window on the specified tab. For tab descriptions, see below.

DebugPort(default)

The DebugPort tab informs the debugger about the debug connector type and the communication protocol it shall use.

For descriptions of the commands on the DebugPort tab, see DebugPort.

Jtag The Jtag tab informs the debugger about the position of the Test Access Ports (TAP) in the JTAG chain which the debugger needs to talk to in order to access the debug and trace facilities on the chip.

For descriptions of the commands on the Jtag tab, see Jtag.

MultiTap Informs the debugger about the existence and type of a System/Chip Level Test Access Port. The debugger might need to control it in order to reconfigure the JTAG chain or to control power, clock, reset, and security of different chip components.

For descriptions of the commands on the MultiTap tab, see Multitap.

Hexagon Debugger 18 ©1989-2019 Lauterbach GmbH

Page 19: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.CONFIG Configure debugger according to target topology

DAP The DAP tab informs the debugger about an ARM CoreSight Debug Access Port (DAP) and about how to control the DAP to access chip-internal memory busses (AHB, APB, AXI) or chip-internal JTAG interfaces.

For descriptions of the commands on the DAP tab, see DAP.

COmponents The COmponents tab informs the debugger (a) about the existence and interconnection of on-chip CoreSight debug and trace modules and (b) informs the debugger on which memory bus and at which base address the debugger can find the control registers of the modules.

For descriptions of the commands on the COmponents tab, see COmponents.

Format: SYStem.CONFIG <parameter>SYStem.MultiCore <parameter> (deprecated)

<parameter>:(DebugPort)

CJTAGFLAGS <flags>CJTAGTCA <value>CONNECTOR [MIPI34 | MIPI20T]CORE <core> <chip>CoreNumber <number>DEBUGPORT [DebugCable0 | DebugCableA | DebugCableB]DEBUGPORTTYPE [JTAG | SWD | CJTAG | CJTAGSWD]NIDNTTRSTTORST [ON | OFF]

<parameter>:(DebugPort cont.)

NIDNTPSRISINGEDGE [ON | OFF]NIDNTRSTPOLARITY [High | Low]PortSHaRing [ON | OFF | Auto]Slave [ON | OFF]SWDP [ON | OFF]SWDPIDLEHIGH [ON | OFF]SWDPTargetSel <value>DAP2SWDPTargetSel <value>TriState [ON | OFF]

Hexagon Debugger 19 ©1989-2019 Lauterbach GmbH

Page 20: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameter>:(JTAG)

CHIPDRLENGTH <bits>CHIPDRPATTERN [Standard | Alternate <pattern>]CHIPDRPOST <bits>CHIPDRPRE <bits>CHIPIRLENGTH <bits>CHIPIRPATTERN [Standard | Alternate <pattern>]CHIPIRPOST<bits>CHIPIRPRE <bits>

<parameter>:(JTAG cont.)

DAP2DRPOST <bits>DAP2DRPRE <bits>DAP2IRPOST <bits>DAP2IRPRE <bits>DAPDRPOST <bits>DAPDRPRE <bits>DAPIRPOST <bits>DAPIRPRE <bits>

<parameter>:(JTAG cont.)

DRPOST <bits>DRPRE <bits>ETBDRPOST <bits>ETBDRPRE <bits>ETBIRPOST <bits>ETBIRPRE <bits>IRPOST<bits>IRPRE <bits>

<parameter>:(JTAG cont.)

NEXTDRPOST <bits>NEXTDRPRE <bits>NEXTIRPOST<bits>NEXTIRPRE <bits>RTPDRPOST <bits>RTPDRPRE <bits>RTPIRPOST <bits>RTPIRPRE <bits>

<parameter>:(JTAG cont.)

Slave [ON | OFF]TAPState <state>TCKLevel <level>TriState [ON | OFF]

Hexagon Debugger 20 ©1989-2019 Lauterbach GmbH

Page 21: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameter>:(Multitap)

CFGCONNECT <code>DAP2TAP <tap>DAPTAP <tap>DEBUGTAP <tap>ETBTAP <tap>MULTITAP [NONE | IcepickA | IcepickB | IcepickC | IcepickD | IcepickBB | IcepickBC | IcepickCC | IcepickDD | STCLTAP1 | STCLTAP2 | STCLTAP3 | MSMTAP <irlength> <irvalue> <drlength> <drvalue> JtagSEQuence <sub_cmd>] NJCR <tap>RTPTAP <tap>SLAVETAP <tap>

<parameter>:(DAP)

AHBACCESSPORT <port>APBACCESSPORT <port>AXIACCESSPORT <port>COREJTAGPORT <port>DAP2AHBACCESSPORT <port>DAP2APBACCESSPORT <port>DAP2AXIACCESSPORT <port>DAP2COREJTAGPORT <port>

<parameter>:(DAP cont.)

DAP2DEBUGACCESSPORT <port>DAP2JTAGPORT <port>DAP2AHBACCESSPORT <port>DEBUGACCESSPORT <port>JTAGACCESSPORT <port>MEMORYACCESSPORT <port>

<parameter>:(COmponents)

ADTF.Base <address>ADTF.RESETAET.Base <address>AET.RESETBMC.Base <address>BMC.RESETCMI.Base <address>CMI.RESET

<parameter>:(COmponents cont.)

CMI.TraceID <id>COREDEBUG.Base <address>COREDEBUG.RESETCTI.Base <address>CTI.Config [NONE | ARMV1 | ARMPostInit | OMAP3 | TMS570 | CortexV1 | QV1]CTI.RESETDRM.Base <address>DRM.RESET

Hexagon Debugger 21 ©1989-2019 Lauterbach GmbH

Page 22: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameter>:(COmponents cont.)

DTM.RESETDTM.Type [None | Generic]DWT.Base <address>DWT.RESETEPM.Base <address>EPM.RESETETB2AXI.Base <address>ETB2AXI.RESET

<parameter>:(COmponents cont.)

ETB.ATBSource <source>ETB.Base <address>ETB.NoFlush [ON | OFF]ETB.RESETETB.Size <size>ETF.ATBSource <source>ETF.Base <address>ETF.RESETETM.Base <address>

<parameter>:(COmponents cont.)

ETM.RESETETR.ATBSource <source>ETR.Base <address>ETR.RESETFUNNEL.ATBSource <sourcelist>FUNNEL.Base <address>FUNNEL.Name <string>FUNNEL.PROGrammable [ON | OFF]

<parameter>:(Components cont.)

FUNNEL.RESETHSM.Base <address>HSM.RESETHTM.Base <address>HTM.RESETHTM.Type [CoreSight | WPT]ICE.Base <address>ICE.RESET

<parameter>:(Components cont.)

ITM.Base <address>ITM.RESETL2CACHE.Base <address>L2CACHE.RESETL2CACHE.Type [NONE | Generic | L210 | L220 | L2C-310 | AURORA | AURORA2]OCP.Base <address>OCP.RESETOCP.TraceID <id>

Hexagon Debugger 22 ©1989-2019 Lauterbach GmbH

Page 23: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameter>:(Components cont.)

OCP.Type <type>PMI.Base <address>PMI.RESETPMI.TraceID <id>RTP.Base <address>RTP.PerBase <address>RTP.RamBase <address>RTP.RESET

<parameter>:(Components cont.)

SC.Base <address>SC.RESETSC.TraceID <id>STM.Base <address>STM.Mode [NONE | XTIv2 | SDTI | STP | STP64 | STPv2]STM.RESETSTM.Type [None | GenericARM | SDTI | TI]TPIU.ATBSource <source>TPIU.Base <address>TPIU.RESETTPIU.Type [CoreSight | Generic]

<parameter>:(Deprecated)

BMCBASE <address>BYPASS <seq>COREBASE <address> CTIBASE <address> CTICONFIG [NONE | ARMV1 | ARMPostInit | OMAP3 | TMS570 | CortexV1 | QV1]DEBUGBASE <address>DTMCONFIG [ON | OFF]

<parameter>:(Deprecated cont.)

DTMETBFUNNELPORT <port>DTMFUNNEL2PORT <port>DTMFUNNELPORT <port>DTMTPIUFUNNELPORT <port>DWTBASE <address>ETB2AXIBASE <address> ETBBASE <address>

<parameter>:(Deprecated cont.)

ETBFUNNELBASE <address>ETFBASE <address>ETMBASE <address>ETMETBFUNNELPORT <port>ETMFUNNEL2PORT <port>ETMFUNNELPORT <port>ETMTPIUFUNNELPORT <port>FILLDRZERO [ON | OFF]

Hexagon Debugger 23 ©1989-2019 Lauterbach GmbH

Page 24: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

The SYStem.CONFIG commands inform the debugger about the available on-chip debug and trace components and how to access them.

This is a common description of the SYStem.CONFIG command group for the ARM, CevaX, TI DSP and Hexagon debugger. Each debugger will provide only a subset of these commands. Some commands need a certain CPU type selection (SYStem.CPU <type>) to become active and it might additionally depend on further settings.

<parameter>:(Deprecated cont.)

FUNNEL2BASE <address>FUNNELBASE <address>HSMBASE <address>HTMBASE <address>HTMETBFUNNELPORT <port>HTMFUNNEL2PORT <port>HTMFUNNELPORT <port>HTMTPIUFUNNELPORT <port>

<parameter>:(Deprecated cont.)

ITMBASE <address>ITMETBFUNNELPORT <port>ITMFUNNEL2PORT <port>ITMFUNNELPORT <port>ITMTPIUFUNNELPORT <port>PERBASE <address>RAMBASE <address>RTPBASE <address>

<parameter>:(Deprecated cont.)

SDTIBASE <address>STMBASE <address>STMETBFUNNELPORT<port>STMFUNNEL2PORT<port>STMFUNNELPORT<port>STMTPIUFUNNELPORT<port>TIADTFBASE <address>TIDRMBASE <address>

<parameter>:(Deprecated cont.)

TIEPMBASE <address>TIICEBASE <address>TIOCPBASE <address>TIOCPTYPE <type>TIPMIBASE <address>TISCBASE <address>TISTMBASE <address>

<parameter>:(Deprecated cont.)

TPIUBASE <address>TPIUFUNNELBASE <address>TRACEETBFUNNELPORT <port>TRACEFUNNELPORT<port>TRACETPIUFUNNELPORT <port>view

Hexagon Debugger 24 ©1989-2019 Lauterbach GmbH

Page 25: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Ideally you can select with SYStem.CPU the chip you are using which causes all setup you need and you do not need any further SYStem.CONFIG command.

The SYStem.CONFIG command information shall be provided after the SYStem.CPU command, which might be a precondition to enter certain SYStem.CONFIG commands, and before you start up the debug session e.g. by SYStem.Up.

Syntax Remarks

The commands are not case sensitive. Capital letters show how the command can be shortened.Example: “SYStem.CONFIG.DWT.Base 0x1000” -> “SYS.CONFIG.DWT.B 0x1000”

The dots after “SYStem.CONFIG” can alternatively be a blank.Example: “SYStem.CONFIG.DWT.Base 0x1000” or “SYStem.CONFIG DWT Base 0x1000”.

Hexagon Debugger 25 ©1989-2019 Lauterbach GmbH

Page 26: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameters> describing the “DebugPort”

CJTAGFLAGS <flags> Activates bug fixes for “cJTAG” implementations.Bit 0: Disable scanning of cJTAG ID.Bit 1: Target has no “keeper”.Bit 2: Inverted meaning of SREDGE register.Bit 3: Old command opcodes.Bit 4: Unlock cJTAG via APFC register.

Default: 0

CJTAGTCA <value> Selects the TCA (TAP Controller Address) to address a device in a cJTAG Star-2 configuration. The Star-2 configuration requires a unique TCA for each device on the debug port.

CONNECTOR[MIPI34 | MIPI20T]

Specifies the connector “MIPI34” or “MIPI20T” on the target. This is mainly needed in order to notify the trace pin location.

Default: MIPI34 if CombiProbe is used, MIPI20T if uTrace is used.

CORE <core> <chip> The command helps to identify debug and trace resources which are commonly used by different cores. The command might be required in a multicore environment if you use multiple debugger instances (multiple TRACE32 PowerView GUIs) to simultaneously debug different cores on the same target system.

Because of the default setting of this command

debugger#1: <core>=1 <chip>=1debugger#2: <core>=1 <chip>=2...

each debugger instance assumes that all notified debug and trace resources can exclusively be used.

But some target systems have shared resources for different cores, for example a common trace port. The default setting causes that each debugger instance controls the same trace port. Sometimes it does not hurt if such a module is controlled twice. But sometimes it is a must to tell the debugger that these cores share resources on the same <chip>. Whereby the “chip” does not need to be identical with the device on your target board:

debugger#1: <core>=1 <chip>=1debugger#2: <core>=2 <chip>=1

Hexagon Debugger 26 ©1989-2019 Lauterbach GmbH

Page 27: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CORE <core> <chip>

(cont.)

For cores on the same <chip>, the debugger assumes that the cores share the same resource if the control registers of the resource have the same address.

Default:<core> depends on CPU selection, usually 1.<chip> derived from CORE= parameter in the configuration file (config.t32), usually 1. If you start multiple debugger instances with the help of t32start.exe, you will get ascending values (1, 2, 3,...).

CoreNumber <number> Number of cores to be considered in an SMP (symmetric multiprocessing) debug session. There are core types like ARM11MPCore, CortexA5MPCore, CortexA9MPCore and Scorpion which can be used as a single core processor or as a scalable multicore processor of the same type. If you intend to debug more than one such core in an SMP debug session you need to specify the number of cores you intend to debug.

Default: 1.

DEBUGPORT [DebugCable0 | DebugCa-bleA | DebugCableB]

It specifies which probe cable shall be used e.g. “DebugCableA” or “DebugCableB”. At the moment only the CombiProbe allows to connect more than one probe cable.

Default: depends on detection.

DEBUGPORTTYPE[JTAG | SWD | CJTAG | CJTAGSWD]

It specifies the used debug port type “JTAG”, “SWD”, “CJTAG”, “CJTAG-SWD”. It assumes the selected type is supported by the target.

Default: JTAG.

What is NIDnT?

NIDnT is an acronym for “Narrow Interface for Debug and Test”. NIDnT is a standard from the MIPI Alliance, which defines how to reuse the pins of an existing interface (like for example a microSD card interface) as a debug and test interface.

To support the NIDnT standard in different implementations, TRACE32 has several special options:

Hexagon Debugger 27 ©1989-2019 Lauterbach GmbH

Page 28: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

NIDNTPSRISINGEDGE[ON | OFF]

Send data on rising edge for NIDnT PS switching.

NIDnT specifies how to switch, for example, the microSD card interface to a debug interface by sending in a special bit sequence via two pins of the microSD card.

TRACE32 will send the bits of the sequence incident to the falling edge of the clock, because TRACE32 expects that the target samples the bits on the rising edge of the clock.

Some targets will sample the bits on the falling edge of the clock instead. To support such targets, you can configure TRACE32 to send bits on the rising edge of the clock by using SYStem.CONFIG NIDNTPSRISINGEDGE ON

NOTE: Only enable this option right before you send the NIDnT switching bit sequence.Make sure to DISABLE this option, before you try to connect to the target system with for example SYStem.Up.

NIDNTRSTPOLARITY[High | Low]

Usually TRACE32 requires that the system reset line of a target system is low active and has a pull-up on the target system.

When connecting via NIDnT to a target system, the reset line might be a high-active signal.To configure TRACE32 to use a high-active reset signal, useSYStem.CONFIG NIDNTRSTPOLARITY High

This option must be used together withSYStem.CONFIG NIDNTTRSTTORST ONbecause you also have to use the TRST signal of an ARM debug cable as reset signal for NIDnT in this case.

NIDNTTRSTTORST[ON | OFF]

Usually TRACE32 requires that the system reset line of a target system is low active and has a pull-up on the target system.This is how the system reset line is usually implemented on regular ARM-based targets.

When connecting via NIDnT (e.g. a microSD card slot) to the target system, the reset line might not include a pull-up on the target system.To circumvent problems, TRACE32 allows to drive the target reset line via the TRST signal of an ARM debug cable.

Enable this option if you want to use the TRST signal of an ARM debug cable as reset signal for a NIDnT.

Hexagon Debugger 28 ©1989-2019 Lauterbach GmbH

Page 29: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

PortSHaRing [ON | OFF | Auto]

Configure if the debug port is shared with another tool, e.g. an ETAS ETK.

OFF: Default. Communicate with the target without sending requests.

ON: Request for access to the debug port and wait until the access is granted before communicating with the target.

Auto: Automatically detect a connected tool on next SYStem.Mode Up, SYStem.Mode Attach or SYStem.Mode Go. If a tool is detected switch to mode ON else switch to mode OFF.

The current setting can be obtained by the PORTSHARING() function, immediate detection can be performed using SYStem.DETECT PortSHaRing.

Slave [ON | OFF] If several debuggers share the same debug port, all except one must have this option active.

JTAG: Only one debugger - the “master” - is allowed to control the signals nTRST and nSRST (nRESET). The other debuggers need to have the setting Slave ON.

Default: OFF.Default: ON if CORE=... >1 in the configuration file (e.g. config.t32).

SWDP [ON | OFF] With this command you can change from the normal JTAG interface to the serial wire debug mode. SWDP (Serial Wire Debug Port) uses just two signals instead of five. It is required that the target and the debugger hard- and software supports this interface.

Default: OFF.

SWDPIdleHigh [ON | OFF]

Keep SWDIO line high when idle. Only for Serialwire Debug mode. Usually the debugger will pull the SWDIO data line low, when no operation is in progress, so while the clock on the SWCLK line is stopped (kept low).

You can configure the debugger to pull the SWDIO data linehigh, when no operation is in progress by using SYStem.CONFIG SWDPIdleHigh ON

Default: OFF.

SWDPTargetSel <value> Device address in case of a multidrop serial wire debug port.

Default: none set (any address accepted).

Hexagon Debugger 29 ©1989-2019 Lauterbach GmbH

Page 30: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

DAP2SWDPTargetSel <value>

Device address of the second CoreSight DAP (DAP2) in case of a multidrop serial wire debug port (SWD).

Default: none set (any address accepted).

TriState [ON | OFF] TriState has to be used if several debug cables are connected to a common JTAG port. TAPState and TCKLevel define the TAP state and TCK level which is selected when the debugger switches to tristate mode. Please note: • nTRST must have a pull-up resistor on the target.• TCK can have a pull-up or pull-down resistor.• Other trigger inputs need to be kept in inactive state.

Default: OFF.

Hexagon Debugger 30 ©1989-2019 Lauterbach GmbH

Page 31: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameters> describing the “JTAG” scan chain and signal behavior

With the JTAG interface you can access a Test Access Port controller (TAP) which has implemented a state machine to provide a mechanism to read and write data to an Instruction Register (IR) and a Data Register (DR) in the TAP. The JTAG interface will be controlled by 5 signals:

• nTRST (reset)

• TCK (clock)

• TMS (state machine control)

• TDI (data input)

• TDO (data output)

Multiple TAPs can be controlled by one JTAG interface by daisy-chaining the TAPs (serial connection). If you want to talk to one TAP in the chain, you need to send a BYPASS pattern (all ones) to all other TAPs. For this case the debugger needs to know the position of the TAP it wants to talk to. The TAP position can be defined with the first four commands in the table below.

… DRPOST <bits> Defines the TAP position in a JTAG scan chain. Number of TAPs in the JTAG chain between the TDI signal and the TAP you are describing. In BYPASS mode, each TAP contributes one data register bit. See possible TAP types and example below.

Default: 0.

… DRPRE <bits> Defines the TAP position in a JTAG scan chain. Number of TAPs in the JTAG chain between the TAP you are describing and the TDO signal. In BYPASS mode, each TAP contributes one data register bit. See possible TAP types and example below.

Default: 0.

… IRPOST <bits> Defines the TAP position in a JTAG scan chain. Number of Instruction Register (IR) bits of all TAPs in the JTAG chain between TDI signal and the TAP you are describing. See possible TAP types and example below.

Default: 0.

… IRPRE <bits> Defines the TAP position in a JTAG scan chain. Number of Instruction Register (IR) bits of all TAPs in the JTAG chain between the TAP you are describing and the TDO signal. See possible TAP types and example below.

Default: 0.

NOTE: If you are not sure about your settings concerning IRPRE, IRPOST, DRPRE, and DRPOST, you can try to detect the settings automatically with the SYStem.DETECT.DaisyChain command.

Hexagon Debugger 31 ©1989-2019 Lauterbach GmbH

Page 32: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CHIPDRLENGTH <bits>

Number of Data Register (DR) bits which needs to get a certain BYPASS pattern.

CHIPDRPATTERN [Standard | Alter-nate <pattern>]

Data Register (DR) pattern which shall be used for BYPASS instead of the standard (1...1) pattern.

CHIPIRLENGTH <bits>

Number of Instruction Register (IR) bits which needs to get a certain BYPASS pattern.

CHIPIRPATTERN [Standard | Alter-nate <pattern>]

Instruction Register (IR) pattern which shall be used for BYPASS instead of the standard pattern.

Slave [ON | OFF] If several debuggers share the same debug port, all except one must have this option active.

JTAG: Only one debugger - the “master” - is allowed to control the signals nTRST and nSRST (nRESET). The other debuggers need to have the setting Slave OFF.

Default: OFF.Default: ON if CORE=... >1 in the configuration file (e.g. config.t32).For CortexM: Please check also SYStem.Option DISableSOFTRES [ON | OFF]

TAPState <state> This is the state of the TAP controller when the debugger switches to tristate mode. All states of the JTAG TAP controller are selectable.

0 Exit2-DR1 Exit1-DR2 Shift-DR3 Pause-DR4 Select-IR-Scan5 Update-DR6 Capture-DR7 Select-DR-Scan8 Exit2-IR9 Exit1-IR10 Shift-IR11 Pause-IR12 Run-Test/Idle13 Update-IR14 Capture-IR15 Test-Logic-Reset

Default: 7 = Select-DR-Scan.

Hexagon Debugger 32 ©1989-2019 Lauterbach GmbH

Page 33: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

TAP types:

Core TAP providing access to the debug register of the core you intend to debug.-> DRPOST, DRPRE, IRPOST, IRPRE.

DAP (Debug Access Port) TAP providing access to the debug register of the core you intend to debug. It might be needed additionally to a Core TAP if the DAP is only used to access memory and not to access the core debug register.-> DAPDRPOST, DAPDRPRE, DAPIRPOST, DAPIRPRE.

DAP2 (Debug Access Port) TAP in case you need to access a second DAP to reach other memory locations.-> DAP2DRPOST, DAP2DRPRE, DAP2IRPOST, DAP2IRPRE.

ETB (Embedded Trace Buffer) TAP if the ETB has its own TAP to access its control register (typical with ARM11 cores).-> ETBDRPOST, ETBDRPRE, ETBIRPOST, ETBIRPRE.

NEXT: If a memory access changes the JTAG chain and the core TAP position then you can specify the new values with the NEXT... parameter. After the access for example the parameter NEXTIRPRE will replace the IRPRE value and NEXTIRPRE becomes 0. Available only on ARM11 debugger.-> NEXTDRPOST, NEXTDRPRE, NEXTIRPOST, NEXTIRPRE.

RTP (RAM Trace Port) TAP if the RTP has its own TAP to access its control register.-> RTPDRPOST, RTPDRPRE, RTPIRPOST, RTPIRPRE.

CHIP: Definition of a TAP or TAP sequence in a scan chain that needs a different Instruction Register (IR) and Data Register (DR) pattern than the default BYPASS (1...1) pattern.-> CHIPDRPOST, CHIPDRPRE, CHIPIRPOST, CHIPIRPRE.

TCKLevel <level> Level of TCK signal when all debuggers are tristated. Normally defined by a pull-up or pull-down resistor on the target.

Default: 0.

TriState [ON | OFF] TriState has to be used if several debug cables are connected to a common JTAG port. TAPState and TCKLevel define the TAP state and TCK level which is selected when the debugger switches to tristate mode. Please note: • nTRST must have a pull-up resistor on the target.• TCK can have a pull-up or pull-down resistor.• Other trigger inputs need to be kept in inactive state.

Default: OFF.

Hexagon Debugger 33 ©1989-2019 Lauterbach GmbH

Page 34: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Example:

SYStem.CONFIG IRPRE 15.SYStem.CONFIG DRPRE 3.SYStem.CONFIG DAPIRPOST 16.SYStem.CONFIG DAPDRPOST 3.SYStem.CONFIG ETBIRPOST 5.SYStem.CONFIG ETBDRPOST 1.SYStem.CONFIG ETBIRPRE 11.SYStem.CONFIG ETBDRPRE 2.

ARM11 TAP

IR: 5bit

ETB TAP

IR: 4bit

DAP TAP

IR: 4bit

TDI TDOOfNoInterest TAP

IR: 7bit

Hexagon Debugger 34 ©1989-2019 Lauterbach GmbH

Page 35: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameters> describing a system level TAP “Multitap”

A “Multitap” is a system level or chip level test access port (TAP) in a JTAG scan chain. It can for example provide functions to re-configure the JTAG chain or view and control power, clock, reset and security of different chip components.

At the moment the debugger supports three types and its different versions:Icepickx, STCLTAPx, MSMTAP:

Example:

CFGCONNECT <code> The <code> is a hexadecimal number which defines the JTAG scan chain configuration. You need the chip documentation to figure out the suitable code. In most cases the chip specific default value can be used for the debug session.

Used if MULTITAP=STCLTAPx.

DAPTAP <tap> Specifies the TAP number which needs to be activated to get the DAP TAP in the JTAG chain.

Used if MULTITAP=Icepickx.

DAP2TAP <tap> Specifies the TAP number which needs to be activated to get a 2nd DAP TAP in the JTAG chain.

Used if MULTITAP=Icepickx.

TDO

TMS

TCK

nTRST

ARM11TAP

DAPTAP

ETBTAP

MULTITAP IcepickCDEBUGTAPDAPTAPETBTAB

Multitap“IcepickC”

JTAG

145

TDI

Hexagon Debugger 35 ©1989-2019 Lauterbach GmbH

Page 36: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

DEBUGTAP <tap> Specifies the TAP number which needs to be activated to get the core TAP in the JTAG chain. E.g. ARM11 TAP if you intend to debug an ARM11.

Used if MULTITAP=Icepickx.

ETBTAP <tap> Specifies the TAP number which needs to be activated to get the ETB TAP in the JTAG chain.

Used if MULTITAP=Icepickx. ETB = Embedded Trace Buffer.

MULTITAP[NONE | IcepickA | IcepickB | IcepickC | IcepickD | IcepickBB | IcepickBC | IcepickCC | IcepickDD | STCLTAP1 | STCLTAP2 | STCLTAP3 | MSMTAP <irlength> <irvalue> <drlength> <drvalue>JtagSEQuence <sub_cmd>]

Selects the type and version of the MULTITAP.

In case of MSMTAP you need to add parameters which specify which IR pattern and DR pattern needed to be shifted by the debugger to initialize the MSMTAP. Please note some of these parameters need a decimal input (dot at the end).

IcepickXY means that there is an Icepick version “X” which includes a subsystem with an Icepick of version “Y”.

For a description of the JtagSEQuence subcommands, see SYStem.CONFIG.MULTITAP JtagSEQuence.

NJCR <tap> Number of a Non-JTAG Control Register (NJCR) which shall be used by the debugger.

Used if MULTITAP=Icepickx.

RTPTAP <tap> Specifies the TAP number which needs to be activated to get the RTP TAP in the JTAG chain.

Used if MULTITAP=Icepickx. RTP = RAM Trace Port.

SLAVETAP <tap> Specifies the TAP number to get the Icepick of the sub-system in the JTAG scan chain.

Used if MULTITAP=IcepickXY (two Icepicks).

Hexagon Debugger 36 ©1989-2019 Lauterbach GmbH

Page 37: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameters> configuring a CoreSight Debug Access Port “DAP”

A Debug Access Port (DAP) is a CoreSight module from ARM which provides access via its debugport (JTAG, cJTAG, SWD) to:

1. Different memory busses (AHB, APB, AXI). This is especially important if the on-chip debug register needs to be accessed this way. You can access the memory buses by using certain access classes with the debugger commands: “AHB:”, “APB:”, “AXI:, “DAP”, “E:”. The interface to these buses is called Memory Access Port (MEM-AP).

2. Other, chip-internal JTAG interfaces. This is especially important if the core you intend to debug is connected to such an internal JTAG interface. The module controlling these JTAG interfaces is called JTAG Access Port (JTAG-AP). Each JTAG-AP can control up to 8 internal JTAG interfaces. A port number between 0 and 7 denotes the JTAG interfaces to be addressed.

3. At emulation or simulation system with using bus transactors the access to the busses must be specified by using the transactor identification name instead using the access port commands. For emulations/simulations with a DAP transactor the individual bus transactor name don’t need to be configured. Instead of this the DAP transactor name need to be passed and the regular access ports to the busses.

Hexagon Debugger 37 ©1989-2019 Lauterbach GmbH

Page 38: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Example:

AHBACCESSPORT <port> DAP access port number (0-255) which shall be used for “AHB:” access class. Default: <port>=0.

APBACCESSPORT <port> DAP access port number (0-255) which shall be used for “APB:” access class. Default: <port>=1.

AXIACCESSPORT <port> DAP access port number (0-255) which shall be used for “AXI:” access class. Default: port not available

COREJTAGPORT <port> JTAG-AP port number (0-7) connected to the core which shall be debugged.

Deb

ug

ger

Memory Access Port(MEM-AP)

1

Memory Access Port(MEM-AP)

0

JTAG Access Port(JTAG-AP)

2S

yste

m B

us (

AH

B)

Deb

ug B

us (

AP

B)

System Memory

Debug Register

Trace Register

ROM Table

0 JTAG

7 JTAG ARM9

Debug Access Port (DAP)

COREJTAGPORT 7AHBACCESSPORT 0MEMORYACCESSPORT 0APBACCESSPORT 1DEBUGACCESSPORT 1JTAGACCESSPORT 2

Debug PortJTAG or cJTAG orSWD

Chip

Hexagon Debugger 38 ©1989-2019 Lauterbach GmbH

Page 39: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

DAP2AHBACCESSPORT <port>

DAP2 access port number (0-255) which shall be used for “AHB2:” access class. Default: <port>=0.

DAP2APBACCESSPORT <port>

DAP2 access port number (0-255) which shall be used for “APB2:” access class. Default: <port>=1.

DAP2AXIACCESSPORT <port>

DAP2 access port number (0-255) which shall be used for “AXI2:” access class. Default: port not available

DAP2DEBUGACCESS-PORT <port>

DAP2 access port number (0-255) where the debug register can be found (typically on APB). Used for “DAP2:” access class. Default: <port>=1.

DAP2COREJTAGPORT <port>

JTAG-AP port number (0-7) connected to the core which shall be debugged. The JTAG-AP can be found on another DAP (DAP2).

DAP2JTAGPORT <port> JTAG-AP port number (0-7) for an (other) DAP which is connected to a JTAG-AP.

DAP2MEMORYACCESS-PORT <port>

DAP2 access port number where system memory can be accessed even during runtime (typically on AHB). Used for “E:” access class while running, assuming “SYStem.MemoryAccess DAP2”. Default: <port>=0.

DEBUGACCESSPORT <port>

DAP access port number (0-255) where the debug register can be found (typically on APB). Used for “DAP:” access class. Default: <port>=1.

JTAGACCESSPORT <port> DAP access port number (0-255) of the JTAG Access Port.

MEMORYACCESSPORT <port>

DAP access port number where system memory can be accessed even during runtime (typically on AHB). Used for “E:” access class while running, assuming “SYStem.MemoryAccess DAP”. Default: <port>=0.

AHBNAME <name> AHB bus transactor name that shall be used for “AHB:” access class.

APBNAME <name> APB bus transactor name that shall be used for “APB:” access class.

AXINAME <name> AXI bus transactor name that shall be used for “AXI:” access class.

DAP2AHBNAME <name> AHB bus transactor name that shall be used for “AHB2:” access class.

Hexagon Debugger 39 ©1989-2019 Lauterbach GmbH

Page 40: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

DAP2APBNAME <name> APB bus transactor name that shall be used for “APB2:” access class.

DAP2AXINAME <name> AXI bus transactor name that shall be used for “AXI2:” access class.

DAP2DEBUGBUSNAME <name>

APB bus transactor name identifying the bus where the debug register can be found. Used for “DAP2:” access class.

DAP2MEMORYBUSNAME <name>

AHB bus transactor name identifying the bus where system memory can be accessed even during runtime. Used for “E:” access class while running, assuming “SYStem.MemoryAccess DAP2”.

DEBUGBUSNAME <name> APB bus transactor name identifying the bus where the debug register can be found. Used for “DAP:” access class.

MEMORYBUSNAME <name>

AHB bus transactor name identifying the bus where system memory can be accessed even during runtime. Used for “E:” access class while running, assuming “SYStem.MemoryAccess DAP”.

DAPNAME <name> DAP transactor name that shall be used for DAP access ports.

DAP2NAME <name> DAP transactor name that shall be used for DAP access ports of 2nd order.

Hexagon Debugger 40 ©1989-2019 Lauterbach GmbH

Page 41: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameters> describing debug and trace “Components”

On the Components tab in the SYStem.CONFIG.state window, you can comfortably add the debug and trace components your chip includes and which you intend to use with the debugger’s help.

Each configuration can be done by a command in a script file as well. Then you do not need to enter everything again on the next debug session. If you press the button with the three dots you get the corresponding command in the command line where you can view and maybe copy it into a script file.

Hexagon Debugger 41 ©1989-2019 Lauterbach GmbH

Page 42: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

You can have several of the following components: CMI, ETB, ETF, ETR, FUNNEL, STM.Example: FUNNEL1, FUNNEL2, FUNNEL3,...

The <address> parameter can be just an address (e.g. 0x80001000) or you can add the access class in front (e.g. AHB:0x80001000). Without access class it gets the command specific default access class which is “EDAP:” in most cases.

Example:

SYStem.CONFIG.COREDEBUG.Base 0x80010000 0x80012000SYStem.CONFIG.BMC.Base 0x80011000 0x80013000SYStem.CONFIG.ETM.Base 0x8001c000 0x8001d000SYStem.CONFIG.STM1.Base EAHB:0x20008000SYStem.CONFIG.STM1.Type ARMSYStem.CONFIG.STM1.Mode STPv2SYStem.CONFIG.FUNNEL1.Base 0x80004000SYStem.CONFIG.FUNNEL2.Base 0x80005000SYStem.CONFIG.TPIU.Base 0x80003000SYStem.CONFIG.FUNNEL1.ATBSource ETM.0 0 ETM.1 1SYStem.CONFIG.FUNNEL2.ATBSource FUNNEL1 0 STM1 7SYStem.CONFIG.TPIU.ATBSource FUNNEL2

ETM

ETM

STM

Core

Core

FUNNEL

TPIUFUNNEL

0

10

7

Hexagon Debugger 42 ©1989-2019 Lauterbach GmbH

Page 43: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

… .ATBSource <source> Specify for components collecting trace information from where the trace data are coming from. This way you inform the debugger about the interconnection of different trace components on a common trace bus.

You need to specify the “... .Base <address>” or other attributes that define the amount of existing peripheral modules before you can describe the interconnection by “... .ATBSource <source>”.

A CoreSight trace FUNNEL has eight input ports (port 0-7) to combine the data of various trace sources to a common trace stream. Therefore you can enter instead of a single source a list of sources and input port numbers.

Example:SYStem.CONFIG FUNNEL.ATBSource ETM 0 HTM 1 STM 7

Meaning: The funnel gets trace data from ETM on port 0, from HTM on port 1 and from STM on port 7.

In an SMP (Symmetric MultiProcessing) debug session where you used a list of base addresses to specify one component per core you need to indicate which component in the list is meant:

Hexagon Debugger 43 ©1989-2019 Lauterbach GmbH

Page 44: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Example: Four cores with ETM modules.SYStem.CONFIG ETM.Base 0x1000 0x2000 0x3000 0x4000SYStem.CONFIG FUNNEL1.ATBSource ETM.0 0 ETM.1 1 ETM.2 2 ETM.3 3"...2" of "ETM.2" indicates it is the third ETM module which has the base address 0x3000. The indices of a list are 0, 1, 2, 3,... If the numbering is accelerating, starting from 0, without gaps, like the example above then you can shorten it to SYStem.CONFIG FUNNEL1.ATBSource ETM

Example: Four cores, each having an ETM module and an ETB module.SYStem.CONFIG ETM.Base 0x1000 0x2000 0x3000 0x4000SYStem.CONFIG ETB.Base 0x5000 0x6000 0x7000 0x8000SYStem.CONFIG ETB.ATBSource ETM.2 2The third "ETM.2" module is connected to the third ETB. The last "2" in the command above is the index for the ETB. It is not a port number which exists only for FUNNELs.

For a list of possible components including a short description see Components and Available Commands.

… .BASE <address> This command informs the debugger about the start address of the register block of the component. And this way it notifies the existence of the component. An on-chip debug and trace component typically provides a control register block which needs to be accessed by the debugger to control this component.

Example: SYStem.CONFIG ETMBASE APB:0x8011c000

Meaning: The control register block of the Embedded Trace Macrocell (ETM) starts at address 0x8011c000 and is accessible via APB bus.

In an SMP (Symmetric MultiProcessing) debug session you can enter for the components BMC, COREBEBUG, CTI, ETB, ETF, ETM, ETR a list of base addresses to specify one component per core.

Example assuming four cores: SYStem.CONFIG COREDEBUG.Base 0x80001000 0x80003000 0x80005000 0x80007000

For a list of possible components including a short description see Components and Available Commands.

… .RESET Undo the configuration for this component. This does not cause a physical reset for the component on the chip.

For a list of possible components including a short description see Components and Available Commands.

Hexagon Debugger 44 ©1989-2019 Lauterbach GmbH

Page 45: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

… .TraceID <id> Identifies from which component the trace packet is coming from. Components which produce trace information (trace sources) for a common trace stream have a selectable “.TraceID <id>”.

If you miss this SYStem.CONFIG command for a certain trace source (e.g. ETM) then there is a dedicated command group for this component where you can select the ID (ETM.TraceID <id>).

The default setting is typically fine because the debugger uses different default trace IDs for different components.

For a list of possible components including a short description see Components and Available Commands.

CTI.Config <type> Informs about the interconnection of the core Cross Trigger Interfaces (CTI). Certain ways of interconnection are common and these are supported by the debugger e.g. to cause a synchronous halt of multiple cores.

NONE: The CTI is not used by the debugger.ARMV1: This mode is used for ARM7/9/11 cores which support synchronous halt, only.ARMPostInit: Like ARMV1 but the CTI connection differs from the ARM recommendation. OMAP3: This mode is not yet used.TMS570: Used for a certain CTI connection used on a TMS570 derivative.CortexV1: The CTI will be configured for synchronous start and stop via CTI. It assumes the connection of DBGRQ, DBGACK, DBGRESTART signals to CTI are done as recommended by ARM. The CTIBASE must be notified. “CortexV1” is the default value if a Cortex-A/R core is selected and the CTIBASE is notified.QV1: This mode is not yet used.

ARMV8V1: Channel 0 and 1 of the CTM are used to distribute start/stop events from and to the CTIs. ARMv8 only.ARMV8V2: Channel 2 and 3 of the CTM are used to distribute start/stop events from and to the CTIs. ARMv8 only.ARMV8V3: Channel 0, 1 and 2 of the CTM are used to distribute start/stop events. Implemented on request. ARMv8 only.

DTM.Type [None | Generic] Informs the debugger that a customer proprietary Data Trace Message (DTM) module is available. This causes the debugger to consider this source when capturing common trace data. Trace data from this module will be recorded and can be accessed later but the unknown DTM module itself will not be controlled by the debugger.

Hexagon Debugger 45 ©1989-2019 Lauterbach GmbH

Page 46: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

ETB.NoFlush [ON | OFF] Deactivates an ETB flush request at the end of the trace recording. This is a workaround for a bug on a certain chip. You will loose trace data at the end of the recording. Don’t use it if not needed. Default: OFF.

ETB.Size <size> Specifies the size of the Embedded Trace Buffer. The ETB size can normally be read out by the debugger. Therefore this command is only needed if this can not be done for any reason.

ETM.StackMode [NotAvail-bale | TRGETM | FULLTIDRM | NOTSET | FULLSTOP | FULLCTI]

Specifies the which method is used to implement the Stack mode of the on-chip trace.NotAvailable: stack mode is not available for this on-chip trace.TRGETM: the trigger delay counter of the onchip-trace is used. It starts by a trigger signal that must be provided by a trace source. Usually those events are routed through one or more CTIs to the on-chip trace.FULLTIDRM: trigger mechanism for TI devices.NOTSET: the method is derived by other GUIs or hardware. detection.FULLSTOP: on-chip trace stack mode by implementation.FULLCTI: on-chip trace provides a trigger signal that is routed back to on-chip trace over a CTI.

FUNNEL.Name <string> It is possible that different funnels have the same address for their control register block. This assumes they are on different buses and for different cores. In this case it is needed to give the funnel different names to differentiate them.

FUNNEL.PROGrammable [ON | OFF]

IIn case the funnel can not or may not be programmed by the debugger, this option needs to be OFF. Default is ON.

HTM.Type [CoreSight | WPT] Selects the type of the AMBA AHB Trace Macrocell (HTM).CoreSight is the type as described in the ARM CoreSight manuals. WPT is a NXP proprietary trace module.

L2CACHE.Type [NONE | Generic | L210 | L220 | L2C-310 | AURORA | AURORA2]

Selects the type of the level2 cache controller. L210, L220, L2C-310 are controller types provided by ARM. AURORAx are Marvell types. The ‘Generic’ type does not need certain treatment by the debugger.

OCP.Type <type> Specifies the type of the OCP module. The <type> is just a number which you need to figure out in the chip documentation.

RTP.PerBase <address> PERBASE specifies the base address of the core peripheral registers which accesses shall be traced. PERBASE is needed for the RAM Trace Port (RTP) which is available on some derivatives from Texas Instruments. The trace packages include only relative addresses to PERBASE and RAMBASE.

Hexagon Debugger 46 ©1989-2019 Lauterbach GmbH

Page 47: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Components and Available Commands

See the description of the commands above. Please note that there is a common description for ... .ATBSource, ... .Base, , ... .RESET, ... .TraceID.

ADTF.Base <address>ADTF.RESETAMBA trace bus DSP Trace Formatter (ADTF) - Texas InstrumentsModule of a TMS320C5x or TMS320C6x core converting program and data trace information in ARM CoreSight compliant format.

AET.Base <address>AET.RESETAdvanced Event Triggering unit (AET) - Texas InstrumentsTrace source module of a TMS320C5x or TMS320C6x core delivering program and data trace information.

BMC.Base <address>BMC.RESETPerformance Monitor Unit (PMU) - ARM debug module, e.g. on Cortex-A/RBench-Mark-Counter (BMC) is the TRACE32 term for the same thing.The module contains counter which can be programmed to count certain events (e.g. cache hits).

CMI.Base <address>CMI.RESETCMI.TraceID <id>Clock Management Instrumentation (CMI) - Texas InstrumentsTrace source delivering information about clock status and events to a system trace module.

RTP.RamBase <address> RAMBASE is the start address of RAM which accesses shall be traced. RAMBASE is needed for the RAM Trace Port (RTP) which is available on some derivatives from Texas Instruments. The trace packages include only relative addresses to PERBASE and RAMBASE.

STM.Mode [NONE | XTIv2 | SDTI | STP | STP64 | STPv2]

Selects the protocol type used by the System Trace Module (STM).

STM.Type [None | Generic | ARM | SDTI | TI]

Selects the type of the System Trace Module (STM). Some types allow to work with different protocols (see STM.Mode).

TPIU.Type [CoreSight | Generic]

Selects the type of the Trace Port Interface Unit (TPIU).

CoreSight: Default. CoreSight TPIU. TPIU control register located at TPIU.Base <address> will be handled by the debugger.

Generic: Proprietary TPIU. TPIU control register will not be handled by the debugger.

Hexagon Debugger 47 ©1989-2019 Lauterbach GmbH

Page 48: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

COREDEBUG.Base <address>COREDEBUG.RESETCore Debug Register - ARM debug register, e.g. on Cortex-A/RSome cores do not have a fix location for their debug register used to control the core. In this case it is essential to specify its location before you can connect by e.g. SYStem.Up.

CTI.Base <address>CTI.Config [NONE | ARMV1 | ARMPostInit | OMAP3 | TMS570 | CortexV1 | QV1]CTI.RESETCross Trigger Interface (CTI) - ARM CoreSight moduleIf notified the debugger uses it to synchronously halt (and sometimes also to start) multiple cores.

DRM.Base <address>DRM.RESETDebug Resource Manager (DRM) - Texas InstrumentsIt will be used to prepare chip pins for trace output.

DTM.RESETDTM.Type [None | Generic]Data Trace Module (DTM) - generic, CoreSight compliant trace source moduleIf specified it will be considered in trace recording and trace data can be accessed afterwards.DTM module itself will not be controlled by the debugger.

DWT.Base <address>DWT.RESETData Watchpoint and Trace unit (DWT) - ARM debug module on Cortex-M coresNormally fix address at 0xE0001000 (default).

EPM.Base <address>EPM.RESETEmulation Pin Manager (EPM) - Texas InstrumentsIt will be used to prepare chip pins for trace output.

ETB2AXI.Base <address>ETB2AXI.RESETETB to AXI moduleSimilar to an ETR.

ETB.ATBSource <source>ETB.Base <address>ETB.RESETETB.Size <size>Embedded Trace Buffer (ETB) - ARM CoreSight moduleEnables trace to be stored in a dedicated SRAM. The trace data will be read out through the debug port after the capturing has finished.

ETF.ATBSource <source>ETF.Base <address>ETF.RESETEmbedded Trace FIFO (ETF) - ARM CoreSight moduleOn-chip trace buffer used to lower the trace bandwidth peaks.

Hexagon Debugger 48 ©1989-2019 Lauterbach GmbH

Page 49: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

ETM.Base <address>ETM.RESETEmbedded Trace Macrocell (ETM) - ARM CoreSight moduleProgram Trace Macrocell (PTM) - ARM CoreSight moduleTrace source providing information about program flow and data accesses of a core.The ETM commands will be used even for PTM.

ETR.ATBSource <source>ETR.Base <address>ETR.RESETEmbedded Trace Router (ETR) - ARM CoreSight moduleEnables trace to be routed over an AXI bus to system memory or to any other AXI slave.

FUNNEL.ATBSource <sourcelist>FUNNEL.Base <address>FUNNEL.Name <string>FUNNEL.PROGrammable [ON | OFF]FUNNEL.RESETCoreSight Trace Funnel (CSTF) - ARM CoreSight moduleCombines multiple trace sources onto a single trace bus (ATB = AMBA Trace Bus)

HSM.Base <address>HSM.RESETHardware Security Module (HSM) - Infineon

HTM.Base <address>HTM.RESETHTM.Type [CoreSight | WPT]AMBA AHB Trace Macrocell (HTM) - ARM CoreSight moduleTrace source delivering trace data of access to an AHB bus.

ICE.Base <address>ICE.RESETICE-Crusher (ICE) - Texas Instruments

ITM.Base <address>ITM.RESETInstrumentation Trace Macrocell (ITM) - ARM CoreSight moduleTrace source delivering system trace information e.g. sent by software in printf() style.

L2CACHE.Base <address>L2CACHE.RESETL2CACHE.Type [NONE | Generic | L210 | L220 | L2C-310 | AURORA | AURORA2]Level 2 Cache ControllerThe debugger might need to handle the controller to ensure cache coherency for debugger operation.

OCP.Base <address>OCP.RESETOCP.TraceID <id>OCP.Type <type>Open Core Protocol watchpoint unit (OCP) - Texas InstrumentsTrace source module delivering bus trace information to a system trace module.

Hexagon Debugger 49 ©1989-2019 Lauterbach GmbH

Page 50: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

PMI.Base <address>PMI.RESETPMI.TraceID <id>Power Management Instrumentation (PMI) - Texas InstrumentsTrace source reporting power management events to a system trace module.

RTP.Base <address>RTP.PerBase <address>RTP.RamBase <address>RTP.RESETRAM Trace Port (RTP) - Texas InstrumentsTrace source delivering trace data about memory interface usage.

SC.Base <address>SC.RESETSC.TraceID <id>Statistic Collector (SC) - Texas InstrumentsTrace source delivering statistic data about bus traffic to a system trace module.

STM.Base <address>STM.Mode [NONE | XTIv2 | SDTI | STP | STP64 | STPv2]STM.RESETSTM.Type [None | Generic | ARM | SDTI | TI]System Trace Macrocell (STM) - MIPI, ARM CoreSight, othersTrace source delivering system trace information e.g. sent by software in printf() style.

TPIU.ATBSource <source>TPIU.Base <address>TPIU.RESETTPIU.Type [CoreSight | Generic]Trace Port Interface Unit (TPIU) - ARM CoreSight moduleTrace sink sending the trace off-chip on a parallel trace port (chip pins).

Hexagon Debugger 50 ©1989-2019 Lauterbach GmbH

Page 51: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

<parameters> which are “Deprecated”

In the last years the chips and its debug and trace architecture became much more complex. Especially the CoreSight trace components and their interconnection on a common trace bus required a reform of our commands. The new commands can deal even with complex structures.

… BASE <address> This command informs the debugger about the start address of the register block of the component. And this way it notifies the existence of the component. An on-chip debug and trace component typically provides a control register block which needs to be accessed by the debugger to control this component.

Example: SYStem.CONFIG ETMBASE APB:0x8011c000

Meaning: The control register block of the Embedded Trace Macrocell (ETM) starts at address 0x8011c000 and is accessible via APB bus.

In an SMP (Symmetric MultiProcessing) debug session you can enter for the components BMC, CORE, CTI, ETB, ETF, ETM, ETR a list of base addresses to specify one component per core.

Example assuming four cores: “SYStem.CONFIG COREBASE 0x80001000 0x80003000 0x80005000 0x80007000”.

COREBASE (old syntax: DEBUGBASE): Some cores e.g. Cortex-A or Cortex-R do not have a fix location for their debug register which are used for example to halt and start the core. In this case it is essential to specify its location before you can connect by e.g. SYStem.Up.

PERBASE and RAMBASE are needed for the RAM Trace Port (RTP) which is available on some derivatives from Texas Instruments. PERBASE specifies the base address of the core peripheral registers which accesses shall be traced, RAMBASE is the start address of RAM which accesses shall be traced. The trace packages include only relative addresses to PERBASE and RAMBASE.

For a list of possible components including a short description see Components and Available Commands.

Hexagon Debugger 51 ©1989-2019 Lauterbach GmbH

Page 52: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

… PORT <port> Informs the debugger about which trace source is connected to which input port of which funnel. A CoreSight trace funnel provides 8 input ports (port 0-7) to combine the data of various trace sources to a common trace stream.

Example: SYStem.CONFIG STMFUNNEL2PORT 3

Meaning: The System Trace Module (STM) is connected to input port #3 on FUNNEL2.

On an SMP debug session some of these commands can have a list of <port> parameter.

In case there are dedicated funnels for the ETB and the TPIU their base addresses are specified by ETBFUNNELBASE, TPIUFUNNELBASE respectively. And the funnel port number for the ETM are declared by ETMETBFUNNELPORT, ETMTPIUFUNNELPORT respectively.

TRACE... stands for the ADTF trace source module.

For a list of possible components including a short description see Components and Available Commands.

BYPASS <seq> With this option it is possible to change the JTAG bypass instruction pattern for other TAPs. It works in a multi-TAP JTAG chain for the IRPOST pattern, only, and is limited to 64 bit. The specified pattern (hexadecimal) will be shifted least significant bit first. If no BYPASS option is used, the default value is “1” for all bits.

CTICONFIG <type> Informs about the interconnection of the core Cross Trigger Interfaces (CTI). Certain ways of interconnection are common and these are supported by the debugger e.g. to cause a synchronous halt of multiple cores.

NONE: The CTI is not used by the debugger.ARMV1: This mode is used for ARM7/9/11 cores which support synchronous halt, only.ARMPostInit: Like ARMV1 but the CTI connection differs from the ARM recommendation. OMAP3: This mode is not yet used.TMS570: Used for a certain CTI connection used on a TMS570 derivative.CortexV1: The CTI will be configured for synchronous start and stop via CTI. It assumes the connection of DBGRQ, DBGACK, DBGRESTART signals to CTI are done as recommended by ARM. The CTIBASE must be notified. “CortexV1” is the default value if a Cortex-A/R core is selected and the CTIBASE is notified.QV1: This mode is not yet used.

Hexagon Debugger 52 ©1989-2019 Lauterbach GmbH

Page 53: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Deprecated and New Commands

In the following you find the list of deprecated commands which can still be used for compatibility reasons and the corresponding new command.

SYStem.CONFIG <parameter>

DTMCONFIG [ON | OFF] Informs the debugger that a customer proprietary Data Trace Message (DTM) module is available. This causes the debugger to consider this source when capturing common trace data. Trace data from this module will be recorded and can be accessed later but the unknown DTM module itself will not be controlled by the debugger.

FILLDRZERO [ON | OFF] This changes the bypass data pattern for other TAPs in a multi-TAP JTAG chain. It changes the pattern from all “1” to all “0”. This is a workaround for a certain chip problem. It is available on the ARM9 debugger, only.

TIOCPTYPE <type> Specifies the type of the OCP module from Texas Instruments (TI).

view Opens a window showing most of the SYStem.CONFIG settings and allows to modify them.

<parameter>:(Deprecated)

<parameter>:(New)

BMCBASE <address> BMC.Base <address>

BYPASS <seq> CHIPIRPRE <bits>CHIPIRLENGTH <bits>CHIPIRPATTERN.Alternate <pattern>

COREBASE <address> COREDEBUG.Base <address>

CTIBASE <address> CTI.Base <address>

CTICONFIG <type> CTI.Config <type>

DEBUGBASE <address> COREDEBUG.Base <address>

DTMCONFIG [ON | OFF] DTM.Type.Generic

DTMETBFUNNELPORT <port> FUNNEL4.ATBSource DTM <port> (1)

DTMFUNNEL2PORT <port> FUNNEL2.ATBSource DTM <port> (1)

DTMFUNNELPORT <port> FUNNEL1.ATBSource DTM <port> (1)

DTMTPIUFUNNELPORT <port> FUNNEL3.ATBSource DTM <port> (1)

DWTBASE <address> DWT.Base <address>

ETB2AXIBASE <address> ETB2AXI.Base <address>

Hexagon Debugger 53 ©1989-2019 Lauterbach GmbH

Page 54: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

ETBBASE <address> ETB1.Base <address>

ETBFUNNELBASE <address> FUNNEL4.Base <address>

ETFBASE <address> ETF1.Base <address>

ETMBASE <address> ETM.Base <address>

ETMETBFUNNELPORT <port> FUNNEL4.ATBSource ETM <port> (1)

ETMFUNNEL2PORT <port> FUNNEL2.ATBSource ETM <port> (1)

ETMFUNNELPORT <port> FUNNEL1.ATBSource ETM <port> (1)

ETMTPIUFUNNELPORT <port> FUNNEL3.ATBSource ETM <port> (1)

FILLDRZERO [ON | OFF] CHIPDRPRE 0CHIPDRPOST 0CHIPDRLENGTH <bits_of_complete_dr_path>CHIPDRPATTERN.Alternate 0

FUNNEL2BASE <address> FUNNEL2.Base <address>

FUNNELBASE <address> FUNNEL1.Base <address>

HSMBASE <address> HSM.Base <address>

HTMBASE <address> HTM.Base <address>

HTMETBFUNNELPORT <port> FUNNEL4.ATBSource HTM <port> (1)

HTMFUNNEL2PORT <port> FUNNEL2.ATBSource HTM <port> (1)

HTMFUNNELPORT <port> FUNNEL1.ATBSource HTM <port> (1)

HTMTPIUFUNNELPORT <port> FUNNEL3.ATBSource HTM <port> (1)

ITMBASE <address> ITM.Base <address>

ITMETBFUNNELPORT <port> FUNNEL4.ATBSource ITM <port> (1)

ITMFUNNEL2PORT <port> FUNNEL2.ATBSource ITM <port> (1)

ITMFUNNELPORT <port> FUNNEL1.ATBSource ITM <port> (1)

ITMTPIUFUNNELPORT <port> FUNNEL3.ATBSource ITM <port> (1)

PERBASE <address> RTP.PerBase <address>

RAMBASE <address> RTP.RamBase <address>

RTPBASE <address> RTP.Base <address>

SDTIBASE <address> STM1.Base <address>STM1.Mode SDTISTM1.Type SDTI

STMBASE <address> STM1.Base <address>STM1.Mode STPV2STM1.Type ARM

STMETBFUNNELPORT <port> FUNNEL4.ATBSource STM1 <port> (1)

STMFUNNEL2PORT <port> FUNNEL2.ATBSource STM1 <port> (1)

STMFUNNELPORT <port> FUNNEL1.ATBSource STM1 <port> (1)

STMTPIUFUNNELPORT <port> FUNNEL3.ATBSource STM1 <port> (1)

Hexagon Debugger 54 ©1989-2019 Lauterbach GmbH

Page 55: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

(1) Further “<component>.ATBSource <source>” commands might be needed to describe the full trace data path from trace source to trace sink.

SYStem.CONFIG MSA Enable translation by system MMU

Default: 0xffffffff (disabled).

Only available for HexagonV5 and later.

When specifying the MSA register address, L2-address translation by the on-chip system-level MMU is enabled. See your SoC documentation for the MSA register address.

The debugger knows from the TLB or page table entry whether a resolved address is to be translated once more by the System MMU. In case the debugger or OS Awareness cannot resolve this second translation the SoC can be instructed to do it by setting bit 2 in this register.

The user can manually trigger this translation using memory class SD:. This assumes that the core MMU translation has already been performed.

TIADTFBASE <address> ADTF.Base <address>

TIDRMBASE <address> DRM.Base <address>

TIEPMBASE <address> EPM.Base <address>

TIICEBASE <address> ICE.Base <address>

TIOCPBASE <address> OCP.Base <address>

TIOCPTYPE <type> OCP.Type <type>

TIPMIBASE <address> PMI.Base <address>

TISCBASE <address> SC.Base <address>

TISTMBASE <address> STM1.Base <address>STM1.Mode STPSTM1.Type TI

TPIUBASE <address> TPIU.Base <address>

TPIUFUNNELBASE <address> FUNNEL3.Base <address>

TRACEETBFUNNELPORT <port> FUNNEL4.ATBSource ADTF <port> (1)

TRACEFUNNELPORT <port> FUNNEL1.ATBSource ADTF <port> (1)

TRACETPIUFUNNELPORT <port> FUNNEL3.ATBSource ADTF <port> (1)

view state

Format: SYStem.CONFIG MSA <address>

Hexagon Debugger 55 ©1989-2019 Lauterbach GmbH

Page 56: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.CPU Select CPU type

Default: HexagonV2.

Select your CPU.

SYStem.CpuAccess Run-time CPU access (intrusive)

This option declares if an intrusive memory access can take place while the CPU is executing code. To perform this access, the debugger stops the CPU shortly, performs the access and then restarts the CPU.

The run-time memory access has to be activated for each window by using the memory class E: (e.g. Data.dump ED:0x000000) or by using the format option %E (e.g. Var.View %E var1).

Format: SYStem.CPU <cpu>

<cpu>: HexagonV2 |HexagonV3 | HexagonV3L | HexagonV3M | HexagonV3C |HexagonV4 | HexagonV4L | HexagonV4M | HexagonV4C |HexagonV5 | HexagonV55 | HexagonV56 |HexagonV60

Format: SYStem.CpuAccess <mode>

<mode>: Enable | Denied | Nonstop

Enable Stop the CPU shortly to perform a memory read or write while the program execution is running.Each short stop takes 1…100 ms depending on the speed of the debug interface and on the size of the read/write accesses required.

Denied No intrusive memory read or write is possible while the CPU is executing the program.

Nonstop The program execution can not be stopped and the real-time behavior of the CPU is not affected.Nonstop reduces the functionality of the debugger to:• Run-time access to memory and variables• Trace displayThe debugger inhibits the following:• To stop the program execution• All features of the debugger that are intrusive (e.g. spot breakpoints, per-

formance analysis via StopAndGo, conditional breakpoints etc.)

Hexagon Debugger 56 ©1989-2019 Lauterbach GmbH

Page 57: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.JtagClock Select clock for JTAG communication

Default: 10.0 MHz.

This command selects the frequency of the JTAG clock, which is used to communicate with the Hexagon core. The maximum reachable frequency is target dependent, the default should be fine. If no unit is specified, Hz is assumed.The frequency modes RTCK, ARTCK, CTCK and CRTCK are not supported by Hexagon.

SYStem.LOCK Tristate the JTAG port

Default: OFF.

If the system is locked, no access to the JTAG port will be performed by the debugger. While locked the JTAG connector of the debugger is tristated. The intention of the SYStem.LOCK command is, for example, to give JTAG access to another tool. The process can also be automated, see SYStem.CONFIG TriState.

It must be ensured that the state of the Hexagon JTAG state machine remains unchanged while the system is locked. To ensure correct hand-over, the options SYStem.CONFIG TAPState and SYStem.CONFIG TCKLevel must be set properly. They define the TAP state and TCK level which is selected when the debugger switches to tristate mode. Please note: nTRST must have a pull-up resistor on the target, EDBGRQ must have a pull-down resistor.

Format: SYStem.JtagClock <frequency>SYStem.BdmClock (deprecated)

<frequency>: 1.0 kHz…80.0 MHz

Format: SYStem.LOCK [ON | OFF]

There is a single cable contact on the casing of the debug cable which can be used to detect if the JTAG connector of the debugger is tristated. If tristated also this signal is tristated, otherwise it is pulled low.

Hexagon Debugger 57 ©1989-2019 Lauterbach GmbH

Page 58: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.MemAccess Run-time memory access (non-intrusive)

Default: CPU.

This option declares if and how a non-intrusive memory access can take place while the CPU is executing code. Although the CPU is not halted, run-time memory access creates an additional load on the processor’s internal data bus. Default access mode is CPU. The currently selected run-time memory access mode is printed in the state line.

The run-time memory access has to be activated for each window by using the memory class E: (e.g. Data.dump ED:0x000000) or by using the format option %E (e.g. Var.View %E var1).

SYStem.Option MMUSPACES Separate address spaces by space IDs

Default: OFF.

Enables the use of space IDs for logical addresses to support multiple address spaces.

Format: SYStem.MemAccess <mode>SYStem.ACCESS (deprecated)

<mode>: CPU | Denied | DAP

CPU The debugger performs memory accesses via a dedicated CPU interface. Hexagon has no such CPU interface.

Denied Non-intrusive memory access is disabled while the CPU is executing code. Instead intrusive accesses can be configured with SYStem.CpuAccess.

DAP A run-time memory access is done via the Debug Access Port (DAP). This is only possible if a DAP is available on the SoC and if the memory bus is connected to it.Not possible on the instruction set simulator.

Format: SYStem.Option MMUSPACES [ON | OFF]SYStem.Option MMUspaces [ON | OFF] (deprecated)SYStem.Option MMU [ON | OFF] (deprecated)

Hexagon Debugger 58 ©1989-2019 Lauterbach GmbH

Page 59: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

For an explanation of the TRACE32 concept of address spaces (zone spaces, MMU spaces, and machine spaces), see “TRACE32 Glossary” (glossary.pdf).

Examples:

NOTE: SYStem.Option MMUSPACES should not be set to ON if only one translation table is used on the target.

If a debug session requires space IDs, you must observe the following sequence of steps:

1. Activate SYStem.Option MMUSPACES.

2. Load the symbols with Data.LOAD.

Otherwise, the internal symbol database of TRACE32 may become inconsistent.

;Dump logical address 0xC00208A belonging to memory space with ;space ID 0x012A:Data.dump D:0x012A:0xC00208A

;Dump logical address 0xC00208A belonging to memory space with ;space ID 0x0203:Data.dump D:0x0203:0xC00208A

Hexagon Debugger 59 ©1989-2019 Lauterbach GmbH

Page 60: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.Mode Select target reset mode

Default: Down.

When debugging is prohibited or the Hexagon core is not correctly configured, establishing the debug connection fails and the debugger will revert into the Down state. One of the following error messages will be printed, and the AREA window shows some additional information. See Hexagon Security for more information on the Hexagon debug modes.

Format: SYStem.Mode <mode>

<mode>: DownNoDebugGoAttachStandByUp

Down Stops the JTAG communication to the core.

NoDebug Releases the core from reset without establishing a JTAG connection to the core. The debug connector is tristated and behaves as if it was not connected. The core will start running.

Go Establishes a JTAG connection, initializes the debug interface. The core is reset and will start running from the reset vector.

Attach User program remains running (no reset) and the debug interface is initialized. After this command the user program can be stopped with the break command or if a break condition occurs.

StandBy The target processor waits for target power and clock. When both are active it starts as fast as possible. This functionality is not available on all targets.

Up Establishes a JTAG connection, initializes the debug interface. The core is reset and will start running from the reset vector. If the application has enabled debugging, the DSP will halt at the initial software breakpoint, if set by the application.

Emulator debug port secured

Debugging is either permitted by the application or untrusted debugging has been selected (not supported by TRACE32).

Emulator debug port locked

The Hexagon core was not enabled or configured by the ARM core. Either it is still in power down mode (all Hexagon versions) or in reset (Hexagon v4 and newer).

Emulator debug port fail Setting the debug mode by the application failed. The debugger can communicate with the debug system but gets no further access.

Hexagon Debugger 60 ©1989-2019 Lauterbach GmbH

Page 61: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

The “Emulate” LED on the debug module is ON when the debug mode is active and the CPU is running.

SYStem.Option CPU specific commands

The SYStem.Options are a class of Architecture and CPU specific commands.

SYStem.Option BUGFIX Workaround for single-stepping an RTE instruction

Default: OFF (Hexagon v1: ON).

Workaround for single-stepping an RTE instruction on Hexagon v1. Do not enable on other Hexagon variants.

SYStem.Option DCFREEZE Do not invalidate cache

Default: ON.

Instruct the debugger whether to provide data cache coherency on a memory access or not. The behavior is different for the various Hexagon variants:

Hexagon v1, v2 and v3 behave as follows when performing a memory access via memory classes D:, DC: and L2:

• If enabled and L1 data cache is enabled, the debugger will disable L1 caches. This assures cache coherency for L1 cache state and content.

• If disabled, all accesses are performed via caches as far as they are enabled. This usually allocates new lines in the cache and so alters the cache states.

In case of any issues with cache content, try to disable DCFREEZE for Hexagon v1, v2 and v3.

When SYStem.Option SRST is OFF, only a Hexagon internal reset is performed. The reset has no impact on other cores in the same chip (depending on the design). This internal reset is also performed when SYStem.CONFIG Slave is enabled.

Format: SYStem.Option BUGFIX [ON | OFF]

Format: SYStem.Option DCFREEZE [ON | OFF]

Hexagon Debugger 61 ©1989-2019 Lauterbach GmbH

Page 62: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Hexagon v4 behaves as follows when performing a memory access via memory classes P:, IC:, D:, DC: and L2:

• If enabled, the debugger will perform a non-destructive read access regarding the L1 data cache by using the memw_phys() instruction.

• If disabled, the debugger will perform a destructive read access which will result in newly allocated cache lines in L1 data cache.

For Hexagon v4, enabling DCFREEZE is recommended.

SYStem.Option CLADE Enable debugger support for CLADE

Default: OFF.

When enabled, TRACE32 will handle RAM regions compressed using CLADE.

SYStem.Option CLADEDICT Loade CLADE dictionary from file

Loads the clade dictionary from a file.

SYStem.Option CLADEPARAM Define the CLADE address parameters

Inform TRACE32 about the location of the compressed memory regions in memory.

tbd.

Format: SYStem.Option CLADE [ON | OFF]

Format: SYStem.Option CLADEDICT <file>

Format: SYStem.Option CLADEPARAM <high> <low> <main> <excp_high> <excp_low> <excp_low_small> […]

Hexagon Debugger 62 ©1989-2019 Lauterbach GmbH

Page 63: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.Option CLADEREAD Use hardware for reading compressed RAM

Default: ON. !!! tbd.

When enabled, TRACE32 will read compressed memory using CLADE hardware. When disabled, TRACE32 will use the built-in CLADE library.

SYStem.Option ICFLUSH Flush instruction cache at “Go” or “Step”

Default: ON.

Format: SYStem.Option CLADEREAD [ON | OFF]

Format: SYStem.Option ICFLUSH [ON | OFF]

Hexagon Debugger 63 ©1989-2019 Lauterbach GmbH

Page 64: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

In case the instruction memory is modified, Instruction Cache(s) have to be kept coherent with RAM, otherwise modifications (e.g. Software Breakpoints) may not take effect. There are two strategies how the invalidation is performed:

• If ICFLUSH is enabled, the entire L1 instruction cache is unconditionally invalidated before program execution is resumed (executing a Go or Step command). The entire L2 cache is also invalidated in the following cases:

Hexagon v2: in case L2 cache is configured.

Hexagon v3: in case L2 cache is configured and in write-through mode

Hexagon v4: never

In case L2 cache is configured but can not be invalidated completely, e.g. because it is in copy-back mode or in case of Hexagon v4, L2 cache coherence is maintained as for the ICFLUSH disabled case.

• If ICFLUSH is disabled, the affected lines in L1 instruction cache are invalidated in the instant of the memory modification. The affected L2 cache lines are also invalidated, but note that this is performed by invalidation of the corresponding L1 data cache lines.

SYStem.Option IMASKASM Disable interrupts while single stepping

Default: OFF.

If enabled, the debug core will disable all interrupts for the CPU when single stepping assembler instructions. No hardware interrupt will be executed during single-step operations. When you execute a Go command, the hardware interrupts will be enabled again, according to the system control registers.

SYStem.Option IMASKHLL Disable interrupts while HLL single stepping

Default: OFF.

In case ICFLUSH is disabled, the instruction cache is only invalidated when writing via memory class P: or IC:.

Note that Hexagon v1 has no L2 cache implemented.

Format: SYStem.Option IMASKASM [ON | OFF]

Format: SYStem.Option IMASKHLL [ON | OFF]

Hexagon Debugger 64 ©1989-2019 Lauterbach GmbH

Page 65: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

If enabled, the debug core will disable all interrupts for the CPU during HLL single-step operations. When you execute a Go command, the hardware interrupts will be enabled again, according to the system control registers. This option should be used in conjunction with SYStem.Option IMASKASM.

SYStem.Option ISDBSoftBreakFix Workaround for prefetch issue

Default: OFF.

A bug in the prefetcher causes ISDB to lock when a breakpoint is hit. The debugger is then not able to communicate with Hexagon any more. This bug affects onchip and software breakpoints.

The debugger’s workaround is to write an ISYNC instruction right after the breakpoint instruction. This has the following restrictions:

• Setting onchip breakpoints is not possible. Use software breakpoints instead.

• Setting software breakpoints at consecutive addresses is not possible.

• The instruction followed by the software breakpoint must not be the target of a jump. The user has to ensure this when setting the breakpoint.

SYStem.Option PC PC parking position

Default: 0xffffffff

If <base> is programmed to a different value than 0xffffffff, the PC will parked at the given address while the thread is breaked. This is a recommended workaround for several silicon issues.

Select a valid physical address which has no jump or call instruction. It is recommended not to park in the middle of a multi-instruction packet.

Format: SYStem.Option ISDBSoftBreakFix [ON | OFF]

NOTE: This workaround is only for early HexagonV60 devices only used by Qualcomm internally. Only enable this option when your device is affected by this issue.

Format: SYStem.Option PC <base>

Hexagon Debugger 65 ©1989-2019 Lauterbach GmbH

Page 66: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.RESetOut Reset target without reset of debug port

This command resets the DSP via the debug registers in ISDB. Only the DSP will reset, not the debug port or the target system. This function only works when the CPU is in SYStem.Mode Up.

SYStem.Option REVision Define default value for REV register

Default: 0x00000000

Allows to specify a default value for the REV register. Applications evaluate this register to get information about the Hexagon version and implemented features.

This command is available in the TRACE32 simulator only. The command becomes effective after the next SYStem.Mode Up or Register.Init and will be permanent. Use the Register.Set REV to change the REV register temporary and immediately.

SYStem.Option SRST Reset via SRST line

Default: OFF.

When enabled (ON), the debugger also resets the core via the nSRST line of the JTAG connector. It also holds the core in reset while in SYStem.Mode Down. When disabled, only Hexagon specific resets will be generated if possible.

On some evaluation boards where the nSRST line is also connected to other cores and chips a reset via nSRST will have unwanted effects.

Format: SYStem.RESetOut

Format: SYStem.Option REVision <value>

Format: SYStem.Option SRST [ON | OFF]

Hexagon Debugger 66 ©1989-2019 Lauterbach GmbH

Page 67: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

SYStem.StuffInstruction Execute stuff instruction

Execute a stuff instruction without modifying the instruction memory. The instruction will be executed in the thread’s current mode.

SYStem.Option TCMBase Base address of the TCM

Default: 0x00000000 (disabled)

Only required for Hexagon v2 and v3, ignored for all other Hexagon versions.

The location of the Tightly Coupled Memory (TCM) depends on the device. As the L2 cache is implemented in the TCM, the debugger needs to know where to look for it. Disabling the TCM (setting the base address to 0x00000000) disables the L2 cache support of TRACE32.

SYStem.Option TLBINV Invalidate TLB while MMU is off

Default: OFF

This is a workaround necessary for some early Hexagon v5 devices. When the debugger accesses memory while the MMU is OFF, the TLB might get corrupted. Enabling this option ensures that the debugger invalidates all TLB entries when disabling the MMU. When enabling again, all entries are restored.

SYStem.state Display SYStem.state window

Displays the SYStem.state window for Hexagon.

Format: SYStem.StuffInstruction <instruction>

Format: SYStem.Option TCMBase <address>

Format: SYStem.Option TLBINV [ON | OFF]

Format: SYStem.state

Hexagon Debugger 67 ©1989-2019 Lauterbach GmbH

Page 68: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CPU specific MMU Commands

MMU.DUMP Page wise display of MMU translation table

Displays the contents of the CPU specific MMU translation table.

• If called without parameters, the complete table will be displayed.

• If the command is called with either an address range or an explicit address, table entries will only be displayed if their logical address matches with the given parameter.

Format: MMU.DUMP <table> [<range> | <address> | <range> <root> | <address> <root>] MMU.<table>.dump (deprecated)

<table>: PageTableKernelPageTableTaskPageTable <task_magic> | <task_id> | <task_name> | <space_id>:0x0<cpu_specific_tables>

<root> The <root> argument can be used to specify a page table base address deviating from the default page table base address. This allows to display a page table located anywhere in memory.

PageTable Displays the current MMU translation table entries of the CPU. This command reads all tables the CPU currently uses for MMU translation and displays the table entries.

KernelPageTable Displays the MMU translation table of the kernel.If specified with the MMU.FORMAT command, this command reads the MMU translation table of the kernel and displays its table entries.

TaskPageTable <task_magic> | <task_id> | <task_name> | <space_id>:0x0

Displays the MMU translation table entries of the given process. Specify one of the TaskPageTable arguments to choose the process you want.In MMU-based operating systems, each process uses its own MMU translation table. This command reads the table of the specified process, and displays its table entries.• For information about the first three parameters, see “What to

know about the Task Parameters” (general_ref_t.pdf).• See also the appropriate OS Awareness Manuals.

Hexagon Debugger 68 ©1989-2019 Lauterbach GmbH

Page 69: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CPU specific tables in MMU.DUMP <table>

TLB Displays the contents of the Translation Lookaside Buffer.

MAP Displays the contents of the MAP table.

VTLB Displays the contents of a virtual TLB (VTLB) translation table.If SYStem.Option.MMUSPACES is set to OFF, the list of VTLB entries is sorted ascending by address only.If SYStem.Option.MMUSPACES is set to ON, the list of VTLB entries is sorted by the ASID first and then by the address.

Hexagon Debugger 69 ©1989-2019 Lauterbach GmbH

Page 70: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

MMU.List Compact display of MMU translation table

Lists the address translation of the CPU-specific MMU table.

• If called without address or range parameters, the complete table will be displayed.

• If called without a table specifier, this command shows the debugger-internal translation table. See TRANSlation.List.

• If the command is called with either an address range or an explicit address, table entries will only be displayed if their logical address matches with the given parameter.

Format: MMU.List <table> [<range> | <address> | <range> <root> | <address> <root>] MMU.<table>.List (deprecated)

<table>: PageTableKernelPageTableTaskPageTable <task_magic> | <task_id> | <task_name> | <space_id>:0x0

<root> The <root> argument can be used to specify a page table base address deviating from the default page table base address. This allows to display a page table located anywhere in memory.

PageTable Lists the current MMU translation of the CPU. This command reads all tables the CPU currently uses for MMU translation and lists the address translation.

KernelPageTable Lists the MMU translation table of the kernel.If specified with the MMU.FORMAT command, this command reads the MMU translation table of the kernel and lists its address translation.

TaskPageTable <task_magic> | <task_id> | <task_name> | <space_id>:0x0

Lists the MMU translation of the given process. Specify one of the TaskPageTable arguments to choose the process you want.In MMU-based operating systems, each process uses its own MMU translation table. This command reads the table of the specified process, and lists its address translation.• For information about the first three parameters, see “What to

know about the Task Parameters” (general_ref_t.pdf).• See also the appropriate OS Awareness Manuals.

Hexagon Debugger 70 ©1989-2019 Lauterbach GmbH

Page 71: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

MMU.MAP Translations from ELF file memory load map

MMU.MAP.dump Display addresses from ELF file memory load map

Shows the logical and associated physical addresses of the program sections loaded from an ELF file.This command is an alias for sYmbol.List.MAP.

MMU.MAP.SCAN Load MMU table from ELF file

Loads the logical and associated physical addresses of the program sections loaded from an ELF file to the debugger-internal translation table.The loaded address translation can be viewed with TRANSlation.List.

See also MMU.MAP.dump.

Format: MMU.MAP.dump

Format: MMU.MAP.SCAN

Hexagon Debugger 71 ©1989-2019 Lauterbach GmbH

Page 72: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

MMU.SCAN Load MMU table from CPU

Loads the CPU-specific MMU translation table from the CPU to the debugger-internal static translation table.

• If called without parameters, the complete page table will be loaded. The list of static address translations can be viewed with TRANSlation.List.

• If the command is called with either an address range or an explicit address, page table entries will only be loaded if their logical address matches with the given parameter.

Use this command to make the translation information available for the debugger even when the program execution is running and the debugger has no access to the page tables and TLBs. This is required for the real-time memory access. Use the command TRANSlation.ON to enable the debugger-internal MMU table.

Format: MMU.SCAN <table> [<range> <address>]MMU.<table>.SCAN (deprecated)

<table>: PageTableKernelPageTableTaskPageTable <task_magic> | <task_id> | <task_name> | <space_id>:0x0ALL<cpu_specific_tables>

PageTable Loads the current MMU address translation of the CPU. This command reads all tables the CPU currently uses for MMU translation, and copies the address translation into the debugger-internal static translation table.

KernelPageTable Loads the MMU translation table of the kernel.If specified with the MMU.FORMAT command, this command reads the table of the kernel and copies its address translation into the debugger-internal static translation table.

TaskPageTable <task_magic> | <task_id> | <task_name> | <space_id>:0x0

Loads the MMU address translation of the given process. Specify one of the TaskPageTable arguments to choose the process you want.In MMU-based operating systems, each process uses its own MMU translation table. This command reads the table of the specified process, and copies its address translation into the debugger-internal static translation table.• For information about the first three parameters, see “What to know

about the Task Parameters” (general_ref_t.pdf).• See also the appropriate OS Awareness Manual.

ALL Loads all known MMU address translations. This command reads the OS kernel MMU table and the MMU tables of all processes and copies the complete address translation into the debugger-internal static translation table. See also the appropriate OS Awareness Manual.

Hexagon Debugger 72 ©1989-2019 Lauterbach GmbH

Page 73: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CPU specific tables in MMU.SCAN <table>

TLB Loads the translation table from the CPU to the debugger-internal translation table.

MAP Loads the MAP table from the CPU to the debugger-internal translation table.

VTLB Loads the translations from a virtual TLB (VTLB) translation table to the debugger-internal translation table.If SYStem.Option.MMUSPACES is set to OFF, the VTLB entries will be scanned, disregarding their ASID field.If SYStem.Option.MMUSPACES is set to ON, the list of VTLB entries will be scanned and their ASID field will be copied to the space ID of the new static translation entry.

Hexagon Debugger 73 ©1989-2019 Lauterbach GmbH

Page 74: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

MMU.Set Write to MMU on processor

MMU.TLB Scan or dump MMU TLB entries

Format: MMU.Set [TLB [<index> [<tlb0> [<tlb1>]]]]

TLB Writes data to the processor’s TLB.

index Index (entry) in TLB table

tlb0tlb1

Data of the TLB entries

Format: MMU.TLB.<sub_cmd>

<sub_cmd>: dump | SCAN

dump Displays a table of all entries from the CPU TLB table.

SCAN Loads the TLB table entries from the CPU to the debugger-internal MMU table.

Hexagon Debugger 74 ©1989-2019 Lauterbach GmbH

Page 75: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

MMU.VTLB Scan or dump VTLB entries

Format: MMU.VTLB.<sub_cmd>

<sub_cmd>: dump | SCAN

dump Displays the entries of a virtual TLB (VTLB) translation table.See MMU.DUMP.VTLB.

SCAN Loads the translations from a virtual TLB (VTLB) translation table to the debugger-internal translation table.See MMU.SCAN.VTLB.

Hexagon Debugger 75 ©1989-2019 Lauterbach GmbH

Page 76: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

CPU specific BenchMarkCounter Commands

The Hexagon-ETM contains six counters which can record various events related to DSP performance.

The benchmark counters can be read at run-time. The counter values are periodically packed into so-called profiling packets and sent out through the trace port.

For information about architecture-independent BMC commands, refer to “BMC” (general_ref_b.pdf).

For information about architecture-specific BMC commands, see command descriptions below.

BMC.COUNTER<n> Specify event count

Specifies which event is counted by an event counter.

Format: BMC.COUNTER<n> <event>

<event>: DCMISS | DCCCONFLICT | ICMISS | ICSTALL | ITLBMISS | DTLBMISS | STALLS

DCMISS data cache misses

DCCONFLICT data cache conflicts

ICMISS instruction cache misses

ICSTALL instruction cache stall-cycles

ITLBMISS itlb misses

DTLBMISS dtlb misses

STALLS all stall cycles

BMC.COUNTER1 ICSTALL

Hexagon Debugger 76 ©1989-2019 Lauterbach GmbH

Page 77: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

BMC.CyclePeriod Specify export rate

Specifies the number of clock cycles for which an event is counted before it is sent out through the trace port.

BMC.OFF Disable benchmark counters

Disable TRACE32 BMC functionality.

BMC.ON Enable benchmark counters

Enable TRACE32 BMC functionality.

BMC.SELect Select counter for statistic analysis

The exported event counter values can be combined with the exported instruction flow in order to get a clearer understanding of the program behavior. The command BMC.SELect allows to specify which counter is combined with the instruction flow to get a statistical evaluation.

Format: BMC.CyclePeriod <cycles>

BMC.CyclePeriod 500. ; count the specified events for; 500 clock cycles,; pack the result in a profiling; packet and sent it out

Format: BMC.OFF

Format: BMC.ON

Format: BMC.SELect <counter>

<counter>: COUNTER0 | COUNTER1 | …

Hexagon Debugger 77 ©1989-2019 Lauterbach GmbH

Page 78: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

BMC.SPDM Specify profiler control

BMC.COUNTER0 STALL ; counter0 counts all stall cycles

BMC.SELect COUNTER0 ; counter0 is selected for the; combination with the instruction; flow

BMC.STATistic.sYmbol ; assign the stall cycles to the; executed functions/symbol; regions

Format: BMC.SPDM [ON | OFF]

OFF(default)

The ETM region counter controls the accumulation/packet generation.

ON The SPDM controls the profiler accumulation/packet generation.

Hexagon Debugger 78 ©1989-2019 Lauterbach GmbH

Page 79: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

BMC.SPLIT Specify export rate

Format: BMC.SPLIT [ON | OFF]

OFF(default)

The specified events are counted for all hardware thread.

ON A single event is counted separately each hardware thread.

Hexagon Debugger 79 ©1989-2019 Lauterbach GmbH

Page 80: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

TrOnchip Commands

TrOnchip.ASID Extend on-chip breakpoint/trace filter by ASID

TrOnchip.ContextID Extend on-chip breakpoint/trace filter by TID

Format: TrOnchip.ASID [ON | OFF]

OFF (default)

Stop the program execution at on-chip breakpoint if the address matches.Trace filters and triggers become active if the address matches.

ON Stop the program execution at on-chip breakpoint if the address and the ASID matches.Trace filters and triggers become active if the address and the ASID matches.

Format: TrOnchip.ContextID [ON | OFF]

OFF (default)

Stop the program execution at on-chip breakpoint if the address matches.Trace filters and triggers become active if the address matches.

ON Stop the program execution at on-chip breakpoint if the address and the TID matches. Trace filters and triggers become active if the address and the TID matches.

Precondition is that the RTOS operates the TID.

Hexagon Debugger 80 ©1989-2019 Lauterbach GmbH

Page 81: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

TrOnchip.CONVert Adjust on-chip breakpoint to resources

TrOnchip.MatchASID Extend on-chip breakpoint/trace filter by ASID

TrOnchip.RESet Reset “TrOnchip” settings

Reset TrOnchip settings to default.

Format: TrOnchip.CONVert [ON | OFF]

ON (default) Adjust data value range breakpoints to suitable bitmask.

OFF TRACE32 does not accept data value range breakpoints.

; data value range is converted to a bit maskTrOnchip.CONVert ONBreak.Set my_data /Write /DATA.Byte 0x7--0x12

Format: TrOnchip.MatchASID [ON | OFF] (deprecated)TrOnchip.ASID [ON | OFF] (deprecated)Use Break.CONFIG.MatchASID instead

OFF(default)

Stop the program execution at on-chip breakpoint if the address matches.Trace filters and triggers become active if the address matches.

ON Stop the program execution at on-chip breakpoint if both the address and the ASID match.Trace filters and triggers become active if both the address and the ASID match.

Format: TrOnchip.RESet

Hexagon Debugger 81 ©1989-2019 Lauterbach GmbH

Page 82: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

TrOnchip.StepException Single stepping of exceptions and interrupts

TrOnchip.state Display on-chip trigger window

Opens the TrOnchip.state window.

Format: TrOnchip.StepException [ON | OFF]

OFF(default)

Execute exception in real-time while single stepping.

Execute interrupts in real-time while single stepping (only if SYStem.Option IMASKASM is OFF).

ON Enable single stepping for exceptions and interrupts (only if SYStem.Option IMASKASM is OFF).

Format: TrOnchip.state

Hexagon Debugger 82 ©1989-2019 Lauterbach GmbH

Page 83: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

JTAG Connector

Mechanical Description of the 20-pin Debug Cable

The connector for Hexagon is identical to the connector for ARM cores as defined by ARM:

This is a standard 20 pin double row connector (pin-to-pin spacing: 0.100 in.).

We strongly recommend to use a connector on your target with housing and having a center polarization (e.g. AMP: 2-827745-0). A connection the other way around indeed causes damage to the output driver of the debugger.

Signal Pin Pin SignalVREF-DEBUG 1 2 VSUPPLY (not used)

TRST- 3 4 GNDTDI 5 6 GND

TMS|TMSC|SWDIO 7 8 GNDTCK|TCKC|SWCLK 9 10 GND

RTCK 11 12 GNDTDO 13 14 GND

RESET- 15 16 GNDDBGRQ 17 18 GND

DBGACK 19 20 GND

Hexagon Debugger 83 ©1989-2019 Lauterbach GmbH

Page 84: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Electrical Description of the 20-pin Debug Cable

• The input and output signals are connected to a supply translating transceiver. Therefore the ICD can work in a voltage range of 0.4 … 5.0 V (5.25 V).

• VTREF is used as a sense line for the target voltage.

• nTRST, TDI, TMS, TCK are driven by the supply translating transceiver. In normal operation mode this driver is enabled, but it can be disabled to give another tool access to the JTAG port. In environments where multiple tools can access the JTAG port, it is required that there is a pull-up or pull-down resistor at TCK. This is to ensure that TCK maintains its level during a handover between different tools.

• RTCK is the return test clock signal from the target JTAG port. This signal can be used to synchronize JTAG clock with the processor clock (see SYStem.JtagClock). Hexagon does not support RTCK.

• TDO is an ICD input. It is connected to the supply translating transceiver.

• nSRST (=nRESET) is used by the debugger to reset the target CPU or to detect a reset on the target. It is driven by an open collector buffer. A pull-up resistor is included in the ICD connector. The debugger will only assert a pulse on nSRST when the SYStem.UP, the SYStem.Mode Go or the SYStem.RESetOUT command is executed.

• EDBGRQ is driven by the supply translating transceiver. This line is optional. It allows to halt the program execution by an external trigger signal.

• DBGACK is an ICD input. It is connected to the supply translating transceiver. A pull-down resistor is included in the ICD connector. This line is optional. It allows exact runtime measurement and exact triggering of other devices on a program execution halt.

• N/C (= Vsupply) is not connected in the ICD. This pin is used by debuggers of other manufacturers for supply voltage input. The ICD is self-powered.

There is an additional plug in the connector on the debug cable to the debug interface. This signal is tristated if the JTAG connector is tristated by the debugger and it is pulled low otherwise. This signal is normally not required, but can be used to detect the tristate state if more than one debug tools are connected to the same JTAG port.

Hexagon Debugger 84 ©1989-2019 Lauterbach GmbH

Page 85: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Support

Available Tools

tbd

Compilers

Target Operating Systems

Language Compiler Company Option Comment

C/C++ LLVM Qualcomm ELF/DWARF

Hexagon Debugger 85 ©1989-2019 Lauterbach GmbH

Page 86: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

3rd-Party Tool Integration

CPU Tool Company Host

WINDOWS CE PLATF. BUILDER

- Windows

CODE::BLOCKS - -C++TEST - WindowsADENEO -X-TOOLS / X32 blue river software GmbH WindowsCODEWRIGHT Borland Software

CorporationWindows

CODE CONFIDENCE TOOLS

Code Confidence Ltd Windows

CODE CONFIDENCE TOOLS

Code Confidence Ltd Linux

EASYCODE EASYCODE GmbH WindowsECLIPSE Eclipse Foundation, Inc WindowsRHAPSODY IN MICROC IBM Deutschland GmbH WindowsRHAPSODY IN C++ IBM Deutschland GmbH WindowsCHRONVIEW Inchron GmbH WindowsLDRA TOOL SUITE LDRA Technology, Inc. WindowsUML DEBUGGER LieberLieber Software

GmbHWindows

SIMULINK The MathWorks Inc. WindowsATTOL TOOLS MicroMax Inc. WindowsVISUAL BASIC INTERFACE

Microsoft Corporation Windows

LABVIEW NATIONAL INSTRUMENTS Corporation

Windows

TPT PikeTec GmbH WindowsCANTATA QA Systems Ltd WindowsRAPITIME Rapita Systems Ltd. WindowsTESSY Razorcat Development

GmbHWindows

DA-C RistanCASE WindowsTRACEANALYZER Symtavision GmbH WindowsECU-TEST TraceTronic GmbH WindowsUNDODB Undo Software LinuxTA INSPECTOR Vector WindowsVECTORCAST UNIT TESTING

Vector Software Windows

VECTORCAST CODE COVERAGE

Vector Software Windows

WINDOWS CE PLATF. BUILDER

- Windows

CODE::BLOCKS - -

Hexagon Debugger 86 ©1989-2019 Lauterbach GmbH

Page 87: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

C++TEST - WindowsADENEO -X-TOOLS / X32 blue river software GmbH WindowsCODEWRIGHT Borland Software

CorporationWindows

CODE CONFIDENCE TOOLS

Code Confidence Ltd Windows

CODE CONFIDENCE TOOLS

Code Confidence Ltd Linux

EASYCODE EASYCODE GmbH WindowsECLIPSE Eclipse Foundation, Inc WindowsRHAPSODY IN MICROC IBM Deutschland GmbH WindowsRHAPSODY IN C++ IBM Deutschland GmbH WindowsCHRONVIEW Inchron GmbH WindowsLDRA TOOL SUITE LDRA Technology, Inc. WindowsUML DEBUGGER LieberLieber Software

GmbHWindows

SIMULINK The MathWorks Inc. WindowsATTOL TOOLS MicroMax Inc. WindowsVISUAL BASIC INTERFACE

Microsoft Corporation Windows

LABVIEW NATIONAL INSTRUMENTS Corporation

Windows

TPT PikeTec GmbH WindowsCANTATA QA Systems Ltd WindowsRAPITIME Rapita Systems Ltd. WindowsTESSY Razorcat Development

GmbHWindows

DA-C RistanCASE WindowsTRACEANALYZER Symtavision GmbH WindowsECU-TEST TraceTronic GmbH WindowsUNDODB Undo Software LinuxTA INSPECTOR Vector WindowsVECTORCAST UNIT TESTING

Vector Software Windows

VECTORCAST CODE COVERAGE

Vector Software Windows

CPU Tool Company Host

Hexagon Debugger 87 ©1989-2019 Lauterbach GmbH

Page 88: Hexagon Debugger - LauterbachHexagon Debugger 6 ©1989-2019 Lauterbach GmbH Warning WARNING: To prevent debugger and target from damage it is recommended to connect or disconnect the

Products

Product Information

Order Information

Hexagon Debugger 88 ©1989-2019 Lauterbach GmbH