Trial Version Specifically Recognized Devices Price Buy now Policies Subscribe

PCIScope DOS agent (PCITool)

Overview
PCIScope DOS agent (further PCITool) is a command line utility for collecting PCI information under clear DOS, DOS included into Windows 95/98 or MSDOS prompt of Windows 95/98/ME.
Main features

Main features of PCITool are:

  • Displaying summary, brief and complete information about installed PCI devices. Almost all PCI Vendor Id/Device Id are decoded as human-readable names.
  • Reading a PCI configuration space, PCI Option ROMs and I/O memory mapped registers for known classes of PCI devices such as USB 1.1/2.0, 1394 (FireWire) and CardBus controllers. See /DA and /DB options.
  • Producing a binary file in a format compatible with PCIScope (.BPD file), which includes full information about PCI and ISA PnP subsystems.
  • Device detection process can be customized using special configuration INI file. PCITool is also able to check and automatically configure bridges to access memory and I/O registers of PCI devices behind them. See /CB option.
  • Command mode to read/write and PCI configuration space registers.
  • Ability to access all 4Gb address space with or without installed memory managers.
How to make a PCITool floppy
It's convenient to use PCITool from a bootable floppy:
  • You can make a snapshot of PCI and ISA PnP subsystems quickly and then open and explore it with PCIScope on another machine;
  • You can get system information or even modify registers of PCI devices on a computer where Windows is not installed or doesn't start properly.

In order to make a PCITool floppy:

  1. Make a DOS bootable floppy (DOS 6.22 or DOS 7.0 included into Windows 98 are recommended). PCITool was designed to work with and without memory managers.
  2. Copy the following files from a PCIScope installation directory:
    1. PCITOOL.EXE - PCITool utility
    2. PCITOOL.INI - PCITool configuration file
    3. PCITCMD.INI - PCITool command file; used with /CM parameter in Command Mode to read/write PCI registers.
    4. PCIDEV.INI, PCIVEND.INI - Copy these files if you want to see human-readable PCI Vendor Id/Device Id.
      Warning: Processing the database of PCI vendors/devices from a floppy disk may work very slow.
  3. You can run PCITool automatically from AUTOEXEC.BAT from a bootable floppy or manually from a command line.
    Parameters, which will be typically used:
    1. /DB:filename - save full PCI/ISA PnP information into a PCIScope's binary file
    2. /CM - switch on processing of PCITCMD.INI command file
Summary mode
In this mode basic information for each installed PCI device is displayed:
  • Ordinal number (PCITOOL specific index),
  • Bus, device, function,
  • Vendor ID, Device ID,
  • BARs' value, size and address space,
  • Filter setting for bridges.

PCITOOL uses PCIDEVS.INI and PCIVEND.INI to convert Vendor and Device IDs to human readable name. To get summary information you should launch PCITOOL without any parameters or using /A, /E, /XD, /CF to customize PCI device detection and output style. The following is a sample of program's screen:

Brief mode
In this mode only brief information for each installed PCI device is displayed:
  • Ordinal number (PCITOOL specific index),
  • Vendor ID, Device ID.

To get brief information you should launch PCITOOL with /B option.

Complete dump
In this mode PCITOOL displays complete decoded dump of configuration space of PCI device specified in command line option. See description of /DC option for details.
Text dump
In this mode PCITOOL produced text dump of configuration space and PCI option ROM for all installed PCI devices and also memory and I/O mapped registers for known types of PCI devices, such as USB 1.1/2.0, 1394 and CardBus controllers. The dump can be printed to a console or saved to a file. Format of the file is compatible with PCIScope application. You can simply import that file by PCIScope.

To get text dump use /DA option.

Binary dump
In this mode PCITOOL produced binary (.BPD) file with dump of configuration space and PCI option ROM for all installed PCI devices and also memory and I/O mapped registers for known types of PCI devices, such as USB 1.1/2.0, 1394 and CardBus controllers. The binary dump also contains extended information: size of BARs, PnP BIOS information, PnP System device list, ISA PnP information. The binary file is compatible with PCIScope and could be simply imported.

To get text dump use /DB option.

Configuration INI file
To customize detection process a special configuration file is used. By default PCITOOL automatically searches for PCITOOL.INI file in the current directory. Use '/CF' option to override default name of configuration INI file. The file is used to change configuration of PCI device (e.g. to adjust BAR values, bridge filter settings, bus numbers and so on).
Format of a configuration file
Section named with PCI device location string contains settings to temporary change PCI device configuration, e.g. BAR values, bus numbers, filter settings etc. All parameters will be restored to original state at PCITOOL exit.

Format of the settings is the following:

[BUS:DEV:FUN] - section name contains device location string

- Values for non-bridge device

IRQ            = <IRQ line register value>   ; By default has decimal
                                             ; format
BAR{n}         = <Value of n-th BAR>         ; BAR0 ... BAR6.
                                             ; Use BAR6 to access
                                             ; Option ROM register.

- Values for bridge device

PrimaryBus     = <Primary bus number>
SecondaryBus   = <Secondary bus number>
SubordinateBus = <Subordinate bus number>
VGAEnable      = <Value of VGA enable bit>   ; VGA enable bit in Bridge
                                             ; Control register
