Guardian Programmer's Guide

Table Of Contents
Writing a Terminal Simulator
Guardian Programmer’s Guide 421922-014
24 - 10
Processing Control Messages
Processing Control Messages
When the requester calls the Control procedure, a Control message is sent to the
terminal-simulation process. The message has the following format:
A requester can perform many terminal-related operations by calling the CONTROL
procedure. Your terminal-simulation process must determine the appropriate
processing to perform for each CONTROL operation.
Processing Setmode Messages
When the requester process calls the SETMODE procedure, a Setmode system
message is sent to the terminal-simulation process. This message has the following
format:
However, if the terminal-simulation process did not call SETMODE function 80 to allow
requesters to include the last-params parameter on SETMODE calls, then system
message -33 does not include sysmsg[4].
If the terminal-simulation process called SETMODE function 80 to allow the
last-params parameter on SETMODE calls, then the process can use sysmsg[4] to
determine the parameters the requester included in the last SETMODE call that used
the same function value. For example, if sysmsg[4].<15> is set to 1, then the terminal-
simulation process must determine the previous values for this SETMODE function
and return those values in its response. (The value representing the previous param1
can also be an internally defined value that identifies the previous owner of BREAK;
refer to Tracking the BREAK Owner, later in this section.) If this bit is set to 0, the
terminal-simulation process need not return previous parameter values for this
Structure of the Control message (system message -32):
sysmsg[0] = -32
sysmsg[1] = the operation parameter of the CONTROL call
sysmsg[2] = the param parameter of the CONTROL call
Structure of a Setmode system message (message -33):
sysmsg[0] = -33
sysmsg[1] = SETMODE function code
sysmsg[2] = param1 of the SETMODE call
sysmsg[3] = param2 of the SETMODE call
sysmsg[4].<13> = set to 1 if param1 was specified
sysmsg[4].<14> = set to 1 if param2 was specified
sysmsg[4].<15> = set to 1 if last-params was specified