TTYOperations
Defined in: src/drivers/tty/tty.ts:40
What a tty driver has to do to move bytes, i.e. struct tty_operations.
Properties
Section titled “Properties”ioctl?
Section titled “ioctl?”
optionalioctl?:Record<number,TTYIoctl>
Defined in: src/drivers/tty/tty.ts:54
Methods
Section titled “Methods”active()?
Section titled “active()?”
optionalactive(tty):string|undefined
Defined in: src/drivers/tty/tty.ts:53
The terminal this one’s output ends up on, which is only interesting for a tty that
redirects somewhere else. Providing it is what gives the tty an active attribute,
the way only /dev/console and /dev/tty0 have one on Linux.
Parameters
Section titled “Parameters”Returns
Section titled “Returns”string | undefined
close()?
Section titled “close()?”
optionalclose(tty):void
Defined in: src/drivers/tty/tty.ts:44
Parameters
Section titled “Parameters”Returns
Section titled “Returns”void
open()?
Section titled “open()?”
optionalopen(tty):void
Defined in: src/drivers/tty/tty.ts:43
Parameters
Section titled “Parameters”Returns
Section titled “Returns”void
redirect()?
Section titled “redirect()?”
optionalredirect(tty):TTY|undefined
Defined in: src/drivers/tty/tty.ts:59
The terminal a device file really refers to, for a driver that stands in for another terminal.
This is what /dev/tty is: a name for whichever terminal is the console.
Parameters
Section titled “Parameters”Returns
Section titled “Returns”TTY | undefined
set_termios()?
Section titled “set_termios()?”
optionalset_termios(tty,old):void
Defined in: src/drivers/tty/tty.ts:46
Called after the line settings change, e.g. when something turns off echo
Parameters
Section titled “Parameters”Returns
Section titled “Returns”void
shutdown()?
Section titled “shutdown()?”
optionalshutdown(tty):void
Defined in: src/drivers/tty/tty.ts:61
Stop driving the terminal and let go of whatever it is attached to
Parameters
Section titled “Parameters”Returns
Section titled “Returns”void
winsize()?
Section titled “winsize()?”
optionalwinsize(tty):WinSize|undefined
Defined in: src/drivers/tty/tty.ts:47
Parameters
Section titled “Parameters”Returns
Section titled “Returns”WinSize | undefined
write()
Section titled “write()”write(
tty,data):void
Defined in: src/drivers/tty/tty.ts:42
Send bytes to the terminal. They have already been through output processing.
Parameters
Section titled “Parameters”Uint8Array
Returns
Section titled “Returns”void