DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

standard(ADM)


standard -- interface program used by the print service

Syntax

/usr/spool/lp/model/interface_program

/usr/spool/lp/admins/lp/interfaces/prt rid user title cp opts files

Description

standard is one of a number of printer interface programs that may be used by the print service. When a printer is first installed, lpadmin(ADM) is used to copy an existing or a customized printer interface program to the directory /usr/spool/lp/admins/lp/interfaces. The copied program file is given the same name as the printer (prt).

Several template interface programs are supplied as shell scripts in the directory /usr/spool/lp/model. A program may be specified for use with a printer being installed, or it may be edited into a more suitable form. Refer to ``Setting up printer interface scripts'' in Administering printers and ``Creating printer interface scripts'' in Administering printers for further details about customizing interface programs.

The LP print service runs a printer interface program to send a print request to a printer. The print service opens the printer port as the standard output of the interface program; the standard input is connected to /dev/null. The arguments rid (request-id), user, and title are typically printed on the banner page. cp controls the number of copies of the request to print. opts is a blank-separated list of arguments that were specified using the -o option to lp(C) or lpadmin. The final arguments are the names of files to be printed.

The standard interface program performs the following actions:


The printer interface programs provided are listed in the following table:

Interface program Printer
1640 DASI 1640 terminal
5310 AT&T 5310/20 matrix printer
crnlmap serial or parallel printer requiring <newline> mapped to <carriage return> <line feed>.
dpq10 DQP-10 matrix printer
dumb dumb line printer
emulator Tandy printers in IBM emulation mode
epson Epson serial or parallel printer
f450 DASI 450 terminal
hp Hewlett Packard 2631a line printer
HPDeskJet500 Hewlett Packard DeskJet500, DeskJetPlus, Thinkjet, or QuietJet
HPLaserJet Hewlett Packard LaserJet printers
lqp40 LQP-40 letter quality printer
network Remote UNIX network printing over TCP/IP, UUCP, MICNET, or XENIX-Net
network.ps Remote printing on PostScript printers over UUCP, MICNET, or XENIX-Net
p9XL NEC p9XL printer in IBM/Epson mode
ph.daps Autologic APS-5 phototypesetter
postscript PostScript printer
proprinter IBM Proprinter XL
pprx Parallel Printronix line printer
prx Printronix line printer
qume1155 Qume Sprint 1155 line printer
standard Standard printer interface program
TandyDMP Tandy dot matrix printers
ti800 Texas Instruments 855 printer

 +------------------+-------------------------------------+
 |Interface program | Printer                             |
 +------------------+-------------------------------------+
 |1640              | DASI 1640 terminal                  |
 +------------------+-------------------------------------+
 |5310              | AT&T 5310/20 matrix printer         |
 +------------------+-------------------------------------+
 |crnlmap           | serial or parallel printer          |
 |                  | requiring <newline> mapped to       |
 |                  | <carriage return> <line feed>.      |
 +------------------+-------------------------------------+
 |dpq10             | DQP-10 matrix printer               |
 +------------------+-------------------------------------+
 |dumb              | dumb line printer                   |
 +------------------+-------------------------------------+
 |emulator          | Tandy printers in IBM emulation     |
 |                  | mode                                |
 +------------------+-------------------------------------+
 |epson             | Epson serial or parallel printer    |
 +------------------+-------------------------------------+
 |f450              | DASI 450 terminal                   |
 +------------------+-------------------------------------+
 |hp                | Hewlett Packard 2631a line printer  |
 +------------------+-------------------------------------+
 |HPDeskJet500      | Hewlett Packard DeskJet500,         |
 |                  | DeskJetPlus, Thinkjet, or QuietJet  |
 +------------------+-------------------------------------+
 |HPLaserJet        | Hewlett Packard LaserJet printers   |
 +------------------+-------------------------------------+
 |lqp40             | LQP-40 letter quality printer       |
 +------------------+-------------------------------------+
 |network           | Remote UNIX network printing over   |
 |                  | TCP/IP, UUCP, MICNET, or XENIX-Net  |
 +------------------+-------------------------------------+
 |network.ps        | Remote printing on PostScript       |
 |                  | printers over UUCP, MICNET, or      |
 |                  | XENIX-Net                           |
 +------------------+-------------------------------------+
 |p9XL              | NEC p9XL printer in IBM/Epson mode  |
 +------------------+-------------------------------------+
 |ph.daps           | Autologic APS-5 phototypesetter     |
 +------------------+-------------------------------------+
 |postscript        | PostScript printer                  |
 +------------------+-------------------------------------+
 |proprinter        | IBM Proprinter XL                   |
 +------------------+-------------------------------------+
 |pprx              | Parallel Printronix line printer    |
 +------------------+-------------------------------------+
 |prx               | Printronix line printer             |
 +------------------+-------------------------------------+
 |qume1155          | Qume Sprint 1155 line printer       |
 +------------------+-------------------------------------+
 |standard          | Standard printer interface program  |
 +------------------+-------------------------------------+
 |TandyDMP          | Tandy dot matrix printers           |
 +------------------+-------------------------------------+
 |ti800             | Texas Instruments 855 printer       |
 +------------------+-------------------------------------+
