3.3.5 Others Commands

To display information about the others commands available in MDB, type help others. The following table provides additional information for these commands.

Table 3-6. Others Commands
CommandDescription
EchoEcho is a command typically used in command files and batch files to output status text to the screen or a file. The echo command will print text surrounded by /* */. Use \n in the text to print a new line.

Command format:

echo text

Example:

echo Hello World

Result:

/*Hello World*/

This command prints text only. To print variables or other information, use commands such as print, info, list, etc.
Helphelp others – Prints a list of commands.
Quitquit - Exits the debugger.
Set The tool property name and value are from the project properties that are selected when creating the project in MPLAB X IDE. IMPORTANT: The Set command, including the tool property options, must be executed before the Hwtool command is issued, otherwise the changes to the tool properties will be ignored.

Command format:

Set tool-property-name value

Example:

Set programoptions.eraseb4program true

Refer to Table 3-7 for other tool properties options that can used with the Set command. Refer to Table 3-8 for simulator options that can be used with the Set command.
SleepMakes the current script processor sleep until specified milliseconds have elapsed.

Command format:

Sleep milliseconds

Example:

Sleep 10
StopwatchDisplay the stopwatch value or setup the stopwatch.

Command format:

Stopwatch [stopwatch-property]

Stopwatch command is used to display the stopwatch value.

Stopwatch stopwatch-property command is used to set the stopwatch property.

stopwatch-property:

  • ror Reset stopwatch on run (Default).
  • nror No reset stopwatch on run.
  • clear Manually reset the stopwatch to zero (Only available on Simulator).
WaitThe Wait command makes the current script processor wait until the debugger halts before processing the next command.

Command format:

Wait

Wait Milliseconds makes the processor process the next command if the debugger does not halt and milliseconds have elapsed.

Command format:

Wait [milliseconds]
cdThis command changes the directory that you are currently working in to the directory you designate.

Command format:

cd [directory]
infoPrints a table of all breakpoints that have been set and not deleted.

Optional argument n means “print information only” about the specified breakpoint.

For each breakpoint the following columns are printed:

  • Breakpoint Numbers
  • Enabled or Disabled: Enabled breakpoints are marked with ‘y’ . Disabled breakpoints are marked with ‘n’
  • Address - Where the breakpoint is in your program, as a memory address.
  • What - Where the breakpoint is in the source for your program: as a file and line number.

Command format:

info breakpoints [n]

info break [n]

list\The list command prints (displays) the source code for the current PC location, or a different file, if specified.

The list command displays lines from a source file.

By default, 10 lines are displayed.

list - displays 10 lines (5 above, 5 below) around the current line

list linenum - displays 10 lines around a given line

list first, - displays 10 lines from first line specified

list ,last

displays 10 lines up to last line specified

list first,last - displays all lines from the first to the last line specified

list - - displays 10 previous lines from the last output

list + - displays 10 more lines from the last output

list function - displays 10 lines around the given function

list file:linenum - displays 10 lines around the given line in a given file

list file:function - displays 10 lines around the given function in a given file

set system.listsize count - changes the number of lines shown

Using 0 or -1 means unlimited list size.

pwdThe pwd command displays the current working directory.

Command format:

pwd
PackDisplay the information (version and path) of the pack currently selected, as well as available packs.

Command format:

pack

Example: (Use PIC12F675 as example)

pack

Result:

PIC10-12Fxxx_DFP, version: 1.6.66

path: C:\earlydfpsoften\packs\Microchip\PIC10-12Fxxx_DFP

Available packs:

1.6.66 (currently selected)

1.5.61

Switch pack to specify the pack that the user wants to use.

Command format:

pack [version]

Example: ( Use PIC12F675 as example)

pack 1.5.61

Result:

Change the in used pack to 1.5.61

GroupCreate a register group for Display command.

Command format:

Group groupName <registers>

Example:

Group xregs <W0,W1,W2,W3,W4>

DisplayExamine a group of registers defined by user (refer to the Group command).

Command format:

Display /g groupName

Example:

Display /g xregs