News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

Printer driver

Started by Magnum, March 31, 2013, 03:13:51 AM

Previous topic - Next topic

Magnum

I decided to use the KMD Kit and write a driver to detect if my printer is ready.

I don't know what I would use in it.

Since I can access any port, I am thinking I would query the printer port ?

Andy
Take care,
                   Andy

Ubuntu-mate-18.04-desktop-amd64

http://www.goodnewsnetwork.org

dedndave

you have to somehow get from a named printer device to a port
that's a pretty big step   :P
and - it may be a serial, parallel, USB, or network printer
direct to the port - doesn't sound good

there are a few "layers" of isolation between the GetPrinter API and the physical printer
the API communicates with the monitor - the monitor communicates with the device driver, and so on

the problem, in this case, seems to be the requirements of the monitor are met without providing constant status
so - if you can figure out how to communicate with the driver - might be the simplest code

communicating with a driver usually includes OpenFile, DeviceIoControl, CloseHandle

Magnum

I just saw that my printer port is a virtual port, reckin that's what you mean by isolated.

Since Farabi's code works, that should be the easiest way.

I just thought of something I will research.

All U.S.B. ports I have are either used for the mouse or a printer.

I should be able to send something to the non-mouse ports and get some kind of yay or nay ?

Take care,
                   Andy

Ubuntu-mate-18.04-desktop-amd64

http://www.goodnewsnetwork.org