1: struct dcdevice {
2: short dcrcsr; /* receiver status register */
3: short dcrbuf;
4: short dctcsr;
5: short dctbuf;
6: };
7:
8: /* bits in dcrcsr */
9: #define DC_ERR 0100000 /* error */
10: #define DC_CTR 0040000 /* carrier transition */
11: #define DC_RING 0020000 /* ring indicator */
12: #define DC_OVERRUN 0010000 /* data overrun */
13: /* bit 11 is unused */
14: /* bits 10-9 are the character length */
15: #define DC_SXDATA 0000400 /* superv. transmit data */
16: #define DC_DONE 0000200 /* done */
17: #define DC_IE 0000100 /* interrupt enable */
18: #define DC_PCHK 0000040 /* parity check */
19: /* bits 4-3 are the receiver speed */
20: #define DC_CAR 0000004 /* carrier detect */
21: #define DC_BRK 0000002 /* break */
22: #define DC_DTR 0000001 /* data terminal ready */
23: #define DC_BITS \
24: "\10\20ERR\17CTR\16RING\15OVERRUN\11SXDATA\10DONE\7IE\6PCHK\3CAR\2BRK\1DTR"
25:
26: /* character lengths */
27: #define DC_8BITS 0000000 /* 8 bits per character */
28: #define DC_7BITS 0001000 /* 7 bits per character */
29: #define DC_6BITS 0002000 /* 6 bits per character */
30: #define DC_5BITS 0003000 /* 5 bits per character */
31:
32: /* receiver (and transmitter) speeds */
33: #define DC_SPEED0 0000000 /* lowest */
34: #define DC_SPEED1 0000010
35: #define DC_SPEED2 0000020
36: #define DC_SPEED3 0000030 /* highest */
37:
38: /* bits in dctcsr */
39: #define DCTCSR_SRDATA 0100000 /* supervisory receive data */
40: /* bits 14-9 are unused */
41: #define DCTCSR_STOP1 0000400 /* stop code: 0= 2 stop bits */
42: #define DCTCSR_RDY 0000200 /* ready */
43: #define DCTCSR_TIE 0000100 /* transmit interrupt enable */
44: /* bit 5 is unused */
45: /* bits 4-3 are the transmitter speed select */
46: #define DCTCSR_MM 0000004 /* maintenance */
47: #define DCTCSR_CTS 0000002 /* clear to send */
48: #define DCTCSR_RTS 0000001 /* request to send */
49: #define DCTCSR_BITS "\10\20SRDATA\11STOP\10RDY\7TIE\3MM\2CTS\1RTS"
Defined struct's
Defined macros
DC_ERR
defined in line
9;
never used
DC_IE
defined in line
17;
never used