tti()

Pass data or error and control codes to io-char

Synopsis:

#include <sys/io-char.h>

int tti(TTYDEV *dev,
        unsigned c );

Arguments:

dev
A pointer to the structure that represents the specific device that data has been received on.
c
Contains received data and control codes that modify how the data is read and processed. See the TTI_* defines below for more details.

Description:

This function forwards data received by the hardware to io-char and passes error/control codes.

The control type is extracted from c, and is one of:

TTI_BREAK
Indicates a “break” signal has been detected by the hardware, or a VINTR character has been received.
TTI_QUIT
Internal to io-char. Indicates a VQUIT character has been received.
TTI_SUSP
Internal to io-char. Indicates a VSUSP character has been received.
TTI_OVERRUN
An overrun has been detected by the hardware.
TTI_FRAME
A framing error has been detected by the hardware.
TTI_PARITY
A parity error has been detected by the hardware.
TTI_CARRIER
Indicates to the io-char library that a carrier was detected (i.e. the hardware modem is online).
TTI_HANGUP
Indicates to io-char that the hardware modem is “hung up.” This type is the opposite of TTI_CARRIER
TTI_OHW_STOP
Used by hardware flow control to stop output.
TTI_OHW_CONT
Used by hardware flow control to start output.

Returns:

If this call returns 0, do nothing. If it returns 1, an event needs to be generated for io-char.

Classification:

QNX Neutrino

Safety:
Cancellation point No
Interrupt handler No
Signal handler No
Thread Yes

See also:

TTYDEV, ttc(), tti2(), tto()