General
Application areas: | Starting, interrupting and terminating; see "Starting, interrupting and terminating"STXIT processing; see "STXIT procedure with contingency processing" |
Macro type: | Type S, MF format 1: standard/L/E form; see "S-type macros" |
Macro description
The SETIC macro enables a time interval for the CPU time and/or the real time to be defined and the summer/winter time change event to be indicated. After the time interval has elapsed, a “CPU time interval elapsed” or “real time interval elapsed” or “summer/winter time change” interrupt event is signaled, and a STXIT routine allocated in the calling program is activated (see the STXIT macro). If this does not happen, the program is terminated.
Functional description
The Executive sets interval timers to the values specified in the SETIC macro. As soon as these values are reached, the user program is interrupted. The system generates the event X'20' for “CPU time interval elapsed” and/or X'A0' for “Real time interval elapsed” and/or
X'20' for “summer/winter time change”, and - if specified by STXIT - control is passed to the interrupt routine for the appropriate timers. If no interrupt routine was specified in the STXIT macro, the program is terminated on occurrence of a timer interrupt.
Once the interrupt has been initiated, the Executive resets the timer to the value specified in the SETIC macro. The interrupts will occur regularly at given intervals or times of day, as specified, until the the time interval is changed by another SETIC macro or deactivated by specification of the value zero. If “REPEAT=NO” is specified, repeating of the intervals can be suppressed.
If the task is in a PASS/VPASS wait state when the real-time interval elapses, this wait state is not interrupted. Control is not passed to the specified STXIT routine until the wait state has terminated.
Macro format and description of operands
SETIC |
[CPUTIM=addr / (r)] [{,REALTIM={addr / (r)} / ,TOD={addr / (r)}}] [,CHWSTIM=YES / NO] ,REPEAT=YES / NO [,PARMOD=24 / 31] [,MF=L / (E,..)] |
CPUTIM=
Makes specifications regarding the CPU time interval (event code X'20').
addr
Symbolic address of the field that contains the CPU time interval specification. There are two possible field formats:
The “addr” field is one word long and contains the time interval as a binary number whose value is interpreted in terms of milliseconds.
The “addr” field is 6 bytes long and contains the time interval in the format hhmmss - hours, minutes seconds (EBCDIC).
Maximum value for hours: 24
Maximum value for minutes and seconds: 59
Once the specified time has elapsed, control is passed to the routine specified by the STXIT macro (TIMER operand).
(r)
Register containing the address value of the “addr” field.
MF=
For a general description of the MF operand, its operand values and any subsequent operands (e.g. for a prefix), see section “S-type macros”. The valid MF values are given at the start of the macro description under “Macro type” and are included in the macro format.
PARMOD=
Controls macro expansion. Either the 24-bit or the 31-bit interface is generated.
If PARMOD is not specified here, macro expansion is performed according to the specification for the GPARMOD macro or according to the default setting for the assembler (= 24-bit interface).
24
The 24-bit interface is generated. Data lists and instructions use 24-bit addresses (address space <= 16 Mb).
31
The 31-bit interface is generated. Data lists and instructions use 31-bit addresses (address space <= 2 Gb).
REALTIM=
Makes specifications regarding the real-time interval (event code X'A0').
addr
Symbolic address of the field that contains the real-time interval. There are two possible field formats:
The “addr” field is one word long and contains the real-time interval as a binary number whose value is interpreted in terms of milliseconds.
The “addr” field is 6 bytes long and contains the real-time interval in the format hhmmss - hours, minutes, seconds (EBCDIC).
Maximum value for hours: 24
Maximum value for minutes and seconds: 59
The value 0 is interpreted as 24 hours.
Once the specified time has elapsed, control is passed to the routine specified in the STXIT macro (RTIMER operand).
(r)
Register containing the address value of the “addr” field.
REPEAT=
Specifies whether or not the same interval is to be set again after it has elapsed.
YES
Default setting: the same interval is to be set again after it has elapsed. This operand is effective only in conjunction with the “CPUTIM”, “REALTIM” or “TOD” operand. With “TOD”, it will be repeated every 24 hours. With REALTIM all values < 50 msec are set to 50 msec. The summer/winter time change (or vice versa) is always implemented with REPEAT=YES.
NO
The interval will not be set again.
TOD=
Makes time-of-day specifications for a real timer, based on a 24-hour clock (event code
X'A0').
The specification is made in the format hhmmss - hours, minutes, seconds (EBCDIC). When the specified time of day is reached, control is passed to the routine specified in the STXIT macro (RTIMER operand).
addr
Symbolic address of a 6-byte field containing the time-of-day specification.
(r)
Register containing the address value of the “addr” field.
CHWSTIM=
Indicates the summer/winter (or vice versa) time change event (event code X'C0'). When the event occurs, control is transferred to the routine specified in the STXIT macro (RTIMER operand).
YES
The event is indicated, i.e. the STXIT routine - if defined - is started.
NO
The event is not indicated.
Return information and error flags
R15:
+---------------+ | | | | | | | | | | | |a|a| +---------------+
A return code relating to the execution of the SETIC macro is transferred in the rightmost byte of register R15.
X'aa' | Meaning |
X'00' | Normal execution |
X'04' | Function was not executed. Invalid operands |
X'08' | Function was not executed. Invalid time entry |