ISAEnable      = <Value of ISA enable bit>   ; ISA enable bit in Bridge
                                             ; Control register

- Values for PCI-2-PCI bridge

MemFilter      = <Base>:<Limit> |            ; Not prefetchable memory
                 <Base>,<Size>               ; filter
PreFilter      = <Base>:<Limit> |            ; Prefetchable memory
                 <Base>,<Size>               ; filter
IoFilter       = <Base>:<Limit> |            ; I/O filter
                 <Base>,<Size> ;

- Values for CardBus bridge

ExCABase       = <ExCA base address>         ; CardBus/ExCA registers
                                             ; base address
MemFilter{n}   = <Base>:<Limit>[,Prefetch] | ; MemFilter0, MemFilter1
                 <Base>,<Size>[,Prefetch]    ; Memory filter
IoFilter{n}    = <Base>:<Limit>            | ; IoFilter0, IoFilter1
                 <Base>,<Size>               ; I/O filter

All numbers should have hexadecimal format, except:
- IRQ line register value should have decimal format by default.
- <Size> value should have decimal format by default or have the following form: 1K, 2K, ... {n}K; 1M, 2M, ... {n}M (size in kilobytes or megabytes).

It needs to specify prefix '0x' or postfix 'h' to force the number to be recognized as hexadecimal. If the value string contains hexadecimal digits than the number is automatically recognized as hexadecimal.

Command mode
In this mode PCITOOL is only able to execute commands to read/write configuration space of any PCI devices. /CM, /W and /R options switch the program to command mode and force it to ignore all another options. PCITOOL supports both commands in a command line and in a batch command file.
Format of a command file
Don't add leading slash before the commands.
;
;Some comments
;

W{b|w|d}:BUS:DEV:FUN:OFF=VAL ; Write data
...
R{b|w|d}:BUS:DEV:FUN:OFF     ; Read data
...
Command line parameters
Syntax:

PCITOOL [/H|?] [/A] [/B] [/E] [/SF] [/DC:n] [/DA[:filename]] [/DB:filename] [/XD:BUS:DEV:FUN] [/XR] [/XP] [/HR] [/RS] [/CF:filename] [/CB] [/W{b|w|d}:BUS:DEV:FUN:OFF=VAL] [/R{b|w|d}:BUS:DEV:FUN:OFF] [/CM[:filename]]

where:

Command line parameter: Description:
/H Print help text.
/A Wait for key press after every device output.
/B Brief mode: just list Device ID and Vendor ID.
/E Silent mode: no output is performed.
/SF Skip filtering of phantom devices.
/DC:n Dump complete configuration space of device with PCITOOL specific index 'n'. Run PCITOOL in brief mode in order to find the index.
/DA[:filename] Dump PCI configuration space, PCI option ROM, memory and I/O mapped registers for all devices into specified file or console. By default the file will have .TXT extension.
The text file, which is produced with this option, is compatible with PCIScope. You can import that file by PCIScope.
/DB:filename Produce binary file with PCI and PnP system information to import by PCIScope. By default the file will have .BPD extension. You can import that file by PCIScope.
/XD:BUS:DEV:FUN Exclude specified device from dumping.
/XR Exclude Option ROM from dumping.
/XP Exclude PnP System device list and ISA PnP device list from dumping.
/HR Read Option ROM of primary video adapter from hardware. Otherwise read copy of Option ROM from C0000 memory address.
/RS Restore screen after reading Option ROM of primary video adapter.
/CF:filename Use specified file name to override default name of configuration INI file. By default PCITOOL uses PCITOOL.INI file. Type /CF:? for the configuration INI file format details.
/CB Automatically check and configure parent bridges to read memory or I/O mapped registers on a PCI device behind those bridges.
Attention!!! On some machines usage of this option may caused hang. In such case program bridges explicitly via configuration INI file.
/W{b|w|d}:BUS:DEV:FUN:OFF=VAL Write value (VAL) as byte (b), word (w) or dword (d) to Configuration Space of device (BUS:DEV:FUN) by offset (OFF). All numbers should have hexadecimal format. Don't use spaces inside this command.
/R{b|w|d}:BUS:DEV:FUN:OFF Read value (VAL) as byte (b), word (w) or dword (d) from Configuration Space of device (BUS:DEV:FUN) by offset (OFF). All numbers should have hexadecimal format. Don't use spaces inside this command.
/CM[:filename] Parse specified command file. If no file name is specified, PCITOOL will use PCITCMD.INI file. Format of a command file.

PCITool components
The following PCITool files can be found in PCIScope installation directory:

File:Description:
PCITOOL.EXE PCITool utility.
PCITOOL.INI PCITool configuration file.
PCITCMD.INI PCITool command file; used with /CM parameter in Command Mode to read/write PCI registers.
PCIDEV.INI, PCIVEND.INI Database of known PCI vendors/devices. These files are used to decode PCI Vendor Id/Device Id as human-readable names.
Warning: We don't recommend to use these files on a floppy. Processing the database of PCI vendors/devices from a floppy disk may work very slow.