Installing WDK 8.1 Generic Text-Only Driver on Windows 10

  • Thread starter Thread starter rpatt1
  • Start date Start date
R

rpatt1

Guest
Hi,

I have to develop a custom printer driver. I would like to use as a starting point the generic text-only driver provided by Microsoft. The driver will be installed on a tablet running Windows 10 Pro, x64.

So I open the WDK 8.1 Generic Text-Only project in Visual Studio Enterprise 2015. I have the WDK 10 installed already. I convert the project from WDK 8.1 to WDK 10 as per this article:

Converting WDK 8.1 Projects to WDK 10 - Windows drivers

I have tried this both with and without a driver package project, it doesn't seem to make a difference. I build the project with Target OS Version = Windows 10 or higher, Target Platform = Desktop, and the platform is x64. I get no errors. If I try to do Target Platform = Universal, I get many warnings which say that the APIs are not universal APIs, maybe this is part of the problem? But Im not sure how to fix that.

I try to install the driver on the target device by selecting the printer in Device Manager, installing driver, selecting "Have Disk" and selecting the location of the INF file. I get the error: "the parameter is incorrect". The setupapi.dev log says everything is fine until this:


dvi: Searching for hardware ID(s):
dvi: usbprint\siimpu-l4656b32
dvi: siimpu-l4656b32
ndv: {Update Driver Software Wizard exit(00000057)}
<<< Section end 2017/06/26 12:42:02.985
<<< [Exit status: FAILURE(0x00000057)]

Then, I modified one line of code in the INF file under the [Generic.NTamd64] heading, so it says this:

"Generic / Text Only" = TTY.GPD, USBPRINT\siimpu-l4656b32

Running the installation again, I get the error "the specified module could not be found".

This is the complete setupapi.dev:


