AnsweredAssumed Answered

USB Printer Device driver and IEEE Device ID string

Question asked by matt lang on Oct 28, 2013

I have an MCF51JE256CLK that I made a printer device. It enumerates as a printing device and loads the standard kernal mode driver for printing on windows. USBPrint.sys. I can print to it by using the "Add Printer" Wizard for windows and open a USB001 port. But my device still lives in the unspecified category in "Devices and Printers".

 

What I would like to do is use an existing .dll user mode driver with a custom .inf and .GPD file. To my understanding, windows checks all the .inf files when a device is plugged in and finds the one with the best "rank". Would I be able to write an .inf file that makes windows pick my .inf file as the best one, and have the file point to an existing printer .dll and a custom .GPD? For example the generic text only driver or some PCL6 driver

 

My other question is: The PC never asks for my Device ID string that describes my printers capabilities such as manufacturer and PCL. When is the PC supposed to ask for this?

 

  1. uint_8 printer_device_id[PRINTER_DEVICE_ID_STRING_SIZE] =  
  2. {  
  3.  
  4.      0x00,0x42,      // Length of the Device ID string (MSB/LSB) including the 
  5.     'M',            // two length bytes 
  6.     'A'
  7.     'N'
  8.     'U'
  9.     'F'
  10.     'A'
  11.     'C'
  12.     'T'
  13.     'U'
  14.     'R'
  15.     'E'
  16.     'R'
  17.     ':'
  18.     'X'
  19.     'X'
  20.     'X'
  21.     'X'
  22.     'X'
  23.     'X'
  24.     ';'
  25.     'M'
  26.     'O'
  27.     'D'
  28.     'E'
  29.     'L'
  30.     ':'
  31.     'P'
  32.     'T'
  33.     'I'
  34.     '-'
  35.     'P'
  36.     'R'
  37.     '0'
  38.     '0'
  39.     '1'
  40.     ';'
  41.     'C'
  42.     'O'
  43.     'M'
  44.     'M'
  45.     'A'
  46.     'N'
  47.     'D'
  48.     ' '
  49.     'S'
  50.     'E'
  51.     'T'
  52.     ':'
  53.     'P'
  54.     'C'
  55.     'L'
  56.     '5'
  57.     ';'
  58.     'C'
  59.     'L'
  60.     'S'
  61.     ':'
  62.     'P'
  63.     'R'
  64.     'I'
  65.     'N'
  66.     'T'
  67.     'E'
  68.     'R'
  69.     ';' 
  70. }; 

 

 

Thanks

Outcomes