Manual removal of Elo driver fragments Tyco Electronics, 301 Constitution Drive, Menlo Park, CA 94025; Tel 650/361-4700 Note:File deletions, and particularly registry key deletions, must be done with care. Deleting non-Elo files can cause problems with computer operations; in the worst case. Elo Touch Solutions PulseTouch Touchscreen: USB VID04E7&PID0073: Search the drivers: Elo Touch Solutions PulseTouch Touchscreen: USB VID04E7&PID0074. The Elo 1517L standard format touchscreen monitor is built to withstand the rigors of continuous public use with a rugged built-for-touch design. Its stylish, thin and modern look, coupled with a retail-focused feature set and is an attractive solution for commercial touchscreen monitor needs.
-->In this topic you'll use the USB Kernel-Mode Driver template provided with Microsoft Visual Studio Professional 2019 to write a simple kernel-mode driver framework (KMDF)-based client driver. After building and installing the client driver, you'll view the client driver in Device Manager and view the driver output in a debugger.
For an explanation about the source code generated by the template, see Understanding the KMDF template code for a USB client driver.
Prerequisites
For developing, debugging, and installing a kernel-mode driver, you need two computers:
- A host computer running Windows 7 or a later version of the Windows operating system. The host computer is your development environment, where you write and debug your driver.
- A target computer running Windows Vista or a later version of Windows. The target computer has the kernel-mode driver that you want to debug.
Before you begin, make sure that you meet the following requirements:
Software requirements
- Your host computer hosts your development environment and has Visual Studio Professional 2019.
- Your host computer has the latest Windows Driver Kit (WDK) for Windows 8. The kit include headers, libraries, tools, documentation, and the debugging tools required to develop, build, and debug a KMDF driver. To get the latest version of the WDK, see Download the Windows Driver Kit (WDK).
- Your host computer has the latest version of debugging tools for Windows. You can get the latest version from the WDK or you can Download and Install Debugging Tools for Windows.
- Your target computer is running Windows Vista or a later version of Windows.
- Your host and target computers are configured for kernel debugging. For more information, see Setting Up a Network Connection in Visual Studio.
Hardware requirements
Get a USB device for which you will be writing the client driver. In most cases, you are provided with a USB device and its hardware specification. The specification describes device capabilities and the supported vendor commands. Use the specification to determine the functionality of the USB driver and the related design decisions.
If you are new to USB driver development, use the OSR USB FX2 learning kit to study USB samples included with the WDK. You can get the learning kit from OSR Online. It contains the USB FX2 device and all the required hardware specifications to implement a client driver.
You can also get a Microsoft USB Test Tool (MUTT) devices. MUTT hardware can be purchased from JJG Technologies. The device does not have installed firmware installed. To install firmware, download the MUTT software package from this Web site and run MUTTUtil.exe. For more information, see the documentation included with the package.
Recommended reading
- Developing Drivers with Windows Driver Foundation, written by Penny Orwick and Guy Smith. For more information, see Developing Drivers with WDF.
Instructions
Step 1: Generate the KMDF driver code by using the Visual Studio Professional 2019 USB driver template
For instructions about generating KMDF driver code, see the steps in Writing a KMDF driver based on a template.
For USB-specific code, select the following options in Visual Studio Professional 2019
- In the New Project dialog box, in the search box at the top, type USB.
- In the middle pane, select Kernel Mode Driver, USB (KMDF).
- Select Next.
- Enter a project name, choose a save location, and select Create.
The following screen shots show the New Project dialog box for the USB Kernel-Mode Driver template.
This topic assumes that the name of the Visual Studio project is 'MyUSBDriver_'. It contains the following files:
Files | Description |
---|---|
Public.h | Provides common declarations shared by the client driver and user applications that communicate with the USB device. |
<Project name>.inf | Contains information required to install the client driver on the target computer. |
Trace.h | Declares tracing functions and macros. |
Driver.h; Driver.c | Declares and defines driver entry points and event callback routines. |
Device.h; Device.c | Declares and defines event callback routine for the prepare-hardware event. |
Queue.h; Queue.c | Declares and defines an event callback routine for the event raised by the framework's queue object. |
Step 2: Modify the INF file to add information about your device
Before you build the driver, you must modify the template INF file with information about your device, specifically the hardware ID string.
In Solution Explorer, under Driver Files, double-click the INF file.
In the INF file you can provide information such as the manufacturer and provider name, the device setup class, and so on. One piece of information that you must provide is the hardware identifier of your device.
Elo Touch Usb Devices Driver Update
To provide the hardware ID string:
Attach your USB device to your host computer and let Windows enumerate the device.
Open Device Manager and open properties for your device.
On the Details tab, select Hardward Ids under Property.
The hardware ID for the device is displayed in the list box. Select and hold (or right-click) and copy the hardware ID string.
Replace USBVID_vvvv&PID_pppp in the following line with your hardware ID string.
[Standard.NT$ARCH$] %MyUSBDriver_.DeviceDesc%=MyUSBDriver__Device, USBVID_vvvv&PID_pppp
Step 3: Build the USB client driver code
To build your driver
- Open the driver project or solution in Visual Studio Professional 2019
- Select and hold (or right-click) the solution in the Solution Explorer and select Configuration Manager.
- From the Configuration Manager, select the Active Solution Configuration (for example, Windows 8 Debug or Windows 8 Release) and the Active Solution Platform (for example, Win32) that correspond to the type of build you're interested in.
- From the Build menu, select Build Solution.
For more information, see Building a Driver.
Step 4: Configure a computer for testing and debugging
To test and debug a driver, you run the debugger on the host computer and the driver on the target computer. So far, you have used Visual Studio on the host computer to build a driver. Next you need to configure a target computer. To configure a target computer, follow the instructions in Provision a computer for driver deployment and testing.
Step 5: Enable tracing for kernel debugging
The template code contains several trace messages (TraceEvents) that can help you track function calls. All functions in the source code contain trace messages that mark the entry and exit of a routine. For errors, the trace message contains the error code and a meaningful string. Because WPP tracing is enabled for your driver project, the PDB symbol file created during the build process contains trace message formatting instructions. If you configure the host and target computers for WPP tracing, your driver can send trace messages to a file or the debugger.
To configure your host computer for WPP tracing
Create trace message format (TMF) files by extracting trace message formatting instructions from the PDB symbol file.
You can use Tracepdb.exe to create TMF files. The tool is located in the <install folder>Windows Kits8.0bin<architecture> folder of the WDK. The following command creates TMF files for the driver project.
tracepdb -f [PDBFiles] -p [TMFDirectory]
The -f option specifies the location and the name of the PDB symbol file. The -p option specifies the location for the TMF files that are created by Tracepdb. For more information, see Tracepdb Commands.
At the specified location you'll see three files (one per .c file in the project). They are given GUID file names.
In the debugger, type the following commands:
.load Wmitrace
Loads the Wmitrace.dll extension.
.chain
Verify that the debugger extension is loaded.
!wmitrace.searchpath +<TMF file location>
Add the location of the TMF files to the debugger extension's search path.
The output resembles this:
Trace Format search path is: 'C:Program Files (x86)Microsoft Visual Studio 14.0Common7IDE;c:driverstmf'
To configure your target computer for WPP tracing
Elo Touch USB Devices Driver
Make sure you have the Tracelog tool on your target computer. The tool is located in the <install_folder>Windows Kits8.0Tools<arch> folder of the WDK. For more information, see Tracelog Command Syntax.
Open a Command Window and run as administrator.
Type the following command:
tracelog -start MyTrace -guid #c918ee71-68c7-4140-8f7d-c907abbcb05d -flag 0xFFFF -level 7-rt -kd
The command starts a trace session named MyTrace.
The guid argument specifies the GUID of the trace provider, which is the client driver. You can get the GUID from Trace.h in the Visual Studio Professional 2019 project. As another option, you can type the following command and specify the GUID in a .guid file. The file contains the GUID in hyphen format:
tracelog -start MyTrace -guid c:driversProvider.guid -flag 0xFFFF -level 7-rt -kd
You can stop the trace session by typing the following command:
tracelog -stop MyTrace
Step 6: Deploy the driver on the target computer
- In the Solution Explorer window, select and hold (or right-click) the <project name>Package , and choose Properties.
- In the left pane, navigate to Configuration Properties > Driver Install > Deployment.
- Check Enable deployment, and check Import into driver store.
- For Remote Computer Name, specify the name of the target computer.
- Select Install and Verify.
- Select Ok.
- On the Debug menu, choose Start Debugging, or press F5 on the keyboard.
Note Do not specify the hardware ID of your device under Hardware ID Driver Update. The hardware ID must be specified only in your driver's information (INF) file.
For more information about deploying the driver to the target system in Visual Studio Professional 2019, see Deploying a Driver to a Test Computer.
You can also manually install the driver on the target computer by using Device Manager. If you want to install the driver from a command prompt, these utilities are available:
This tool comes with the Windows. It is in WindowsSystem32. You can use this utility to add the driver to the driver store.
For more information, see PnPUtil Examples.
This tool comes with the WDK. You can use it to install and update drivers.
Step 7: View the driver in Device Manager
Enter the following command to open Device Manager:
devmgmt
Verify that Device Manager shows a node for the following node:
Samples
MyUSBDriver_Device
Step 8: View the output in the debugger
Elo Touch Driver Windows 10
Visual Studio first displays progress in the Output window. Then it opens the Debugger Immediate Window. Verify that trace messages appear in the debugger on the host computer. The output should look like this, where 'MyUSBDriver_' is the name of the driver module:
Related topics
Understanding the KMDF template code for a USB client driver
Getting started with USB client driver development
A client is not displaying the image from the host PC, but the image of the client's operating system. | Check the network connection. Make sure that the network configuration of the host PC and the client are correct. Check the CP-Link 3 configuration (see also the Client Configuration section). | |
The host PC cannot connect to a client even though the client is reachable using the Ping command. | Faulty firewall setting on the client. For CE based clients: Wrong directory used for installation. | Check the firewall settings of the client (see also the Firewall Configuration section). For CE based clients: Always install CP-Link 3 into the directory suggested by the installation wizard (see also the Installation - Client section). |
A network adapter in the client is being used both for the CP-Link 3 connection and for real-time Ethernet. It is not possible to transmit the “Virtual Graphics” data via UDP (see also the Comments section). | Change the client's “Virtual Graphics” data transfer protocol over to TCP (see also the Client Configuration section). | |
Exceptionally slow graphics performance of a client. | The color depth of the client's display does not match the corresponding host display color depth. | Adjust the color depth of the client's display to match the color depth of the corresponding host display (see also the Installation - Client section). |
The image displayed at a client is faulty; some parts of the screen are not updated, or are updated only after a delay. | The network has a poor connection quality, while the “Virtual Graphics” data is being transmitted via UDP. | Change the client's “Virtual Graphics” data transfer protocol over to TCP (see also the Client Configuration section). |
Connection dropouts are occurring; a client sometimes shows the image from the host PC, sometimes the image of the client's operating system. | A network adapter of the host PC is being used for the CP-Link 3 connection at the same time the adapter is configured as a TwinCAT RT Ethernet adapter (see also the Comments section). | Please use TwinCAT 2.11, Build 1552 or newer, beginning with this version this issue is fixed. Alternative: The network adapter may not be configured as TwinCAT RT Ethernet Adapter. Install the standard Intel® network card driver. |
After touching the client touch screen a dialog opens with question 'Minimize client window?' | Virtual USB is not activated for this client. The touch screen is used as local device. | Activate virtual USB for this client. If needed add HID devices to the USB Device Blacklist in order to prevent user inputs from this client. (see also the Client Configuration section). |
On using an Elo touch screen via 'Virtual USB' the mouse moves, but does not follow the finger. The touch screen calibration fails. | Elo Touchscreen driver is not installed on the host PC or the driver is outdated. | Install a recent Elo Touchscreen driver on the host PC. Run the Elo alignment program on the host PC. |
Setting the HID Focus manually via ADS or using the function block FB_CPLink3_AcquireHidFocus does not work. | Verify the status of the CP-Link 3 Service. Maybe the CP-Link 3 Service needs to be registered or started (see also CP-Link 3 Service section). | |
On using an USB Bus Coupler, the Coupler's outputs drop out or the Bus Coupler does not behave like expected. | Faulty configuration or faulty use of the USB Bus Coupler. Multiple Bus Couplers have identical device numbers. The cycle time for data exchange with the Bus Coupler is too short. | Check the configuration for the use of USB Bus Couplers (see also Using the USB Bus Coupler). Ensure that different device numbers are assigned to all Bus Couplers (see also Device Number of USB Bus Coupler). Use the recommended cycle time for data exchange with the Bus Coupler (see also Cycle time for data exchange). |
The MissedCnt variable of an USB Bus Coupler is incrementing. | The cycle time for data exchange with the Bus Coupler is too short. Faulty configuration of the RT Ethernet when accessing the Bus Coupler via RT Ethernet. | Use the recommended cycle time for data exchange with the Bus Coupler (see also Cycle time for data exchange). Check the RT Ethernet configuration when accessing the Bus Coupler via RT Ethernet (see also 'Virtual USB Interface (Remote)' via RT Ethernet, or Access via network variables (RT Ethernet), or ADS access via RT Ethernet) |
A client's (running Windows XP) USB devices cannot be used if the PC has been started in 'Safe Mode'. | The operating system prevents loading particular CP-Link 3 drivers, because these drivers use network components of the operating system that are not available in 'Safe Mode'. The successful loading of these drivers is a requirement for the operating system to load the USB-Hub driver. Therefore, the USB-Hub driver is not loaded which leads to the client's USB devices to be unusable. | Start the operating system in 'Safe Mode with Networking'. |