termios

Imports

posix

Types

Speed = cuint
Source Edit
Cflag = cuint
Source Edit
Termios {...}{.importc: "struct termios", header: "<termios.h>".} = object
  c_iflag*: Cflag
  c_oflag*: Cflag
  c_cflag*: Cflag
  c_lflag*: Cflag
  c_line*: cuchar
  c_cc*: array[NCCS, cuchar]
  c_ispeed*: Speed
  c_ospeed*: Speed
Source Edit
IOctl_WinSize = object
  ws_row*, ws_col*, ws_xpixel*, ws_ypixel*: cushort
Source Edit

Vars

VINTR: cint
Source Edit
VQUIT: cint
Source Edit
VERASE: cint
Source Edit
VKILL: cint
Source Edit
VEOF: cint
Source Edit
VTIME: cint
Source Edit
VMIN: cint
Source Edit
VSTART: cint
Source Edit
VSTOP: cint
Source Edit
VSUSP: cint
Source Edit
VEOL: cint
Source Edit
IGNBRK: Cflag
Source Edit
BRKINT: Cflag
Source Edit
IGNPAR: Cflag
Source Edit
PARMRK: Cflag
Source Edit
INPCK: Cflag
Source Edit
ISTRIP: Cflag
Source Edit
INLCR: Cflag
Source Edit
IGNCR: Cflag
Source Edit
ICRNL: Cflag
Source Edit
IUCLC: Cflag
Source Edit
IXON: Cflag
Source Edit
IXANY: Cflag
Source Edit
IXOFF: Cflag
Source Edit
OPOST: Cflag
Source Edit
ONLCR: Cflag
Source Edit
OCRNL: Cflag
Source Edit
ONOCR: Cflag
Source Edit
ONLRET: Cflag
Source Edit
OFILL: Cflag
Source Edit
OFDEL: Cflag
Source Edit
NLDLY: Cflag
Source Edit
NL0: Cflag
Source Edit
NL1: Cflag
Source Edit
CRDLY: Cflag
Source Edit
CR0: Cflag
Source Edit
CR1: Cflag
Source Edit
CR2: Cflag
Source Edit
CR3: Cflag
Source Edit
TABDLY: Cflag
Source Edit
TAB0: Cflag
Source Edit
TAB1: Cflag
Source Edit
TAB2: Cflag
Source Edit
TAB3: Cflag
Source Edit
BSDLY: Cflag
Source Edit
BS0: Cflag
Source Edit
BS1: Cflag
Source Edit
FFDLY: Cflag
Source Edit
FF0: Cflag
Source Edit
FF1: Cflag
Source Edit
VTDLY: Cflag
Source Edit
VT0: Cflag
Source Edit
VT1: Cflag
Source Edit
B0: Speed
Source Edit
B50: Speed
Source Edit
B75: Speed
Source Edit
B110: Speed
Source Edit
B134: Speed
Source Edit
B150: Speed
Source Edit
B200: Speed
Source Edit
B300: Speed
Source Edit
B600: Speed
Source Edit
B1200: Speed
Source Edit
B1800: Speed
Source Edit
B2400: Speed
Source Edit
B4800: Speed
Source Edit
B9600: Speed
Source Edit
B19200: Speed
Source Edit
B38400: Speed
Source Edit
B57600: Speed
Source Edit
B115200: Speed
Source Edit
B230400: Speed
Source Edit
B460800: Speed
Source Edit
B500000: Speed
Source Edit
B576000: Speed
Source Edit
B921600: Speed
Source Edit
B1000000: Speed
Source Edit
B1152000: Speed
Source Edit
B1500000: Speed
Source Edit
B2000000: Speed
Source Edit
B2500000: Speed
Source Edit
B3000000: Speed
Source Edit
B3500000: Speed
Source Edit
B4000000: Speed
Source Edit
EXTA: Speed
Source Edit
EXTB: Speed
Source Edit
CSIZE: Cflag
Source Edit
CS5: Cflag
Source Edit
CS6: Cflag
Source Edit
CS7: Cflag
Source Edit
CS8: Cflag
Source Edit
CSTOPB: Cflag
Source Edit
CREAD: Cflag
Source Edit
PARENB: Cflag
Source Edit
PARODD: Cflag
Source Edit
HUPCL: Cflag
Source Edit
CLOCAL: Cflag
Source Edit
ISIG: Cflag
Source Edit
ICANON: Cflag
Source Edit
ECHO: Cflag
Source Edit
ECHOE: Cflag
Source Edit
ECHOK: Cflag
Source Edit
ECHONL: Cflag
Source Edit
NOFLSH: Cflag
Source Edit
TOSTOP: Cflag
Source Edit
IEXTEN: Cflag
Source Edit
TCOOFF: cint
Source Edit
TCOON: cint
Source Edit
TCIOFF: cint
Source Edit
TCION: cint
Source Edit
TCIFLUSH: cint
Source Edit
TCOFLUSH: cint
Source Edit
TCIOFLUSH: cint
Source Edit
TCSANOW: cint
Source Edit
TCSADRAIN: cint
Source Edit
TCSAFLUSH: cint
Source Edit
TIOCGWINSZ: culong
Source Edit

Consts

NCCS = 32
Source Edit

Procs

proc cfGetOspeed(termios: ptr Termios): Speed {...}{.importc: "cfgetospeed",
    header: "<termios.h>".}
Source Edit
proc cfGetIspeed(termios: ptr Termios): Speed {...}{.importc: "cfgetispeed",
    header: "<termios.h>".}
Source Edit
proc cfSetOspeed(termios: ptr Termios; speed: Speed): cint {...}{.
    importc: "cfsetospeed", header: "<termios.h>".}
Source Edit
proc cfSetIspeed(termios: ptr Termios; speed: Speed): cint {...}{.
    importc: "cfsetispeed", header: "<termios.h>".}
Source Edit
proc tcGetAttr(fd: cint; termios: ptr Termios): cint {...}{.importc: "tcgetattr",
    header: "<termios.h>".}
Source Edit
proc tcSetAttr(fd: cint; optional_actions: cint; termios: ptr Termios): cint {...}{.
    importc: "tcsetattr", header: "<termios.h>".}
Source Edit
proc tcSendBreak(fd: cint; duration: cint): cint {...}{.importc: "tcsendbreak",
    header: "<termios.h>".}
Source Edit
proc tcDrain(fd: cint): cint {...}{.importc: "tcdrain", header: "<termios.h>".}
Source Edit
proc tcFlush(fd: cint; queue_selector: cint): cint {...}{.importc: "tcflush",
    header: "<termios.h>".}
Source Edit
proc tcFlow(fd: cint; action: cint): cint {...}{.importc: "tcflow",
    header: "<termios.h>".}
Source Edit
proc ioctl(fd: cint; request: culong; reply: ptr IOctl_WinSize): int {...}{.
    importc: "ioctl", header: "<stdio.h>", varargs.}
Source Edit

Templates

template cceq(val, c): untyped
Source Edit

© 2006–2021 Andreas Rumpf
Licensed under the MIT License.
https://nim-lang.org/docs/termios.html