RE: DOT4PRINT driver.
- From: "Hemanshu Srivastava" <HemanshuSrivastava@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 10 May 2005 02:44:02 -0700
Hi Guillaume,
There is nothing wrong with the procedure you are following.
Actually there could be few reasons for the problem you are facing.
- It could be a timeout problem as you are suspecting. The reason could be a
delayed resonse or no response from the printer.
To exactly know whether the printer is responding you can use a debugger
(may be a usbmonitor) to really check what is happeing on port.
- If you are using high speed, just try with the full speed USB. It may work
because in this case if the device is slow still there is chance to read data.
One very specific case with few printers is taht they dont provide any
bi-directional support through readdata rather through control endpoint they
provide status.
The reason why with DeviIocontrol things are working is that its instant and
through control pipe.
Another option is you can try and put read in a loop with delay.... it wont
solve the problem but isolate the cause.
Hope this helps.
Thanks.
Hemanshu Srivastava
"Guillaume" wrote:
> Dear All,
>
> I would like to send/receive PJL to/from usb printers.
>
> To manage this, I find out that I had to:
>
> - Retrieve printer port from printer name using PRINTER_INFO_2 struct ;
> - Retrieve corresponding USBPrint interface (using setupapi) ;
> - Get the Symbolic path corresponding to the found interface ;
> - Use CreateFile () to open the printer ;
> - Use WriteFile () to send PJL to the printer ;
> - Use ReadFile () to get an answer back from the printer.
>
> Everything works find with Lexmark E321 USB printers.
>
> When I try this with a HP Laserjet 1320n, a timeout happens when
> reading data from the printer. That is weird as I can use
> DeviceIOControl without any problem.
>
> I don't know if it is of interest but HP Laserjet 1320n uses DOT4PRINT
> driver.
> I suspect it may cause the problem. Is there something to do to enable
> DOT4 bidirectionality? Otherwise, what could be the cause of the
> problem I encounter?
>
> I would really appreciate some help on this issue...
>
> Best regards,
>
> Guillaume.
>
>
.
- Follow-Ups:
- Re: DOT4PRINT driver.
- From: Guillaume
- Re: DOT4PRINT driver.
- From: Guillaume
- Re: DOT4PRINT driver.
- References:
- DOT4PRINT driver.
- From: Guillaume
- DOT4PRINT driver.
- Prev by Date: Simple dma access example
- Next by Date: MPEG2 & TestCap Samples
- Previous by thread: DOT4PRINT driver.
- Next by thread: Re: DOT4PRINT driver.
- Index(es):
Relevant Pages
|