Manual page for hpnptyd(8C)
hpnptyd - HP network peripheral pty daemon
SYNOPSIS
hpnptyd
-m master_pty -x peripheral [-fk]
[-p port] [-t timeout]
[-l logfile]
DESCRIPTION
Hpnptyd
provides a network connection between a pseudo terminal
(pty) and an HP network peripheral. A
daemon process is invoked for each network connection.
For applications that operate on serial ports,
operating on a pty has the appearance of operating
on a local serial port.
Hpnptyd
opens the network connection when there is data from the pty.
Data from the pty is sent to the peripheral over the network
connection. Data from the peripheral is passed back to the pty.
After a period when there is no more data from the pty, no more
data from the network peripheral, and all
the pty data has been sent to the network peripheral, the
network connection is closed. The length of the inactivity period
can be specified by the timeout command line value.
Note: The printjob is not re-sent if the peripheral is power cycled
while the job is printing. Also, if the printjob is small, the sending
application may complete sending and the printjob has not
been printed yet. The printjob may
be buffered at the pty or at hpnptyd
waiting to be sent to the peripheral.
Normally hpnptyd is started at bootup from /etc/rc.
When using hpnptyd, the print scheduler must
be started after starting the pty daemons.
Options are:
- -f
-
Run in the foreground. Normally, hpnptyd runs in the background.
- -k
-
Keep the network connection open. This option can be used
in conjunction with the
SIGHUP
signal to externally control when the network connection is
closed down. After the network connection is closed, new
data from the pty will cause the connection to be re-opened.
- -l logfile
-
Send verbose logging messages to file
logfile. The logging messages are detailed messages about
what hpnptyd is doing. Included in the messages are how
many bytes are read and written to the pty and to the network connection.
If this option is omitted, no logging is performed.
- -m master_pty
-
Specify
master_pty
as the master (or
controller) pty for a network connection.
For each master pty, there will be a
corresponding slave pty; application
programs interface to the slave pty.
The naming conventions for pty's will vary
from operating system to operating system;
consult your system documentation.
- -p port
-
Specify
port
as the TCP/IP port number for a
network connection. The default port
number is 9100.
- -t timeout
-
Specify
timeout
as the timeout period for a network connection. If there is no data
from the pty or from the network peripheral for timeout seconds
and all the data read so far
has been written to the network peripheral, the network connection
is closed. New data from the pty causes the network connection to
be re-opened. The default timeout is 30 seconds. A timeout of 0
is not allowed.
- -x peripheral
-
Specify
peripheral
as the peripheral for printing.
This may be a host name
or dotted decimal Internet address.
The following signals have the specified effect when sent to hpnptyd
using the
kill.1
command:
- SIGHUP
-
Causes hpnptyd to close the network connection after a
timeout interval of no activity between the pty and network peripheral.
- SIGUSR1
-
Turns on logging. If a log file was specified, it is appended to.
If no log file was specified, logging messages are written to
/var/tmp/hpnptyd.<PID>.
- SIGUSR2
-
Turns off logging.
EXAMPLES
To start up a single network connection from pty
/dev/ptypa to peripheral foobar:
/usr/lib/hpnp/hpnptyd -m /dev/ptypa -x foobar
To send the contents of file plot1 over the network
connection in the previous example:
cat plot1 >/dev/ttypa
FILES
- /dev/pty[pqr][0-9a-f]
-
master pseudo terminals
- /dev/tty[pqr][0-9a-f]
-
slave pseudo terminals
- /var/tmp/hpnptyd.<PID>
-
default log file name
SEE ALSO
pty(4), hpnpf(8C)
Created by unroff & hp-tools.
© somebody (See intro for details). All Rights Reserved.
Last modified 11/5/97