| 1 | | [http://libusb.org/wiki/libwdi/faq (Previous)] [http://libusb.org/wiki/libwdi/install (Next)] [http://libusb.org/wiki/libwdi#Documentation (Back to Table of Content)] |
| 2 | | |
| 3 | | = Zadig - User Guide = |
| 4 | | |
| 5 | | == Basic usage == |
| 6 | | |
| 7 | | In its simplest mode of operation, Zadig is meant to install a libusb 1.0 compatible driver, for a device that does not yet have such a driver installed. |
| 8 | | |
| 9 | | Below is an overview for a typical driver installation: |
| 10 | | |
| 11 | | 1. On Windows Vista or Windows 7, the first screen you will see when launching Zadig is the ''User Account Control'' prompt displayed below. This is because the application needs to run with administrative privileges, and you should answer ''Yes''.[[BR]]On Windows XP or earlier, no security prompt will appear.[[BR]][[BR]] |
| 12 | | [[Image(zadig_01.png)]][[BR]][[BR]] |
| 13 | | 1. With the application running, you should see your USB device appear in the dropdown list (click on the dropdown to see all devices).[[BR]]You can also plug your USB device after Zadig is running, as the list is refreshed automatically. We recommend that you leave only the device you want to install a driver for, and unplug any other USB device.[[BR]][[BR]] |
| 14 | | [[Image(zadig_02.png)]][[BR]][[BR]] |
| 15 | | The ''Vendor ID'', ''Product ID'' and (optionally) ''Interface ID'' that are displayed under the device name are provided for information. If you leave your mouse over the ''Vendor ID'', you should get the full name of the Vendor displayed.[[BR]][[BR]][[BR]] |
| 16 | | '''HELP! MY DEVICE DOES NOT APPEAR IN THE LIST!! '''[[BR]][[BR]] |
| 17 | | If you cannot see your device listed, then it probably means that it already has a driver installed, in which case you need to be very cautious about replacing it, as other applications may no longer be able to access it. For instance, if you replace the existing driver for an USB keyboard or mouse, it will no longer work for input in Windows. It will only work with a libusb based application.[[BR]][[BR]] |
| 18 | | To see USB devices that already have a driver installed, go to the ''Options'' menu and select ''List All Devices''.[[BR]] |
| 19 | | Below is an example of what you would see for an USB keyboard, with the ''!HidUsb'' driver already installed:[[BR]][[BR]] |
| 20 | | [[Image(zadig_03.png)]][[BR]][[BR]][[BR]] |
| 21 | | 1. (Optional) With your device selected, you can edit its name if the default doesn't suit your needs by clicking the ''Edit Desc.'' checkbox.[[BR]] |
| 22 | | You can enter a description in the language of your choice. The description you enter here is how the device will appear in Device Manager and at other locations. [[BR]][[BR]] |
| 23 | | 1. Once you are satisfied with the selection and device description, simply click the ''Install Driver'' Button.[[BR]][[BR]] |
| 24 | | 1. On Windows Vista or Windows 7, you might get the following security alert:[[BR]][[BR]] |
| 25 | | [[Image(zadig_05.png)]][[BR]][[BR]] |
| 26 | | This is because the driver files are generated automatically during installation. You will need to select ''Install this driver software anyway''[[BR]][[BR]] |
| 27 | | 1. Once the installation is started, just wait until it completes. Note that the installation process can take up to 5 minutes and can not be cancelled.[[BR]][[BR]] |
| 28 | | [[Image(zadig_04.png)]][[BR]][[BR]] |
| 29 | | You will be notified once the installation is complete.[[BR]][[BR]] |
| 30 | | 1. If the installation was successful, you should end up with something similar to this:[[BR]][[BR]] |
| 31 | | [[Image(zadig_07.png)]][[BR]][[BR]] |
| 32 | | Notice how the driver is now being displayed (in green) and indicates ''WinUSB''. WinUSB is one of the drivers supported by libusb 1.0.[[BR]]If the driver has been installed successfully, you should now be able to use your device with a libusb 1.0 application. |
| 33 | | |
| 34 | | == Advanced Use == |
| 35 | | |
| 36 | | For power users, Zadig offers the following list of features: |
| 37 | | * '''Advanced Mode''' (''Options -> Advanced Mode''):[[BR]]In this mode, users have the ability to select the target driver to be installed (WinUSB, libusb0.sys or a user driver if embedded), as well as the directory where the files should be extracted.[[BR]][[BR]] |
| 38 | | * '''Setting of the options through an INI file''':[[BR]]All the options that can be set in the menus can also be set from a zadig.ini file, which Zadig attempts to read when started. An example of such an ini file is provided below.[[BR]][[BR]] |
| 39 | | * '''!Info/Log''':[[BR]]In advanced mode, an informational window displaying the status of the application is also displayed, with the ability to clear/save that data. You can also select the log level appearing in this window by going to ''Options -> Log Level''. If you want to find out more about what the installation process is doing, or report an issue, make sure you run your driver installation with a sufficient log level.[[BR]][[BR]] |
| 40 | | * '''Extract files only, rather than install''' (''Options -> Extract Files Only''):[[BR]]When this mode is enabled, Zadig will not launch the installation process after extracting the driver files and creating the inf. This is useful if you want to check the files, or install them manually.[[BR]][[BR]] |
| 41 | | * '''Fine control over devices listed''' (''Options -> List All Devices'' / ''Options -> Ignore Hubs or Composite Parents''):[[BR]]By default, Zadig only lists devices that don't have a driver installed. In some situations however, you might want to replace an existing driver, including the ones for USB hubs (usbhub.sys) or Composite Parent (usbccgp.sys). These options allow you to do just that.[[BR]][[BR]] |
| 42 | | * '''Create New''' (''Device -> Create New''):[[BR]]In the case where you want to install a driver for a device that is not yet plugged, and for which you have the relevant information (VID, PID, etc.), you can select the ''Create New'' option and run the installation process so that the next time the device is plugged, the driver will be available.[[BR]][[BR]] |
| 43 | | * '''Open Preselected''' (''Device -> Open Preselected''):[[BR]]Similar to the ''Create New'' option above, but using a zadig preset device config file. For an example of such a file, see below.[[BR]][[BR]] |
| 44 | | |
| 45 | | == Example of a zadig.ini file == |
| 46 | | |
| 47 | | {{{#!c |
| 48 | | /* |
| 49 | | * Sample ini file for Zadig |
| 50 | | */ |
| 51 | | |
| 52 | | // Start application in advanced mode (default = false) |
| 53 | | advanced_mode = true; |
| 54 | | |
| 55 | | // Log level (0=debug, 1=info, 2=warning, 3=error) |
| 56 | | log_level = 0; |
| 57 | | |
| 58 | | // Extract driver files only, don't install (default = false) |
| 59 | | extract_only = false; |
| 60 | | |
| 61 | | // List all devices, including the ones that aready have a driver (default = false) |
| 62 | | list_all = true; |
| 63 | | |
| 64 | | // Include hubs and composite parent devices when listing all (default = false) |
| 65 | | include_hubs = true; |
| 66 | | |
| 67 | | // Trim trailing whitespaces from the USB device description (default = false) |
| 68 | | trim_whitespaces = true; |
| 69 | | |
| 70 | | // Select the following as the default driver to install: |
| 71 | | // WinUSB = 0, libusb0.sys = 1, Custom = 2 (default = WinUSB) |
| 72 | | default_driver = 0; |
| 73 | | |
| 74 | | // Set the default destination directory for extraction of the driver files (default = "C:\usb_driver") |
| 75 | | default_dir = "C:\usb_driver"; |
| 76 | | }}} |
| 77 | | |
| 78 | | == Example of a zadig preset device config file == |
| 79 | | {{{#!c |
| 80 | | // This is a sample preset device configuration for Zadig |
| 81 | | |
| 82 | | device = { |
| 83 | | Description = "Sample Device"; |
| 84 | | VID = 0xABCD; |
| 85 | | PID = 0x1234; |
| 86 | | MI = 0x00; |
| 87 | | }; |
| 88 | | }}} |