Intel® System Debugger User Guide
Perform Basic Debugging Tasks
If you are not prompted to the Debug perspective automatically, click the
Open Perspective button on the top right corner of the Eclipse* toolbar:
Select Debug and click Open.
Load Application
To load an application, you must be in the ROM space address. The target needs to be reset for that. There are some preconditions for that: https://psefdk.app.intel.com/_zephyr_code_base.html#autotoc_md5.
Execute the
monitor load si
If the debugger breaks into 0x700… address, you can load the program as follows:
load <path-to-binary>/zephyr.elf
If the address is still 0x600…, execute the instructions again.
Note: This issue is also present in OpenOCD. For more information, read:
Run Control
To run control from GUI, use Suspend and
Resume buttons in the toolbar.
Alternatively, you can run or resume the application by executing the Suspend button.
Check Registers
After starting a new debug session, do a step and display registers to ensure that you are on a start function.
In Debugger console, execute the following commands:
si info registers
Registers are now displayed in the Registers view. To open it, go to Window > Show view > Registers.
Program counter register must be pointing to the start address close to
Step Through Code
To step through the disassembled code (displayed in the Disassembly view), click the
Instruction Stepping Mode button in the Debug view. Now you can use stepping functions:
Step Into - executes the current line, including any routines, and proceeds to the next statement.
Step Over - executes the current line, following execution inside a routine.
Step Return - continues execution to the end of the current routine, then follows execution to the caller of the routine.
Alternatively, execute the
Set Breakpoints
- From GUI
In the Disassembly view, right-click the required address in the source code. Select Add breakpoint.
Set the type Regular or Hardware.
Set additional parameters:
Enabled box (checked by default) - uncheck if you want to keep the breakpoint disabled now.
Condition - a custom condition for hitting the breakpoint.
Ignore count - the number of times a breakpoint hit must be ignored.
Click Apply and Close.
- From the console
To set a software breakpoint, execute the command:
break <filename.extension:line>
To set a hardware breakpoint, execute the command:
hbreak <filename.extension:line>
New breakpoint is displayed in the
Breakpoints view.
Enable Interrupts
By default, interrupts in Intel® Programmable Services Engine (Intel® PSE) are disabled. You can enable and disable them and also see the status by using these commands in the debugger console:
monitor enable_interrupts monitor disable_interrupts monitor status_interrupts