Meaningless Drivel is fun!*
The moose likes I/O and Streams and the fly likes Need help with POS printer Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » I/O and Streams
Bookmark "Need help with POS printer" Watch "Need help with POS printer" New topic
Author

Need help with POS printer

Bayless Kirtley
Greenhorn

Joined: May 14, 2007
Posts: 1
I have a 100% Java POS application. The receipt printer is installed as the default Windows XP printer but on a USB port. I am using the Java Printable interface to print receipts. I insert the needed text, etc into a JLabel and print it. This all works fine. My problem is opening the cash drawer which is attached to the printer. I must send a 0x07 (ASCII BEL character) to the printer which then opens the drawer. For some reason the bel never gets sent.

Is the JLabel removing it? I know it is possible to send it through a Windows printer as there is a test provided with the printer and it works. I have also tried sending the 07 directly to the printer as a Java byte. I have tried opening both the Windows printer name and the USB port as files but that also does not work.

If anyone has an answer, I will forever be in your debt.

Thanks in advance,
Bayless
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Need help with POS printer