Starting from the Command Line

You can start the debugger from the real-mode command line by using the WDEB386 command line. (You cannot start the debugger from the command line after WIN.COM has started. To get the real-mode command line, press the F8 key as Windows starts and choose the Command Prompt Only option.) The command line has this syntax:


wdeb386 [/A] [/B] [/C:comport] [/D:"commands"] [/E] [/F:filename] [/H] [/I] [/L] [/N] [/T:hhhh] [/S:symfile] [/V[P]] [/X] winfile [parameters]

Following are the command-line options and parameters:

/A

Specifies that symbol files should not be automatically loaded.

/B

Specifies that the debugger should stop just prior to VMM initialization, after all virtual devices have been loaded and the processor is running in protected mode.

/C:comport

Specifies a COM port for debugger output. You can specify "1", "2", "3", or "4" for comport. If this option is not specified, The debugger checks first for COM2. If COM2 is not found, the debugger then checks for COM1. If neither COM1 nor COM2 exists, the debugger checks for any other COM port in the read-only memory (ROM) data area (40:0).

/D:"commands"

Carries out the debugger command line specified by the string enclosed in quotation marks. Spaces, semicolons (;), and other punctuation can be included in the command string. To use a single quote (') on the command line, use double quotation marks (") before and after the single quotation mark.

The commands specified in this option are carried out after symbols are loaded. This means you can set breakpoints in code even before the code has been loaded. Before a segment or module has been loaded or defined, breakpoints can be set on the logical address (a combination of map number and group number) until the segment or module is defined, at which point the breakpoint turns into a real breakpoint.

/E

Specifies that the debugger should stop at real-mode entry.

/F: filename

Specifies a file containing command-line options for the debugger. Maximum file size is 4K, and the input file cannot contain the /F option.

/H

Specifies that the debugger should be loaded as a VxD.

/I

Specifies that the debugger should be invisible to int 41.

/L

Specifies that line numbers should not be included in the .SYM file. This can make a large difference in memory use, and may be required on a machine with 4 megabytes of RAM.

/N

Sets the following options:


dislwr

codebytes

symaddrs

int3line

newvec

newreg

newprompt


For information about these options, see the y command in Reference.

/R:dddd

Sets the baud rate for the debugging terminal.

/S: symfile

Specifies a symbol file to be loaded. This option can be repeated to load more than one symbol file. If the symbol files are not in your current directory, you must supply a full path, because the debugger does not use the PATH environment variable to locate any of the files supplied on the command line.

When memory is low, you can use more symbol files by running the Debugger in the Windows directory and specifying the full path of VMM32.VXD (such as \WINDOWS\SYSTEM\VMM32.VXD) instead of WIN.COM.

/T:hhhh

Sets the port number for the timing card. (The default number is 250h.)

/V

Enables verbose mode, which displays messages indicating which segments are being being loaded.

/VP

Enables verbose mode, which displays messages indicating which segments are being loaded. This option displays the messages for applications only.

/X

Causes symbols to be loaded into Extended Memory Specification (XMS) memory.

winfile

Specifies the Windows application to run under debugger control. You will usually specify WIN.COM.

parameters

Specifies any parameters to be passed to the application.


The length of the command line cannot exceed 128 characters.

The following example shows a valid command line:


wdeb386 /C:1 /R:9600 /F:RUNWDEB.WRF /V \windows\win.com