Technical Document #84

Technical Document #84        [Product Version: 6.2.X–7.X]
WinDriver Upgrade: Version 6.0.x -> Version 6.2.x–7.x

This document outlines the steps for upgrading from version 6.0.x to version 6.2.x–7.x of WinDriver.

The following documents describe the upgrade steps for other versions of WinDriver:

  • TD #131 — Version 7.x -> Version 8.x
  • TD #127 — Version 6.2.x -> Version 7.x and above
  • TD #116 — Version 5.2.2 or earlier -> Version 6.0.2–7.x


Upgrade Steps:

  1. Acquire a New WinDriver License (Registered Users)
  2. Upgrade Your Driver Project
  3. Upgrade Your Device INF File (Windows)
  4. Upgrade Your Driver Distribution


  1. Acquire a New WinDriver License (Registered Users)
  2. If you are using a registered version of WinDriver, contact Jungo's sales department to acquire a WinDriver license registration string for the new version. Then register the new license from DriverWizard (File | Register WinDriver) and from your code (if you select to rebuild your code).

    Note that if you have a valid Support & Upgrade Subscription you are entitled to receive a new license free of charge.




  3. Upgrade Your Driver Project
  4. WinDriver is backwards compatible, therefore code developed with version 6.0.x should work, without modification, with the driver module (windrvr6.sys/o/ko/dll) from version 6.2.x/7.x, provided the code is not rebuilt with the files and license from the newer version. However, in order to fully utilize the new driver module and enjoy all bug fixes and enhancements provided by the new version, it is recommended to also upgrade your driver project to use the new driver files.

    To upgrade your driver code, follow these steps:

    • When upgrading from version 7.0.0- to version 7.0.1+:
      Beginning with version 7.0.1 of WinDriver, the include path in the WinDriver project/make files contains the path to the WinDriver/ and WinDriver/include/ directories.
      The #include statements in the WinDriver source files and generated DriverWizard code were modified accordingly to indicate only the name of the header file to include, instead of the full/relative path to the file (as done in version 7.0.0-).

      In light of these changes, when rebuilding a driver project from v7.0.0 or below with the source files from v7.0.1 or above, you may need to modify your project/make file and add the path to the WinDriver/ and WinDriver/include/ directories to the project's include path in order to successfully build the project.


    • wd_utils: Beginning with version 6.2.0 of WinDriver, Windows MS Visual Studio (Visual C++) projects can utilize the wd_utils DLL by linking the project with WinDriver\lib\
      wd_utils.lib
      . Beginning with version 7.0.0 this option is also supported for Borland C++ Builder projects, which need to be linked with WinDriver\lib\wd_utils_borland.lib.

      Linux projects from version 7.0.0+ can utilize wd_utils by linking with WinDriver/lib/libwd_utils.so. To link your Linux project with this shared object, add wd_utils to the makefile's link flags (LFLAGS += -l wd_utils), instead of listing all the source files from the WinDriver/src directory in the makefile (under the SRCS flag).

      Beginning with version 7.0.1 of WinDriver, Windows CE projects can also utilize wd_utils by linking with WinDriver\lib\wd_utils.lib, and Solaris projects can link with WinDriver/lib/libwd_utils.so.

      The sample and generated DriverWizard projects from v6.2.0+ (Windows — Visual Studio) / v7.0.0 (Windows — Borland C++ Builder; Linux) / v7.0.1+ (Solaris; Windows CE) demonstrate how to link your project with the wd_utils DLL/shared object.

      Note that if you select to use the wd_utils DLL/shared object from your project, you will need to distribute wd_utils.dll / libwd_utils.so with your driver, as explained in the driver distribution instructions of the WinDriver User's Manual.


    • For USB, beginning with version 7.0.0 of WinDriver, if you have created a console driver application/DLL/shared object that calls functions implemented in WinDriver/samples/shared/usb_diag_lib.c (as is the case for the sample and generated WinDriver USB diagnostic driver projects): in order to build your project with the usb_diag_lib.c file from the new version, you must add the new WinDriver/samples/shared/diag_lib.c file to your project.

    • For PCI/ISA drivers, beginning with version 7.0.0 WinDriver features the new WDC library, which provides convenient wrapper APIs to the standard WinDriver PCI/ISA APIs. (This library is part of the wd_utils DLL/shared object; the source files are found under the WinDriver/src directory).

      The new WDC APIs are documented in the WinDriver v7.x PCI User's Manual. The generated DriverWizard v7.x projects utilize the WDC APIs instead of the lower-level standard WinDriver APIs. The new APIs are also used from the v7.x pci_diag, pcmcia_diag, pci_dump and PLX samples.

      Since WDC mainly provides wrappers to the standard WinDriver APIs, which are still supported, you do not need to modify your old code to use the new WDC library. Should you select to upgrade your code to use the new APIs, you can examine the new samples and generated code and compare them to those from your old WinDriver version for a better understanding of how to use the WDC APIs.

      Note that to use the WDC APIs you will need to either include the relevant WinDriver/src/wdc_xxx.c source files in your project/makefile; or link your project with the WinDriver\lib\
      wd_utils.lib
      library — for MS Visual Studio (Visual C++) projects, or with the WinDriver\lib\wd_utils_borland.lib library — for Borland C++ Builder projects (as done in the generated and sample WinDriver Visual Studio and Borland C++ Builder projects).


    • For PCI/ISA projects that include interrupt handling APIs, if you do not wish to upgrade your code to use the new WDC API, add the DLLCALLCONV modifier in the locations listed below. The following is based on the sample/generated C WinDriver code, where xxx is the name of your driver project. Similar changes should be made in Visual Basic and Delphi projects or in your propriety C/C++ interrupt functions. Add DLLCALLCONV in the following locations:
      • xxx_lib.h:
        typedef void (DLLCALLCONV
            *XXX_INT_HANDLER)
            (XXX_HANDLE hXXX,
            XXX_INT_RESULT *intResult);
      • xxx_lib.c:
        void DLLCALLCONV
            XXX_IntHandler(PVOID pData)
      • xxx_diag.c:
        void DLLCALLCONV XXX_IntHandlerRoutine
            (XXX_HANDLE hXXX,
            XXX_INT_RESULT *intResult)

    • For Visual Basic (VB) projects, beginning with version 6.2.2 of WinDriver the names of the windrvr.cls and wd_utils.cls files from the WinDriver\vb\include\ directory, have changed to windrvr.bas and wd_utils.bas, respectively, therefore VB projects developed with version 6.2.1 or below need to be adjusted to use the new files.

    • Registered users: Modify the driver code to register your new license registration string.
      For PCI/ISA drivers the license should be registered using the WD_License() API or using the new WDC WDC_DriverOpen() API. For USB drivers the license should be registered using the WDU_Init() API. For details regarding these APIs, refer to the WinDriver User's Manual from the new version.

    • Rebuild your driver project with the source files from the new version.



  5. Upgrade Your Device INF File (Windows)
  6. On Windows 98/Me/2000/XP/Server 2003: If you have created a driver for a Plug-and-Play device (USB/PCI), it is recommended to create and install a new INF file for your device, which registers it with windrvr6.sys from the new version. You can use DriverWizard from the new version to generate the new INF file, or modify the driver version in your existing INF file.




  7. Upgrade Your Driver Distribution / Installation
  8. Create a new driver distribution package, which contains the driver module (windrvr6.sys/o/ko/dll) and related files from the new version along with an installation program that installs the new driver.

    For Windows 98/Me/2000/XP/Server 2003, for example, distribute the new windrvr6.sys and windrvr6.inf files, the wdreg.exe/wdreg_gui.exe/wdreg16.exe utility, your device INF file (if created), the wd_utils.dll (if it used from your driver project) and your Kernel PlugIn driver (if you have created such a driver).

    Specific driver distribution instructions can be found in the Distributing Your Driver chapter of the new manual. The instructions for Windows are also summarized in Technical Document #117.