Reference Guide
ZCOM C I/F Library Routines
ZCNTL (3X)
Chapter 4 173
NOTES 1. File /opt/acc/include/zcom/zcomsys.h contains the symbolic names
for rcode (not all of them are applicable to zcntl):
/* Message request code values applicable to zcntl() */
#define ZCOM_MRQCODE_CNTWR 3 /* Terminal write */
#define ZCOM_MRQCODE_STATUS 5 /* Unsolicited status change */
#define ZCOM_MRQCODE_TERM 6 /* Set terminal parameters */
#define ZCOM_MRQCODE_ENB 7 /* Terminal enable */
#define ZCOM_MRQCODE_DSB 8 /* Terminal disable */
#define ZCOM_MRQCODE_ACT 9 /* Terminal activate */
#define ZCOM_MRQCODE_DEA 10 /* Terminal deactivate */
2. The result for a zcntl request is returned in the rstat parameter if
mode=8, or may be returned in a response message via zread(3X) if
another non-zero mode is specified. Refer to the NOTES section in
zsend(3X) for more information on the mode parameter. See
zread(3X) for more details on response messages.
3. For rcode=ZCOM_MRQCODE_TERM (Set terminal parameters), the
terminal configuration data in ibuf must be set as follows. Refer to
/opt/acc/include/zcom/zcomsys.h for these data structures:
For any ACC card except an i960 4-channel ACC card:
Data structure: ztrq_type
Must set RTYP bit = 0.
ibuf, len If rcode=ZCOM_MRQCODE_CNTWR, ibuf contains the control data for
the protocol, and len indicates the length of the control data. If
rcode=ZCOM_MRQCODE_TERM, ibuf contains the configuration data
for the terminal as described below, and the len indicates the total length
of the configuration data. For other values of rcode, ibuf and len are not
used.
rstat
(Return
Param)
Return status. Only used for requests issued with âwaitâ, i.e. mode =
ZMODE_WAIT. NULL may be used if the return status is not required.
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0RTYP0 Terminal Type -----Port #
2 Group Poll Code Device Poll Code
4 Group Select Code Device Select Code