dcsimg
how to get the parallel port's answer
2 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Marcos_Cisneros
Posted On:   Thursday, July 4, 2002 02:35 PM

I am printing text in a red hat 7.2 by opening a FileWriter to /dev/lp0 and the printer works. But my problem is how to get any response from the printer or the port on my java application. I have tried with FileReader but only return I/O error. I need to do this in order to know when the printer has not paper o something like that.

Thanks for attention.

Acme

Re: how to get the parallel port's answer

Posted By:   Rob_Taft  
Posted On:   Wednesday, August 7, 2002 01:32 PM

A: Your first problem is that your trying to read a file from the lp0. I was suprised you could write to it.
B: javax.comm wont work either, because its linux. Theres a library called gnu.io that might help. Another thing is, it may be responding with a few bytes that may be meaningless to you, and you may need some info about the data sent back from the printer.

Re: how to get the parallel port's answer

Posted By:   Scott_Yaung  
Posted On:   Sunday, July 21, 2002 01:35 PM

have u try java comm?
I have not try it in Linux yet
About | Sitemap | Contact