The standard options to lp -o and lpadmin -o that each interface program may recognize are documented on the lp(C) manual page. The option will be ignored if the printer is incapable of satisfying it. Additional options that each program may recognize are documented in the program files themselves. These include options to specify special character sets, to print graphics using special filters, and to alter print quality.

Exit values

The following table shows the exit values that printer interface programs should return to the print service:

Exit value Reason
0 normal exit after print request completes; any printer fault is cleared
1-127 an error occurred printing a request; any printer fault is cleared
129 a problem occurred with the printer; the printer may be disabled or the print service may be suspended for several minutes

 +-----------+--------------------------------------------+
 |Exit value | Reason                                     |
 +-----------+--------------------------------------------+
 |0          | normal exit after print request completes; |
 |           | any printer fault is cleared               |
 +-----------+--------------------------------------------+
 |1-127      | an error occurred printing a request; any  |
 |           | printer fault is cleared                   |
 +-----------+--------------------------------------------+
 |129        | a problem occurred with the printer; the   |
 |           | printer may be disabled or the print       |
 |           | service may be suspended for several       |
 |           | minutes                                    |
 +-----------+--------------------------------------------+

Examples

Install printer caxton on serial line /dev/tty1a to use the postscript interface script:

/usr/lib/lpadmin -p caxton -v /dev/tty1a -m postscript

Install printer gutenberg on serial line /dev/tty1b to use the same interface script as caxton:

/usr/lib/lpadmin -p gutenberg -v /dev/tty1b -e caxton

Install printer tory on serial line /dev/tty1c to use the customized interface script chopped:

/usr/lib/lpadmin -p tory -v /dev/tty1c -i /usr/spool/lp/model/chopped

You can also specify chopped using the -m option because it has been created in the scripts directory:

/usr/lib/lpadmin -p tory -v /dev/tty1c -m chopped

Limitations

An interface program must never return an exit value of 128 or a value greater than 129.

Printer interface programs must not open or close printer ports themselves; they must not uninitialize printers.

Files


/usr/spool/lp/model/*
standard printer interface programs directory

/usr/spool/lp/admins/lp/interfaces/printer
interface program used by printer

See also

lp(C), lp.cat(ADM), lpadmin(ADM), stty(C)

``Managing printers and print jobs'' in Administering printers
``Setting up printer interface scripts'' in Administering printers
``Creating printer interface scripts'' in Administering printers

Standards conformance

The printer interface programs are not part of any currently supported standard; they are an extension of AT&T System V provided by The Santa Cruz Operation, Inc.

The interface program p9XL was developed by Owen DeLong and is used with permission.


© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 03 June 2005