home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-387-Vol-3of3.iso / e / emxdev8f.zip / TERMIO.H < prev    next >
C/C++ Source or Header  |  1992-08-28  |  3KB  |  135 lines

  1. /* sys/termio.h (emx+gcc) */
  2.  
  3. #if !defined (_SYS_TERMIO_H)
  4. #define _SYS_TERMIO_H
  5.  
  6. /* request codes */
  7.  
  8. #if !defined (TCGETA)
  9. #define TCGETA      1
  10. #define TCSETA      2
  11. #define TCSETAW     3
  12. #define TCSETAF     4
  13. #define TCFLSH      5
  14. #endif
  15.  
  16. /* c_cc indexes */
  17.  
  18. #define VINTR       0
  19. #define VQUIT       1
  20. #define VERASE      2
  21. #define VKILL       3
  22. #define VEOF        4
  23. #define VEOL        5
  24. #define VMIN        6
  25. #define VTIME       7
  26.  
  27. #define NCC         8   /* Number of the above */
  28.  
  29. /* c_iflag, emx ignores most of the following bits */
  30.  
  31. #define IGNBRK      0x0001
  32. #define BRKINT      0x0002
  33. #define IGNPAR      0x0004
  34. #define PARMRK      0x0008
  35. #define INPCK       0x0010
  36. #define ISTRIP      0x0020
  37. #define INLCR       0x0040
  38. #define IGNCR       0x0080
  39. #define ICRNL       0x0100
  40. #define IUCLC       0x0200
  41. #define IXON        0x0400
  42. #define IXANY       0x0800
  43. #define IXOFF       0x1000
  44. #define IDELETE     0x8000  /* emx */
  45.  
  46. /* c_oflag, emx ignores all of the following bits */
  47.  
  48. #define OPOST       0x0001
  49. #define OLCUC       0x0002
  50. #define ONLCR       0x0004
  51. #define OCRNL       0x0008
  52. #define ONOCR       0x0010
  53. #define ONLRET      0x0020
  54. #define OFILL       0x0040
  55. #define OFDEL       0x0080
  56. #define NLDLY       0x0100 /* mask */
  57. #define NL0         0x0000
  58. #define NL1         0x0100
  59. #define CRDLY       0x0600 /* mask */
  60. #define CR0         0x0000
  61. #define CR1         0x0200
  62. #define CR2         0x0400
  63. #define CR3         0x0600
  64. #define TABDLY      0x1800 /* mask */
  65. #define TAB0        0x0000
  66. #define TAB1        0x0800
  67. #define TAB2        0x1000
  68. #define TAB3        0x1800
  69. #define BSDLY       0x2000 /* mask */
  70. #define BS0         0x0000
  71. #define BS1         0x2000
  72. #define VTDLY       0x4000 /* mask */
  73. #define VT0         0x0000
  74. #define VT1         0x4000
  75. #define FFDLY       0x8000 /* mask */
  76. #define FF0         0x0000
  77. #define FF1         0x8000
  78.  
  79. /* c_cflag, emx ignores all of the following bits */
  80.  
  81. #define CBAUD       0x000f /* mask */
  82. #define B0          0x0000
  83. #define B50         0x0001
  84. #define B75         0x0002
  85. #define B110        0x0003
  86. #define B134        0x0004
  87. #define B150        0x0005
  88. #define B200        0x0006
  89. #define B300        0x0007
  90. #define B600        0x0008
  91. #define B1200       0x0009
  92. #define B1800       0x000a
  93. #define B2400       0x000b
  94. #define B4800       0x000c
  95. #define B9600       0x000d
  96. #define B19200      0x000e
  97. #define B38400      0x000f
  98. #define CSIZE       0x0030 /* mask */
  99. #define CS5         0x0000
  100. #define CS6         0x0010
  101. #define CS7         0x0020
  102. #define CS8         0x0030
  103. #define CSTOPB      0x0040
  104. #define CREAD       0x0080
  105. #define PARENB      0x0100
  106. #define PARODD      0x0200
  107. #define HUPCL       0x0400
  108. #define CLOCAL      0x0800
  109. #define LOBLK       0x1000
  110.  
  111. /* c_lflag, emx ignores some of the following bits */
  112.  
  113. #define ISIG        0x0001
  114. #define ICANON      0x0002
  115. #define XCASE       0x0004
  116. #define ECHO        0x0008
  117. #define ECHOE       0x0010
  118. #define ECHOK       0x0020
  119. #define ECHONL      0x0040
  120. #define NOFLSH      0x0080
  121. #define IDEFAULT    0x8000  /* emx */
  122.  
  123.  
  124. struct termio
  125. {
  126.   unsigned int  c_iflag;
  127.   unsigned int  c_oflag;
  128.   unsigned int  c_cflag;
  129.   unsigned int  c_lflag;
  130.   unsigned int  c_line;
  131.   unsigned char c_cc[NCC];
  132. };
  133.  
  134. #endif /* !defined (_SYS_TERMIO_H) */
  135.