General
Application area: | Messages; see "Messages" |
Makrotyp: | Type S, MF format 1: 31-bit interface: standard/L/D/C/E form; |
The MSG7 macro will not be developed further; new functions will only be offered in the MSG7X macro which, unlike the MSG7 macro, also uses the new data area layout.
Macro description
The MSG7 macro outputs a system message to SYSOUT, SYSLST, the operator console or a user program area. The specified message code must contain 7 characters.
The operand values number2, A, B, C, N, R, T serve to structure a CSECT/DSECT and can be specified only in conjunction with the MF=C/D form of the macro.
Every system message has a 7-character message code. The first 3 characters of the code denote the message class; the remaining 4 characters are used for consecutive numbering within a class. System messages may contain variable sections “(&nnn)” that can be replaced by inserts.
Macro format and description of operands
MSG7 |
ID=msgid / (r1) / ((r1),(r2)) / (class,(r)) / R / C [,INSERT={(insertlength, {addr / base,[index],[displ]}) / ((insertlength, {addr / base,[index],[displ]}),...) / number1 / number2 / (number,B) / (number,T)}] [,LAN='language'] ,DEST=SYSOUT / SYSLST / CONSOLE / (destination,...) [,UCDEST='destcode' / (r) / destaddr / N / R / A] [,REPLY={(replylength,{addr / base,[index],[displ]}) / REG / N / A / B / R}] [,BUFFER={(bufferlength,{addr / base,[index],[displ]}) / N / A / B}] [,MAP={NO / YES}] ,DMS=APPL / NOTAPPL / NA [,RC=X / (r) / R / N] ,MF=S / C / (C,pre) / (E,...) / (D,pre) / D / L |
ID=
Specifies the message code of the system message to be output.
msgid
Specifies a 7-character message code.
(r1)
Register pair r1 and r1 + 1 containing the message code:
r1 = Register containing the message class (right-justified).
r1 + 1 = Register containing the message number.
r1 must be even-numbered.
((r1),(r2))
Register pair containing the message code:
r1 = Register containing the message class (right-justified).
r2 = Register containing the message number.
(class,(r))
class = 3-character message class
r = register containing the 4-character message number.
INSERT=
Specifies up to 15 lengths and addresses of inserts. An address reference is created in the message processing operand list for each entry.
If more inserts are specified than can be accommodated by the message, excess inserts are ignored. An insert consisting solely of blanks is shortened to a single blank.
Trailing blanks in an insert are suppressed.
The character X'01' can be entered at the end of an insert to prevent the suppression of blanks. When the character X'01' is encountered during message processing, all blanks that precede it are retained.
If a message text contains more inserts than are specified in the macro call, the default value is assumed for every excess insert. The substitute insert (&nn) is used if no default value is present.
(insertlength,...)insertlength
= length of the insertaddr
= symbolic address (name) of the areabase
= base register 1)index
= index register 1)displ
= displacement 1)
1)Entries for calculating the address of the insert
Inserts may be skipped by entering commas for omitted positions e.g. INSERT=(,(insertlength2,addr2),,(insertlength4,addr4)). Inserts omitted in this way are replaced by their default values or by the substitute insert (&nn).
If insertlength=0, the insert must begin with a record length field (4 bytes):
Bytes 0-1: length of the insert
Bytes 2-3: reserved.
Notes
The commas should always be entered in the case of indexed addressing.
An insertion list begins with two parentheses.
The sum of the insertion lengths <= 4079 bytes.
number1
Number of INSERTs for which space is to be reserved in the operand list for message processing.
“number1” may be specified only in conjunction with MF=L.
number2
Number of inserts for which names are to be generated in the CSECT/DSECT. “number2” may be specified only in conjunction with the C form or the D form of the macro.
(number,B)
Number of inserts whose addresses are to be specified in the form (base,index,displ). This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
(number,T)
Number of inserts for which symbolic addresses are to be specified.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
LAN=
Specifies the language to be used for message output.
This operand is ignored if DEST=CONSOLE is specified.
'language'
1 letter to identify the language:
D = German, E = English.
For additional options please consult system administration. The default value is defined by the system parameter MSGLPRI; this value is also assumed in the event of invalid specifications.
REPLY=
Defines a reply area. The area must be aligned on a halfword boundary and begin with a record length field (4 bytes: bytes 1-2: length of the reply; bytes 3-4 reserved). Before the macro is executed, bytes 1-2 must contain the length of the reply area (<= 4095 bytes). When the macro is executed, the current length of the reply is entered in bytes 1-2.
Lowercase letters are converted to uppercase when entered via the REPLY operand. REPLY may be specified only in conjunction with DEST=SYSOUT/CONSOLE.
If a “?” reserved in MIP as a keyword is entered as a reply, MIP MIP shows the meaning and action of the relevant message before the message is again output for reply.
Note
REPLY may be specified only in conjunction with DEST=SYSOUT/CONSOLE.
(replylength,...) replylength
= length of the reply area > 4 bytesaddr2
= symbolic address (name) of the areabase
= base register 1)index
= index register 1)displ
= displacement 1)
1)Entries for calculating the address of the area
Note
The commas should always be entered in the case of indexed addressing.
REG
Specifies that the reply is written left-justified in register R1. Reply length <= 4 bytes.
N
No reply area is generated in the CSECT/DSECT
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
A
The address of the reply area is a symbolic address.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
B
The address of the reply area is given in the form (base, index,displ).
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
R
The reply is to be transferred in register R1.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
DEST=
Designates destinations for the converted system message. If the REPLY operand is also specified, only DEST=SYSOUT/CONSOLE is permissible.
SYSOUT
Output to SYSOUT.
SYSLST
Output to SYSLST.
CONSOLE
Output to the operator console.
(...)
Combination of the above-mentioned destinations; entry in parentheses.
BUFFER=
Specifies an area to which the converted system message is to be transferred. BUFFER must be aligned on a halfword boundary.
A record length field is entered in the first 2 bytes:
- Bytes 0-1: length of the area | Bytes 2-3: reserved | WROUT format Bytes 4: output control character | Bytes 5-n: message text | -
(bufferlength,...) bufferlength
= length of the area > 16 bytesaddr
= symbolic address (name) of the areabase
= base register 1)index
= index register 1)displ
= displacement 1)
1)Entries for calculating the address of the area
N
No area for the converted system message is generated in the CSECT/DSECT.This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
A
The address of the area is a symbolic address.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
B
The address of the area is given in the form (base, index,displ).
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
MAP=
Specifies whether BUFFER is given another structure (mapping format).
NO
BUFFER is created in the WROUT format.
YES
BUFFER is created in the mapping format (see below).
UCDEST=
UCON destination (UCON=Universal CONsole); (see “Introduction to System Administration” [10 (Related publications)] manual).
The destination of a message can be specified as follows:
mnemonic device name for a particular console.
routing code for consoles and authorized user tasks which are allocated a particular area of activity.
authorization name for an authorized user task.
Notes
UCDEST is not executed unless DEST=CONSOLE was specified.
UCDEST has priority over the RC operand.
'destcod'
The following entries are permissible for 'destcode':'(mn)'
where mn = 2-character mnemonic device name.'< x'
where x = routing code;<
must be specified.'name'
where name = name of the user task (4 characters).
destaddr
Symbolic name of an area (word length) with the entry for “destcode”; left-justified entries; alignment on a word boundary.(r)
r = Register containing the entries for “destcode”; left-justified entry.N
No field for “destcode” is to be generated in the CSECT/DSECT.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.R
The entry for 'destcode' is entered in a register.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.A
The address of the field containing “destcode” is a symbolic address (destaddr).This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
DMS=
Specifies the message search mechanism.
APPL
The message is sought with the aid of DMS (message files and DLAM area).
NOTAPPL / NA
The message is sought at system level only in the DLAM area without DMS). Reply if the requested message is not found:
msgid,DMS NOT IN MEMORY,program counter,modul,inserts.
RC=
Specifies the routing code for sending a message to the console. The routing code entered in the message unit is ignored if the RC operand is specified.
x
Routing code (1st character). See also the “Introduction to System Administration” manual [10 (Related publications)].
(r)
Register containing the specification for “x”; right-justified entry.
R
The routing code is entered in a register.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
N
No field for the routing code is generated in the CSECT/DSECT.
This specification is required for the structuring of the CSECT/DSECT; it may be specified only in conjunction with the C form or the D form of the macro.
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.
A prefix (pre = 1..4 letters) can be specified in the C form and D form, as shown in the macro format.
Default values:
pre = MSGC for the C form
pre = MSGD for the D form
If less than 4 letters are entered for the prefix, the string MSGx (where x corresponds to 1st letter) results.
The operand list also contains a definition of the output area, reply area and fields for a maximum of 15 inserts.
Mapping format
The mapping format specifies the structure of the BUFFER area in the case of MAP=YES. Various entries (mapping list) are prefixed to the structure defined under BUFFER.
Structure of the mapping format:
Bytes 0-1: length of the mapping list
Bytes 2-3: C'MP'
Bytes 4-n: entries
Bytes n+1 bis p: remainder of structure as under BUFFER (WROUT format).
The entries contain information on
the inserts
the message code
the routing code
the message weight
slack bytes for alignment.
Entries are stored as follows:
Entry on | Structure of the entry | |||||||||||||||
Insert Message Message Routing Slack | (A separate entry ... is created for each insert) | |||||||||||||||
Insert | Displacement when | |||||||||||||||
0H | ||||||||||||||||
X' 81' | 7-character message code | |||||||||||||||
0 | 8 | |||||||||||||||
X' 20' | Message | |||||||||||||||
0 | ||||||||||||||||
X' 50' | Routing code | |||||||||||||||
0 | ||||||||||||||||
X' 00' | - - - | X' 00' | WROUT format | |||||||||||||
0 |
Return information and error flags
The operand list also contains a definition of the output area, reply area and fields for a maximum of 15 inserts.
R15:
+---------------+ | | | | | | | | | | | |a|a| +---------------+
A return code relating to the execution of the MSG7 macro is transferred in the rightmost byte of register R15.
X'aa' | Meaning |
X'00' | MSG7 macro completed without errors |
X'04' | Abnormal termination of input/output |
X'08' | Invalid message number, area address, mnemonic device name, name of the authorized |
X'0C' | Noninteractive user requests reply |
X'10' | No memory space available |
X'14' | Break during WROUT macro |
X'18' | Truncated message written to output area |
X'20' | Message output aborted |
X'2C' | DEST=SYSLST was specified with REPLY=... |
X'30' | DEST=(...) was specified with REPLY=... |
X'41' | The MIP subsystem is not loaded |