/********************************************************************* * file: sys/lp.h * part #: * internal sequence #: * * ************************************************************ * * " (c) Copyright Hewlett-Packard Company, 1984. All * * * rights are reserved. Copying or other reproduction * * * of this program except for archival purposes is * * * prohibited without the prior written consent of * * * Hewlett-Packard Company." * * ************************************************************ * * * This file contains line printer driver definitions. * * Pisces Q-DOS project * Jay Phillips PCD * * $Log$ * ************************************************************************/ /************************************************************************ * * Major device numbers for the different printer interfaces * Except that 0 is used for internal printer. * ************************************************************************/ #define INTERNAL_PRINTER 0 #define HPIB_PRINTER 19 #define RS_232_PRINTER 4 #define LP_MAJOR 7 /* major dev number for driver */ #define LP_MINOR 0 /* minor dev number for driver */ /************************************************************************ * * Line printer driver ioctl command definitions * ************************************************************************/ #define LP_CHANGE (('L' << 8) | 0) #define LP_ID (('L' << 8) | 1) #define LP_GETCTLBITS (('L' << 8) | 3) #define LP_SETCTLBITS (('L' << 8) | 4) /************************************************************************ * * Misc. * ************************************************************************/ #define TRUE 1 #define FALSE 0 /************************************************************************ * * Printer flags * ************************************************************************/ #define LP_COOKED 0x00010000 /* cooked mode flag */ #define LP_HANDSHAKE 0x0000c000 /* handshake control field */ #define LP_ENQACK 1 /* enquire-acknowledge */ #define LP_XONXOFF 2 /* xon-xoff */ #define LP_HARDWARE 3 /* hardware handshake */ #define LP_HAND_SHIFT 14 /* handshake value shift factor */ #define LP_NLON 0x00002000 /* newline mapping is on */ #define LP_EXPTAB 0x00001000 /* tab expansion is on */ #define LP_INDENT 0x00000f00 /* no. of cols to indent */ #define LP_INDENT_SHIFT 8 /* indent value shift factor */ #define LP_PARITY 0x00000080 /* parity on/off */ #define LP_PAREVEN 0x00000040 /* parity odd/even */ #define LP_1STOPBIT 0x00000020 /* stop bits 1/2 */ #define LP_BAUD 0x0000001f /* baud rate */ #define LPB0 0x00 /* hangup */ #define LPB50 0x01 /* 50 baud */ #define LPB75 0x02 /* 75 baud */ #define LPB110 0x03 /* 110 baud */ #define LPB134 0x04 /* 134.5 baud */ #define LPB150 0x05 /* 150 baud */ #define LPB200 0x06 /* 200 baud */ #define LPB300 0x07 /* 300 baud */ #define LPB600 0x08 /* 600 baud */ #define LPB900 0x09 /* 900 baud */ #define LPB1200 0x0a /* 1200 baud */ #define LPB1800 0x0b /* 1800 baud */ #define LPB2400 0x0c /* 2400 baud */ #define LPB3600 0x0d /* 3600 baud */ #define LPB4800 0x0e /* 4800 baud */ #define LPB7200 0x0f /* 7200 baud */ #define LPB9600 0x10 /* 9600 baud */ #define LPB19200 0x11 /* 19200 baud */ #define LPB38400 0x12 /* 38400 baud */ /************************************************************************ * * Data structures * ************************************************************************/ struct driv_info { int id; int type; }; struct p_change { int pid; dev_t dev; }; struct set_ctl { int pid; long control; };