LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to detect a serial printer programmatically?


@sebster wrote:

I looked at the manual for your printer and on page 17 (actually page 21 of the document) is the following information on Control Codes:

 

CODE ENQ (05)H

FUNCTION Enquiry

OUTLINE

When this code is received, the printer outputs status data.

If it is input after text data input in the STX-ETX mode, the

printer outputs status data and the check byte.

 

I don't have access to this printer (or any other similar models) to try this out but could this be of any use to you?

 

 


Interesting!  If that doesn't work, maybe you'll have to do a VISA inquiry and if you get that error code, the printer is there.  If there is NO error code, the rinter is NOT there.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 11 of 13
(587 Views)

Unfortunately, I don't think that will work. As Rolf pointed out that test will only prove that the printer drivers are using the port.

 

Mike...


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 12 of 13
(577 Views)

@mikeporter wrote:

Unfortunately, I don't think that will work. As Rolf pointed out that test will only prove that the printer drivers are using the port.

 

Mike...


I'm guessing that the printer driver will do the exact ID thingy as was discussed earlier and will release control of the COM port if it doesn't see the printer.  If it DOESN'T, then I am thinking you might have problems bigger than printer detection...

 

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 13 of 13
(568 Views)