1 /* hp2648.h 4.1 83/11/10 */ 2 /* 3 * Displays plot files on an hp2648a graphics terminals. I have heard 4 * that all hp plotting devices use the same control sequences, so this 5 * might work for all hp devices capable of plotting. 6 */ 7 8 #include <stdio.h> 9 10 #define TERMINAL "/dev/tty" 11 12 #define ENQ 05 13 #define ACK 06 14 #define ESC 033 15 #define GRAPHIC '*' 16 #define MODE 'm' 17 #define PLOT 'p' 18 #define DISPLAY 'd' 19 #define PENUP 'a' 20 #define BINARY 'i' 21 #define ASCII 'f' 22 #define CR '\n' 23 24 #define TRUE 1 25 #define FALSE 0 26 27 #define xsc(xi) ((int) (xi - lowx) * scalex + 0.5) 28 #define ysc(yi) ((int) (yi - lowy) * scaley + 0.5) 29 30 extern int shakehands; 31 extern int currentx; 32 extern int currenty; 33 extern int buffcount; 34 extern int fildes; 35 extern float lowx; 36 extern float lowy; 37 extern float scalex; 38 extern float scaley; 39 extern struct sgttyb sarg; 40