QNX RTOS v4 Knowledge Base
QNX RTOS v4 Knowledge Base
Title |
Information about structures in QNX4 |
Ref. No. |
QNX.000005013 |
Category(ies) |
Development, Character I/O |
Issue |
We're going to write a special "Dev.ser" driver for our own serial protocol.
We need information about the structures "input_buffer", "canon_buffer", "output_buffer" and "termios".
Do you have a description for these structures?
|
Solution |
The termios structure is defined in the /usr/include/termios.h header file:
struct termios { tcflag_t c_iflag; /* Input Modes */ tcflag_t c_oflag; /* Ouput modes */ tcflag_t c_cflag; /* Control Modes */ tcflag_t c_lflag; /* Local Modes */ cc_t c_cc[NCCS]; /* Control Characters */ unsigned short zero[3]; unsigned short c_status; /* device status */ unsigned short c_qflag; /* QNX Specific flags */ unsigned short handle; speed_t c_ispeed; /* Input Baud rate */ speed_t c_ospeed; /* Output baud rate */ };
The source to Dev.ser is available in the free software archive:
http://www.qnx.com/cgi-bin/dir_find.cgi?/usr/free/
That source will show how those structures are used in the original Dev.ser code which should be useful in your application.
See Also: tc* functions in Watcom C Library Reference - N to Z console* functions in Watcom c Library Reference - A to M |
|