[cups.general] How to send print job to one printer and control code to open cash drawer to another printer (Redirect)

Johannes Meixner jsmeix at suse.de
Wed May 10 01:59:14 PDT 2006


Hello,

On May 9 16:41 Anonymous wrote (shortened):
> 1. Dot matrix printer hooked up as samba printer.
> 2. POS (Point Of Sale) printer, Epson, with a cash drawer
>    connected. Also setup as samba printer.
> Opening the cash drawer is done by a Esc sequence.
> We want to send the print job to dot matrix printer
> and the Esc sequence to Epson to open drawer.

If you like to do it all on your own see for example
http://en.opensuse.org/SDB:Using_Your_Own_Filters_to_Print_with_CUPS
"Adding Additional Filter Stages to the Default CUPS Filter System"

The additional filter could be something like
-------------------------------------------------------------------
#! /bin/bash
# Send ESC sequence to the POS printer via its queue:
echo -en 'ESC sequence' | lp -d 'POS_printer_queue' -o raw
# Have the input at fd0 (stdin) in any case:
[ -n "$6" ] && exec <"$6"
# Forward the actual print job data as is to the next stage:
cat -
-------------------------------------------------------------------


Kind Regards,
Johannes Meixner
-- 
SUSE LINUX Products GmbH, Maxfeldstrasse 5      Mail: jsmeix at suse.de
90409 Nuernberg, Germany                    WWW: http://www.suse.de/





More information about the cups mailing list