>>> [Device Install (DiShowUpdateDevice) - USBPRINT\SIIMPU-L465\6&13862B1B&8&USB001]
>>> Section start 2017/06/26 12:50:11.210
cmd: "C:\WINDOWS\system32\mmc.exe" C:\WINDOWS\system32\devmgmt.msc
dvi: {DIF_UPDATEDRIVER_UI} 12:50:11.214
dvi: Default installer: Enter 12:50:11.220
dvi: Default installer: Exit
dvi: {DIF_UPDATEDRIVER_UI - exit(0xe000020e)} 12:50:11.225
ndv: {Update Driver Software Wizard - USBPRINT\SIIMPU-L465\6&13862B1B&8&USB001}
dvi: {DIF_SELECTDEVICE} 12:50:22.125
dvi: Using exported function 'ClassInstall32' in module 'C:\WINDOWS\system32\ntprint.dll'.
dvi: Class installer == ntprint.dll,ClassInstall32
dvi: Class installer: Enter 12:50:22.146
dvi: Class installer: Exit
dvi: {DIF_SELECTDEVICE - exit(0xe000020e)} 12:50:22.152
dvi: {DIF_SELECTDEVICE} 12:50:28.686
dvi: Class installer: Enter 12:50:28.689
dvi: Class installer: Exit
dvi: {DIF_SELECTDEVICE - exit(0xe000020e)} 12:50:28.695
sto: {Setup Import Driver Package: c:\users\e\desktop\generic text-only driver\c++\tty.inf} 12:50:29.839
inf: Provider: Microsoft
inf: Class GUID: {4D36E979-E325-11CE-BFC1-08002BE10318}
sto: {Copy Driver Package: c:\users\e\desktop\generic text-only driver\c++\tty.inf} 12:50:29.858
sto: Driver Package = c:\users\e\desktop\generic text-only driver\c++\tty.inf
sto: Flags = 0x00000007
sto: Destination = C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}
sto: Copying driver package files to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\amd64\TTYRES.DLL' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\amd64\TTYRES.DLL'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\amd64\TTY.DLL' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\amd64\TTY.DLL'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\amd64\TTYUI.DLL' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\amd64\TTYUI.DLL'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\TTY.GPD' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\TTY.GPD'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\tty.inf' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\tty.inf'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\TTY.INI' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\TTY.INI'.
flq: Copying 'c:\users\e\desktop\generic text-only driver\c++\TTYUI.HLP' to 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\TTYUI.HLP'.
sto: {Copy Driver Package: exit(0x00000000)} 12:50:30.051
pol: {Driver package policy check} 12:50:30.112
pol: {Driver package policy check - exit(0x00000000)} 12:50:30.115
sto: {Stage Driver Package: C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\tty.inf} 12:50:30.117
inf: {Query Configurability: C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\tty.inf} 12:50:30.147
inf: Driver package 'tty.inf' is configurable.
inf: {Query Configurability: exit(0x00000000)} 12:50:30.164
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\amd64\TTYRES.DLL' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\amd64\TTYRES.DLL'.
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\amd64\TTY.DLL' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\amd64\TTY.DLL'.
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\amd64\TTYUI.DLL' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\amd64\TTYUI.DLL'.
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\TTY.GPD' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\TTY.GPD'.
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\tty.inf' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\tty.inf'.
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\TTY.INI' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\TTY.INI'.
flq: Copying 'C:\Users\e\AppData\Local\Temp\{16b2f579-86c2-3a4b-8ac7-9b23657a2131}\TTYUI.HLP' to 'C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\TTYUI.HLP'.
sto: {DRIVERSTORE IMPORT VALIDATE} 12:50:30.329
! sig: Driver package does not contain a catalog file, but user wants to install anyway.
sto: {DRIVERSTORE IMPORT VALIDATE: exit(0x00000000)} 12:50:32.075
sig: Signer Score = 0x80000000
sig: Signer Name = <unsigned>
sto: {DRIVERSTORE IMPORT BEGIN} 12:50:32.085
bak: Create system restore point:
bak: Description = Device Driver Package Install: Microsoft Printers
bak: Time = 32547ms
bak: Status = 0x00000000 (SUCCESS)
sto: {DRIVERSTORE IMPORT BEGIN: exit(0x00000000)} 12:51:04.658
cpy: {Copy Directory: C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}} 12:51:04.661
cpy: Target Path = C:\WINDOWS\System32\DriverStore\FileRepository\tty.inf_amd64_7b53a905d4319193
cpy: {Copy Directory: C:\WINDOWS\System32\DriverStore\Temp\{eeccd183-94dd-fa4f-b193-7d02bca39ca6}\amd64} 12:51:04.668
cpy: Target Path = C:\WINDOWS\System32\DriverStore\FileRepository\tty.inf_amd64_7b53a905d4319193\amd64
cpy: {Copy Directory: exit(0x00000000)} 12:51:04.682
cpy: {Copy Directory: exit(0x00000000)} 12:51:04.704
idb: {Register Driver Package: C:\WINDOWS\System32\DriverStore\FileRepository\tty.inf_amd64_7b53a905d4319193\tty.inf} 12:51:04.710
idb: Created driver package object 'tty.inf_amd64_7b53a905d4319193' in DRIVERS database node.
idb: Created driver INF file object 'oem53.inf' in DRIVERS database node.
idb: Registered driver package 'tty.inf_amd64_7b53a905d4319193' with 'oem53.inf'.
idb: {Register Driver Package: exit(0x00000000)} 12:51:04.760
idb: {Publish Driver Package: C:\WINDOWS\System32\DriverStore\FileRepository\tty.inf_amd64_7b53a905d4319193\tty.inf} 12:51:04.764
idb: Activating driver package 'tty.inf_amd64_7b53a905d4319193'.
cpy: Published 'tty.inf_amd64_7b53a905d4319193\tty.inf' to 'oem53.inf'.
idb: Indexed 2 device IDs for 'tty.inf_amd64_7b53a905d4319193'.
sto: Flushed driver database node 'DRIVERS'. Time = 63 ms
sto: Flushed driver database node 'SYSTEM'. Time = 16 ms
idb: {Publish Driver Package: exit(0x00000000)} 12:51:04.897
sto: {DRIVERSTORE IMPORT END} 12:51:04.907
dvi: Flushed all driver package files to disk. Time = 31 ms
bak: Commit system restore point:
bak: Description = Device Driver Package Install: Microsoft Printers
bak: Time = 16ms
bak: Status = 0x00000000 (SUCCESS)
sto: {DRIVERSTORE IMPORT END: exit(0x00000000)} 12:51:04.960
sto: {Stage Driver Package: exit(0x00000000)} 12:51:04.989
sto: {Setup Import Driver Package - exit (0x00000000)} 12:51:05.062
dvi: Searching for hardware ID(s):
dvi: usbprint\siimpu-l4656b32
dvi: siimpu-l4656b32
dvi: Class GUID of device changed to: {4d36e979-e325-11ce-bfc1-08002be10318}.
dvi: {DIF_DESTROYPRIVATEDATA} 12:51:05.094
dvi: Class installer: Enter 12:51:05.097
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:05.104
dvi: Default installer: Exit
dvi: {DIF_DESTROYPRIVATEDATA - exit(0xe000020e)} 12:51:05.109
dvi: {Plug and Play Service: Device Install for USBPRINT\SIIMPU-L465\6&13862B1B&8&USB001}
dvi: Driver INF Path: C:\WINDOWS\INF\oem53.inf
dvi: Driver Node Name: tty.inf:c4e39b170769cdc5:TTY.GPD:0.0.0.0:usbprint\siimpu-l4656b32,
dvi: Driver Store Path: C:\WINDOWS\System32\DriverStore\FileRepository\tty.inf_amd64_7b53a905d4319193\tty.inf
dvi: Searching for hardware ID(s):
dvi: usbprint\siimpu-l4656b32
dvi: siimpu-l4656b32
dvi: Class GUID of device changed to: {4d36e979-e325-11ce-bfc1-08002be10318}.
dvi: {Core Device Install} 12:51:05.222
dvi: {Install Device - USBPRINT\SIIMPU-L465\6&13862B1B&8&USB001} 12:51:05.234
dvi: Parent device: USB\VID_0619&PID_0109\5&1b2043cc&0&1
dvi: {Configure Device - USBPRINT\SIIMPU-L465\6&13862B1B&8&USB001} 12:51:05.267
dvi: Parent device: USB\VID_0619&PID_0109\5&1b2043cc&0&1
! dvi: Device class {4d36e979-e325-11ce-bfc1-08002be10318} is not configurable.
dvi: {Configure Device - exit(0x00000032)} 12:51:05.281
dvi: {DIF_ALLOW_INSTALL} 12:51:05.284
dvi: Using exported function 'ClassInstall32' in module 'C:\WINDOWS\system32\ntprint.dll'.
dvi: Class installer == ntprint.dll,ClassInstall32
dvi: Class installer: Enter 12:51:05.325
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:05.339
dvi: Default installer: Exit
dvi: {DIF_ALLOW_INSTALL - exit(0xe000020e)} 12:51:05.345
dvi: {DIF_INSTALLDEVICEFILES} 12:51:05.348
dvi: Class installer: Enter 12:51:05.351
dvi: Class installer: Exit
dvi: {DIF_INSTALLDEVICEFILES - exit(0x00000000)} 12:51:06.305
dvi: {DIF_REGISTER_COINSTALLERS} 12:51:06.310
dvi: Reset Device: Resetting device configuration. 12:51:06.315
dvi: Reset Device: Resetting device configuration completed. 12:51:06.319
dvi: Class installer: Enter 12:51:06.322
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:06.328
dvi: Default installer: Exit
dvi: {DIF_REGISTER_COINSTALLERS - exit(0x00000000)} 12:51:06.339
dvi: {DIF_INSTALLINTERFACES} 12:51:06.342
dvi: Class installer: Enter 12:51:06.349
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:06.355
dvi: Default installer: Exit
dvi: {DIF_INSTALLINTERFACES - exit(0x00000000)} 12:51:06.366
dvi: {DIF_INSTALLDEVICE} 12:51:06.368
dvi: Class installer: Enter 12:51:06.371
!!! dvi: Class installer: failed(0x0000007e)!
!!! dvi: Error 126: The specified module could not be found.
dvi: {DIF_INSTALLDEVICE - exit(0x0000007e)} 12:51:06.567
!!! dvi: Error(0000007e) installing device!
! dvi: Queueing up error report since device installation failed...
dvi: {Install Device - exit(0x0000007e)} 12:51:06.586
dvi: {Core Device Install - exit(0x0000007e)} 12:51:06.589
dvi: {DIF_DESTROYPRIVATEDATA} 12:51:06.592
dvi: Class installer: Enter 12:51:06.595
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:06.601
dvi: Default installer: Exit
dvi: {DIF_DESTROYPRIVATEDATA - exit(0xe000020e)} 12:51:06.608
ump: {Plug and Play Service: Device Install exit(0000007e)}
!!! ndv: Device install failed for device.
!!! ndv: Error 126: The specified module could not be found.
ndv: Installing NULL driver.
dvi: {Plug and Play Service: Device Install for USBPRINT\SIIMPU-L465\6&13862B1B&8&USB001}
! dvi: Installing NULL driver!
dvi: {DIF_ALLOW_INSTALL} 12:51:07.213
dvi: Using exported function 'ClassInstall32' in module 'C:\WINDOWS\system32\ntprint.dll'.
dvi: Class installer == ntprint.dll,ClassInstall32
dvi: Class installer: Enter 12:51:07.249
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:07.258
dvi: Default installer: Exit
dvi: {DIF_ALLOW_INSTALL - exit(0xe000020e)} 12:51:07.264
dvi: {DIF_REGISTER_COINSTALLERS} 12:51:07.267
dvi: Class installer: Enter 12:51:07.271
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:07.276
dvi: Default installer: Exit
dvi: {DIF_REGISTER_COINSTALLERS - exit(0x00000000)} 12:51:07.283
dvi: {DIF_INSTALLDEVICE} 12:51:07.286
dvi: Class installer: Enter 12:51:07.289
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:07.296
! dvi: Installing NULL driver!
dvi: Install Null Driver: Removing device sub-tree. 12:51:07.307
dvi: Install Null Driver: Removing device sub-tree completed. 12:51:07.324
dvi: Install Null Driver: Restarting device. 12:51:07.337
dvi: Install Null Driver: Restarting device completed. 12:51:07.345
dvi: Install Device: Configuring device class. 12:51:07.348
dvi: Install Device: Configuring device class completed. 12:51:07.352
dvi: Install Device: Starting device. 12:51:07.355
dvi: Install Device: Starting device completed. 12:51:07.371
dvi: Default installer: Exit
dvi: {DIF_INSTALLDEVICE - exit(0x00000000)} 12:51:07.380
dvi: {DIF_DESTROYPRIVATEDATA} 12:51:07.385
dvi: Class installer: Enter 12:51:07.388
dvi: Class installer: Exit
dvi: Default installer: Enter 12:51:07.394
dvi: Default installer: Exit
dvi: {DIF_DESTROYPRIVATEDATA - exit(0xe000020e)} 12:51:07.399
ump: {Plug and Play Service: Device Install exit(00000000)}
ndv: {Update Driver Software Wizard exit(0000007e)}
<<< Section end 2017/06/26 12:54:06.948
<<< [Exit status: FAILURE(0x0000007e)]


Could someone please explain what Im doing wrong?

Continue reading...
 
Back
Top