SRP Debugger SRP Debugger

Navigation

Home

User Guide
Hotkeys
Command Line

ASM Commands

About

Command Overview:

assemble

Assembles the current program. Asks for the program to be saved, if it has been modified since the last saving.


break < linenumber >

Toggles a breakpoint for the line <linenumber>. If the line contained already a breakpoint, this breakpoint will be removed; otherwise a breakpoint is added to that line.


clear

Clears the message output view and the processor output view.


close

Closes the current program, if one is open. May ask if the program should be saved before closing.


del watch < regnumber >

Deletes all watchpoints for register <regnumber>


dumpmem < memoryaddress >

Sets the memory view to display the content of the memory from address <memoryaddress> on. The value of <memoryaddress> is given in decimal notation.


help

Open the help viewer, displaying the help start page.


load < file >

Opens the program from the file given by <file>. The parameter may be an absolute path or a path relative to the directory that the Debugger was started from.

The command completion function can be used for the filename, completing absolute paths.


microstep

Executes one machine instruction. In cases of composite commands (eg. the call command), multiple of those microsteps may be taken to complete one command.

This is only possible when a running program was suspended.


open < file >

Refer to: load <file>


quit

Quits the Debugger application. This will pop a confirmation dialog and ask for unsaved programs to be saved.

This command cannot be executed when a program is still running.


reset

Reloads the current program from the file it was originally loaded from or last saved to. This does not work if the current program has not been loaded from a file or not been saved, yet.


resume

Resumes the current program.

This is only possible when a running program was suspended.


run

Runs the current program. Asks to assemble first, if the program has not been assembled during this session, or if it has been modified since the last time it was assembled.


save

Saves the program to the file it was last saved to or opened from. If the program has not been saved before and has not been loaded from a file, it opens a file dialog to select a file.


save < filename >

Saves the current program to the file given by <filename>. The parameter may be an absolute path or a path relative to the directory that the Debugger was started from.


setmemory [-x] < memaddress > < memvalue >

Sets the memory at the address <memaddress> to the value <memvalue>. If the flag -x is set, the value of <memvalue> is interpreted as hexadecimal notation. Otherwise, it is interpreted as decimal notation.


set [-x] < regnumber > < regvalue >

Sets the register with the number <regnumber> to the value <regvalue>. If the flag -x is set, the value of <regvalue> is interpreted as hexadecimal notation. Otherwise, it is interpreted as decimal notation.


show memory < on / off >

Toggles the memory view visible/invisible.


show registers < on / off >

Toggles the register view visible/invisible.


show stack < on / off >

Toggles the stack view (memory & function stack) visible/invisible.


stop

Causes the current program to stop execution immediately and sets the processor back to the initial state.

This is prossible during any phase of a running program.


step

Executes a single command, which corresponds to one line in the source code. If this command is complex (like the call command), this step comprises multiple instructions (microsteps).

This is only possible when a running program was suspended.


stepover

Steps over the current command. This implicitly places a breakpoint after the current command. For most cases, this will behave like the step command. However, functions are executed in one and the program stops after the function has returned (called stepping over a function, hence the name).

This is only possible when a running program was suspended.


stepreturn

This is only possible when a running program was suspended.

This steps out of the current function. The program runs until the current function has returned. Stepping out of the main function causes the program to run to the end, as this markes the end of the main function.


trace < delay >

This causes the program to update all views and pause for <delay> milliseconds after each instruction. This way, a program can be followed visually during execution. A value of 0 deactivates this mode of operation.

This corresponds to the menu action: debug - live run.

Caveat: This mode also works during the execution of the loader. When the loader is running, the function stack shows a single element for the loader. If after the program start, the program does not seem to be running, but the registers start taking on funny values, go and check if you forgot to deactivate this mode and the loader is taking its time.


watch < regnumber >

Causes the program to suspend whenever register number <regnumber> changes its value.


watch < regnumber > < relop > < value >

Causes the program to suspend when register number <regnumber> changes its value and the new value is in relation <relop> to the value <value>. <relop> may be one of: =, <, <=, >, >=.

The relational operator unqual is not implemented, but can be used by placing two watchpoints, one < value and one > value.

Example: 'watch 16 > 1000' causes the program to suspend whenever register 16 changes its value and the new value is greater than thousand.


< return>

Hitting return causes the latest command to be repeated. This applies only to commands entered during the current session, so that hitting return at the beginning of a session will not repreat the latest command in the command history.


< arrow up >

Browses the command history towards the next older command.


< arrow down >

Browses the command history towards the next newer command.


< ctrl + space >

Completes the current command or shows multiple suggestions, if the current prefix is ambiguous.