Chapter 5. Developing a Driver

This chapter takes you through the WinDriver driver development cycle.

5.1. Using DriverWizard to Build a Device Driver

  • Use DriverWizard to diagnose your device and verify that it operates as expected: Read/write the I/O and memory ranges, view the PCI configuration registers, define and access custom registers, and listen to interrupts.
  • Use DriverWizard to generate skeletal code for your device in C or C#. For more information about DriverWizard, refer to Chapter 4.
    If you are using an enhanced-support PCI device (PLX 6466, 9030, 9050, 9052, 9054, 9056, 9080 and 9656; Altera Qsys design; Xilinx BMD design), you may want to use the related WinDriver sample as the basis for your development instead of generating code with DriverWizard. Note that for devices based on the Altera Qsys design or Xilinx BMD design, you can use DriverWizard to generate customized device-specific code, which utilizes the enhanced-support sample APIs. For additional information, refer to Chapter 7: Enhanced Support for Specific Chipsets.
  • Use any C or .NET compiler or development environment (depending on the code you created) to build the skeletal driver you need.
    WinDriver provides specific support for the following environments and compilers: MS Visual Studio, C++, GCC, Windows GCC

That is all you need to do in order to create your user-mode driver.
If you discover that better performance is needed, refer to Chapter 10.
For a detailed description of WinDriver's PCI/ISA API, refer to Appendix B.
To learn how to perform operations that DriverWizard cannot automate, refer to Chapter 9.