1.10  What Does the WinDriver Toolkit Include?

1.10.1  WinDriver Modules

  • WinDriver (WinDriver/include) – the general purpose hardware access toolkit. The main files here are:
    • windrvr.h: Declarations and definitions of WinDriver's basic API.
    • wdc_lib.h and wdc_defs.h: Declarations and definitions of the WinDriver Card (WDC) library, which provides convenient wrapper APIs for accessing PCI/PCMCIA/CardBus/ISA/EISA/CompactPCI/PCI Express devices (see Chapter B.2).
    • windrvr_int_thread.h: Declarations of convenient wrapper functions to simplify interrupt handling.
    • windrvr_events.h: Declarations of APIs for handling and Plug-and-Play and power management events.
    • utils.h: Declarations of general utility functions.
    • status_strings.h: Declarations of API for converting WinDriver status codes to descriptive error strings.
    [Note]
    On Mac OS X, the WinDriver API is supplied in the form of a framework – WDAPI.framework. This framework is provided in the WinDriver/redist directory, and is copied, as part of the WinDriver installation, to the operating system's frameworks directory – /Library/Frameworks. Therefore, the include path on Mac OS X should be
    /Library/Frameworks/WDAPI.framework/Headers.
  • DriverWizard (WinDriver/wizard/wdwizard or /Applications/wdwizard.app on Mac OS X) – a graphical application that diagnoses your hardware and enables you to easily generate code for your driver (refer to Chapter 4 for details).
  • Debug Monitor – a debugging tool that collects information about your driver as it runs. This tool is available both as a fully graphical application – WinDriver/util/wddebug_gui, or /Applications/wddebug_gui.app on Mac OS X – and as a console-mode application – WinDriver/util/wddebug. The console-mode version also supports GUI execution on Windows CE platforms that don't have a command-line prompt.
    For details regarding the Debug Monitor, refer to section 6.2.
  • WinDriver distribution package (WinDriver/redist) – the files you include in the driver distribution to customers.
  • WinDriver Kernel PlugIn – the files and samples needed to create a kernel-mode Kernel PlugIn driver (refer to Chapter 11 for details.)
  • This manual – the full WinDriver manual (this document), in different formats, can be found under the WinDriver/docs directory.

1.10.2  Utilities

  • pci_dump.exe (WinDriver/util/pci_dump.exe) – used to obtain a dump of the PCI configuration registers of the installed PCI cards.
  • pci_diag.exe (WinDriver/util/pci_diag.exe) – used for reading/writing PCI configuration registers, accessing PCI I/O and memory ranges and handling PCI interrupts.
  • pci_scan.exe (WinDriver/util/pci_scan.exe) – used to obtain a list of the PCI cards installed and the resources allocated for each card.
  • pcmcia_diag.exe (WinDriver/util/pcmcia_diag.exe) – used for reading/writing PCMCIA attribute space, accessing PCMCIA I/O and memory ranges and handling PCMCIA interrupts.
  • pcmcia_scan.exe (WinDriver/util/pcmcia_scan.exe) – used to obtain a list of the PCMCIA cards installed and the resources allocated for each card.

1.10.3  WinDriver's Specific Chipset Support

WinDriver provides custom wrapper APIs and sample code for major PCI chipsets (see Chapter 7), including for the following chipsets:

  • PLX 6466, 9030, 9050, 9052, 9054, 9056, 9080 and 9656 – WinDriver/plx
  • AMCC S5933 – WinDriver/amcc
  • Altera pci_dev_kit – WinDriver/altera/pci_dev_kit
  • Xilinx VirtexII and Virtex 5 – WinDriver/xilinx

1.10.4  Samples

In addition to the samples provided for specific chipsets [1.10.3], WinDriver includes a variety of samples that demonstrate how to use WinDriver's API to communicate with your device and perform various driver tasks.

  • C samples: found under the WinDriver/samples directory.
    These samples also include the source code for the utilities listed above [1.10.2].
  • .NET C# samples (Windows): found under the WinDriver\csharp.net directory.
  • Delphi (Pascal) samples (Windows) WinDriver\delphi\samples directory.
  • Visual Basic samples (Windows): found under the WinDriver\vb\samples directory.