;;      DOCUMENT NAME ......... SYSTEM.DAT
;;      DOCUMENT NUMBER ....... 10/19055-35/CAA1103801/1
;;      REVISION STATE ........ V3
;;      REVISION DATE ......... 2004-09-02
;;      DESIGNER .............. SEARAJ
;--------------------------------------------------------------------------
	IF  \   DEF(SYASMFLG)  
;                NOLIST
	ENDIF
;--------------------------------------------------------------------------
;    	COPYRIGHT	Copyright ERICSSON INFORMATION SYSTEMS 1985
;	---------
;
;    		The copyright to the program herein is the property of
;		ERICSSON BUSINESS COMMUNICATIONS AB, Sweden.
;    		The programs may be used and/or copied only with the
;		written permission from ERICSSON BUSINESS COMMUNICATIONS AB
;		or in accordance with the terms and conditions stipulated
;		in agreement/contract under which the program has been
;    		supplied.
;--------------------------------------------------------------------------
;    
;;    *-----------------------------------------------------------------*
;     ! Note! Lines marked with duble semicolon can easy be extracted   !
;     !       from this file when a                                     !
;     !                                                                 !
;;    ! SURVEY of INFORMATION-CODES, ATTENTION-CODES and JOB-SIGNALS    !
;     !                                                                 !
;     !        has to be created.                                       !
;;    !                                                                 !
;;    ! Extract from SYSTEM-*-*-*.DAT     (version, see above )         !
;;    *-----------------------------------------------------------------*
;
;     *-----------------------------------------------------------------*
;     ! To extract data to other system-files there are a number of	!
;     ! markings in this datafile to be used by a support program	!
;     ! that reads this file and extracts datavalues to another file.   !
;     !									!
;     ! Examle of external use are datafiles to include for RP 'RPSYS*,	!
;     ! for O&M 'RASC' or for test-tool 'WILMER'   			!
;     !									!
;     !	; General mark rules:						!
;     !	;--------------------						!
;     !									!
;     !	;RBEG,QUALIFIER[,DEFINITIONMACRO]				!
;     !									!
;     !	NAME1		EQU		123	;     for RASC use	!
;     !		DEFINITIONMACRO	NAME2,	124	;     for RASC use	!
;     !	NAME3		EQU		125	;RP   for RASC and RP	!
;     !		DEFINITIONMACRO	NAME4,	126	;RP   for RASC and RP	!
;     !									!
;     !	;REND (qualifier)						!
;     !	       								!
;     ! Note! Lines marked ;RP within this ;RBEG ... ;REND contains	!
;     !       data definitions that shall be extracted to datafiles	!
;     !       for RP-use. (RPSYS-*-*.*)					!
;     !       Lines marked with ;R within an ;RBEG -- ;REND must be     !
;     !       extracted for external data file but will not be read     !
;     !       by the TEK-assembler                                      !
;     !        							 	!
;     ! ;RCODE, name	; The name defines the information code that    !
;     ! 		; the following sub codes belongs to.           !
;     *-----------------------------------------------------------------*
;     !	; Used qualifiers within this file:				!
;     !	;----------------------------------				!
;     !									!
;     !	CARDTYPES							!
;     !	INDTYPES							!
;     !	JOBSIGNALS							!
;     !	ATTCODES							!
;     !	INFCODES							!
;     !	SUBCODES							!
;     !	CHARACTERS							!
;     !	OTHERS								!
;     !									!
;     *-----------------------------------------------------------------*
;
;    	REVISION INFORMATION 
;
;
;	PA1	2003-09-25	SEARAJ
;
;		based on SYSTEM-34-1-B.DAT
;
;		11.1/2	new information codes :
;				LCDTOG1 ,
;				LCDTOG2 .
;
;		12.73	CTIFUNC-message, new subcodes :
;				REQNAMESUPPORT ,
;				RSPNAMESUPPORT ,
;				REQNAME ,
;				RSPNAME .
;
;		12.64	SISIG,SIFACILITY-message, new headers :
;				FAS0HOLDREQ ,
;				FAS0RETREQ ,
;				FAS0ECTREQ ,
;				FAS0SUSPREQ ,
;				FAS0RESUREQ ,
;				FAS0HOLDACK ,
;				FAS0RETACK ,
;				FAS0SUSPACK ,
;				FAS0RESUACK ,
;				FAS0HOLDIND ,
;				FAS0RETIND ,
;				FAS0ECTIND .
;
;	PA2	2003-10-10	SEARAJ
;
;		12.64	SISIG,SIFACILITY-message,
;			new header definitions :
;				FAS0ECTEXE ,
;				FAS0ECTACK ;
;			changed header definitions :
;				FAS0SUSPREQ ,
;				FAS0RESUREQ ,
;				FAS0SUSPACK ,
;				FAS0RESUACK .
;
;		12.3.1	SEIZ-messages and others, INDIVIDUAL data field,
;			new bit-position symbols:
;				CLISTABIT .
;
;	PA3	2003-11-07	SEAFRAI
;
;		4.3	new Directory numbers
;			(Default directory numbers used for e2base and for dialling) :
;				DIR.DIKEY ,
;				DIR.DEKEY .
;
;	PA4	2003-11-21	SEAFRAI
;
;		12.3.2	Instrument- and Terminal-types, new INSTRUMENTS :
;				TERM.D422 ,
;				TERM.D425 .
;
;		12.64	SISIG -message, new data in SISIG,SIFACILITY :
;				FASUSPEND ,
;				FARESUME .
;
;		12.90	IPSIG-message, new subcodes :
;				IPMWI ,
;				IPIDLE .
;
;	PA5	2003-12-12	SEARAJ
;
;		12.37	CONINFO-message, new subcode :
;				CONI.SUSPEND .
;
;	PA6	2004-02-12	SEAMALI
;
;		Adaptions for new 6809 compiler.
;
;	PA7	2004-02-25	SEARAJ
;
;		Fileheader :
;		NOLIST directive commented because generation of LIS files
;		not posible otherwise in SSCompile since adaptions for new
;		6809 compiler.
;		(LIST directive at end of file does not work, probably Tektroniks
;		assembler shortcoming, therefore list mode is not activated
;		anymore. work only if LIST directive is somewhere in the
;		middle of file. perhaps dependent on file size).
;
;		13.10	new card type :
;				CTYPE.IAS .
;
;		12.3.2	all terminal types for instruments and trunks
;			extracted for RPSYS .
;
;		12.90	IPSIG-message, new subcode :
;				IPPICKUP .
;
;		12.3	SEIZ-messages, new bit position symbol for
;			CTRLDATA2+1 / bit 4 :
;				CPNNA .
;
;	PA8	2004-03-05	SEARAJ
;
;		12.90	IPSIG-message :
;			subcode removed :
;				IPPICKUP ;
;			new subcode :
;				IPFUNCSETUP (same value asl IPPICKUP before).
;
;		12.3.1	SEIZ-messages and others, INDIVIDUAL data field :
;			bitposition symbols for CI removed :
;				CLISTBIT ,
;				CLISTABIT ;
;			new nibble position symbol instead :
;				CLISTNIB .
;
;	based on  REL_02R15_PA15
;
;	V1	2004-04-23	SEARAJ
;
;		12.3.3	Forward and return data field,
;			new definition added :
;				SZCF.VIRVOIPGW .
;		
;		4.2	Individual type and flags for e2base and RP (CARDREP-message),
;			new type definition :
;				TYPE.IAS .
;
;	V2	2004-07-13	SEARAJ
;
;		11.2   RPSYS flag added for some information codes :
;			OMPCCOM ,
;			OMPCCOMANSW .
;
;		8.3   RPSYS flag added for some jobsignals :
;			ST.CTINP ,
;			ST.OMEPC .
;
;		12.96   LICFUNC-message, subcodes added and defined for RPSYS :
;			LICAPPREQ ,
;			LICAPPRESP ,
;			LICCHKEXT ,
;			LICCHKEXTACK ,
;			LICCTIREP .
;
;	V3	2004-09-06	SEAMALI
;
;		13.3	Internal character set
;
;			Add cyrillic character defintions
;
;		12.26	ELPAR-message, new subcode:
;			ELPLCDCHG .
;
;--------------------------------------------------------------------------
	PAGE
;	TABLE OF CONTENTS
;	-----------------

;	 1.	GENERAL DESCRIPTION
;	 1.1	 Included document
;	 1.2	 Definitions
;	 1.2.1	  Sections
;	 1.2.2	  Global references
;	 1.2.3	  Global definitions
;	 1.2.4	  Definition macro 'SYDEF'
;
;	 2.	OS-DIMENSIONS
;	 2.1	 Jobqueues
;	 2.2	 Timers
;	 
;	 3.	OS-BUFFER and MESSAGE-layout
;	 3.1	 Basic buffer
;	 3.2	 Message buffer
;	 3.3	 Process buffer
;
;	 4.	E2BASE and E2RECORDS
;	 4.1	 Size
;	 4.2	 Individual type and flags for e2base and RP (CARDREP-message)
;	 4.3	 Directory numbers
;
;	 5.	PCM-CHANNELS
;
;	 6.	MEMORY 
;	 6.1	 Memory check codes
;	 6.2	 Mapped data ram, common.
;	 6.3	 Extended mapped ram / E2-prom.
;	 6.3.1	  Ram part.
;	 6.3.2	  OS.BATT Part of mapped Battery Backed-Up RAM
;	 6.3.3	  E2 Part of mapped Battery Backed-Up RAM
;	 6.4	 Program memory.
;	 6.5	 JOBBASE, reservations (global)
;	 6.6	 PORTS (hardware and dummies)
;	 6.6.1	  Map ports.
;	 6.6.2	  Breakpoint port, real hardware
;	 6.6.3	  Input and Output port.
;	 6.6.4	  Backplane control (function control port)
;	 6.6.5	  Switch circuit, handled by OU (SX).
;	 6.6.6	  Breakpoint ports (dummies, no circuits in hardware)
;	 6.6.7	  Bitmasks for OS.CALL QSWITCH (from ports in SP and CP).
;
;	 7.	PROGRAM MAP HEADER
;	 7.1	 Map header offsets
;	 7.2	 Product administrative data
;	 7.3	 Header and table reservation
;	 7.4	 Endmark for tables and MDATA

;	 8.	JOBSIGNALS
;	 8.1	 Limits.
;	 8.2	 Survey of jobsignals.
;	 8.3	 Jobsignal definitions (global)
;
;	 9.	INDIVIDUAL ADDRESS (Hardware position / card & individual)
;	 9.1	 Limits.
;	 9.2	 Individual Addresses
;
;	10.	CARD GLOBAL MESSAGES
;	10.1	 Survey of attention codes.
;	10.2	 Attention code definitions (global)
;
;	11.	INFORMATION CODES
;	11.1	 Survey of information codes.
;	11.2	 Information code definitions (global)
;
;	12.	MESSAGE-DATA
;	12.1	 RPCTRL-message, mode/subcode
;	12.2	 SURDY-message, subcodes.
;	12.3	 SEIZ-messages.
;	12.3.1	  Individual data field (seiz-messages and others)
;	12.3.2	  Instrument- and terminal-types 
;	12.3.3	  Forward an return data field
;	12.4	 CONCTRL-message, subcodes (states).
;	12.5	 KEYCODE-message, keycodes, keytypes.
;	12.6	 LCDCTRL-message, subcodes
;	12.7	 Tones, used in TONE-  MPCON- and ELCTRL-messages.
;	12.8	 LEDRING- LEDCTRL- and MULTPRES -message ledcadences.
;	12.9	 ACD-messages, subcodes.
;	12.10	 REROUTE-message, subcodes (cause).
;	12.11	 EU- and IO-messages, subcodes.
;	12.11.1	  EUSEIZ subcodes (IO-mode).   
;	12.11.2	  EUCTRL, subcodes.
;	12.11.3	  IOINIT, subcodes.
;	12.11.4	  IOCTRL, subcodes.
;	12.11.5	  IODATA, subcodes.
;	12.12	 QUEUEINFO-message, subcodes.
;	12.13	 OPINFO-message, subcodes.
;	12.14	 CONRELCTRL-message, subcodes and other data.
;	12.15	 TEXTSTRING-message
;	12.15.1	  Subcodes
;	12.15.2	  Other symbols
;	12.16	 MICTRL-message.
;	12.16.1	  MICTRL-message, subcodes.
;	12.16.2	  MICTRL-message, controldata.
;	12.17	 REALTIME-message, subcodes.
;	12.18	 VMU- and VM-messages, subcodes.
;	12.18.1	  VMUSEIZ-, VMSEIZ-and VMUSEIZHD-message. 
;	12.18.2	  VMUSEIZANSW- and VMSEIZANSW- and VMUORDERANSW-message.
;	12.18.3	  VMUDATAANSW-message.
;	12.18.4	  VMUORDER-message.
;	12.18.5	  VMCTRL-message.
;	12.19	 METER- message, subcodes.
;	12.20	 CIL- messages, subcodes and data.
;	12.20.1	  CILCONDAT, subcodes
;	12.20.2	  CILCONSTAT, subcodes
;	12.20.3	  CILDIGSEND, subcodes and data
;	12.20.4	  CILCONREL
;	12.20.5   CILSERVICE, subcodes
;	12.21	 DIGREQ- messages, subcodes.
;	12.22	 PCCTRL- messages, subcodes. 
;	12.23	 MISTOCLR- messages, subcodes.
;	12.24	 GUESTINFO- message, subcodes.
;	12.25	 CPJOB-message, subcodes.
;	12.26	 ELPAR-message,
;	12.27	 E2STATUS message, subcodes.
;	12.28	 PGINFO message, subcodes.
;	12.29	 TRTRANSIT message, subcodes.
;	12.30	 HOCIL-messages, subcodes.
;	12.31	 UPDCARD-message, subcodes.
;	12.32	 ACBCTRL-message, subcodes.
;	12.33	 NEWNO-message, subcodes.
;	12.34	 E2RECORD, E2ACK and E2NAK-message, subcodes.
;	12.35	 ECCOM-message, subcodes.
;	12.36	 NUMINFO-message, subcodes
;	12.37	 CONINFO-message, subcodes
;	12.38	 ELCTRL-message, subcodes.
;	12.39	 CARDREP-message, subcodes.
;	12.40	 BTCORDER-message, subcodes.
;	12.41	 BTCPAR-message, subcodes.
;	12.42	 BTCSIGNAL-message, subcodes.
;	12.43	 BTLSUP-message, subcodes and data.
;	12.44	 IMPCTRL-message, subcodes.
;	12.45	 MPCONANSW-message, subcodes.
;	12.46	 REGCTRL-message, subcodes and data.
;	12.47	 TONEPAR-message, subcodes and data (tones see 12.7)
;	12.48	 TONECTRL-message, subcodes
;	12.49	 STATEREP-message, subcodes
;	12.50	 TRANSM-message, subcodes
;	12.51	 SYSPAR-message, subcodes
;	12.52	 VOICEPAGCTRL-message, subcodes
;	12.53	 MEMEX-message, subcodes
;	12.54	 RPJOB, RPJOBANSW -messages, subcodes and data
;	12.55	 ADFUNCTION -message, subcodes and data
;	12.56	 CPICKUPCTRL -message, subcodes
;	12.57	 ELSTATE -message, subcodes
;	12.58	 TESTTRACE -message, subcodes (TYPE)
;	12.59	 TEXTEDIT -message, subcodes 
;	12.60	 ELDTRANSIT -message, subcodes 
;	12.61	 COST -message, subcodes and other data
;	12.62	 SAVENO -message, subcodes 
;	12.63	 SERVICE -message, subcodes and data
;	12.64	 SISIG -message, subcodes and data
;	12.65	 CONPTYNUM -message, subcodes and data
;	12.66	 CATREAD -message, subcodes 
;	12.67	 LCRNUM -message, subcodes and data
;	12.68	 NUMCONVERT -message, subcodes and data
;	12.69	 AUTHCODE -message, subcodes
;	12.70	 INDDATAANSW -message, data
;	12.71	 GUEST -message, subcodes
;	12.72	 DIRCTRL -message, subcodes
;	12.73	 CTIFUNC -message, subcodes
;	12.74	 PESGLOBAL -message, subcodes
;	12.75	 TISIG -message, subcodes
;	12.76	 TFRQ-message, data
;	12.77	 DISPLAYCTRL-message, subcodes
;	12.78	 TRSTATUS-message, subcodes
;	12.79    BLOCKINFO-message, subcodes
;	12.80    CICTRL-message, subcodes
;	12.81    MUCTRL-message, subcodes
;	12.82	 UPDIND-message, subcodes
;	12.83	 PNRINFO-message, subcodes
;	12.84	 OMPCCOM-message, ,subcodes
;	12.85	 ALARMCTRL-message, subcodes
;	12.86	 GROUPCTRL-message, subcodes
;	12.87	 IPDATA-message, subcodes
;	12.88	 UPGRAD-message, subcodes
;	12.89	 ACCTRL-message, subcodes
;	12.90	 IPSIG-message, subcodes
;	12.91	 TRANSP-message, subcodes
;	12.92	 ARCTRL-message, subcodes
;	12.93	 BREAKINCTRL-message, subcodes
;	12.94	 CONFCTRL-message, subcodes
;	12.95	 TFRCTRL-message, subcodes
;	12.96	 LICFUNC-message, subcodes
;
;	13.	MOREOVER
;	13.1	 Data for OS.BUFFER OS.TIMER and OU.CHANNEL CHECK calls
;	13.2	 Suffix-functions (answer codes from OU.CALL PA.SUFFIX)
;	13.3	 Internal character set
;	13.4	 Floating point declarations
;	13.5	 Equations for predigits
;	13.6	 Definitions for utility call OU.CALL PA.PUBLICNO
;	13.7	 Systemtype definitions for utility call OU.CALL PA.SYSTEMTYPE
;	13.8	 Definitions for OS.BATT calls / Battery RAM Handler
;	13.8.1	  Internal Definitions
;	13.8.2	  General Definitions
;	13.8.3	  Error Numbers
;	13.8.4	  Pool IDs
;	13.9	 Common definitions for messages
;	13.10	 Card types
;	13.11	 Purposes of Restart
;	13.12	 Reason for Online-Coredump
;	13.13	 OS Base Array Layout
;	13.14	 OS Debug Functions
;	13.15	 Warning data for W.OSMERRD
  PAGE
        STITLE     '1. General description'
; 1.	GENERAL DESCRIPTION
;	===================

;	This file contains common symbols for the ASB 150 Central program,
;	messages and all common system dimension symbols.
;
;	There are also some system common memory reservations and data
;	descriptions.
;
;	The code for the program map headers and the header tables are done here
;	as well as the endmarks of the header tables and the RAM area MDATA.
;
;	The Jobsignals, information codes and attention codes are declared
;	as global to be compatible with code written for earlier releases.
;
;-----------------------------------------------------------------------------
;	This program version must be able to run on different CPU-D / CPU-E
;	versions:
;
;		Old:    CPU-D	ROF 157 5118/1	
;		New:    CPU-D2	ROF 157 5118/2  
;		Future: CPU-E	ROF 157 5124	
;						
;	The differeces concerns the map-ports in chapter 6.6.1 and the E1/E2
;	memory layout in chapter 6.3 
;	See also the technical description 1551-ROF 157 5118 for the board.
;
;	The current version of the board can be red in the backplane contol
;	port, see chapter 6.6.4
;
;	NOTE! 	The complete handling of the CPU-E with 32 additional battery
;		backed RAM-maps will be added in a later release of this file.
;
;	handling of CPU-E with additional E2 maps added in R5
;
;----------------------------------------------------------------------------
  PAGE
	STITLE     '1.1  Included documents'
; 1.1	INCLUDED DOCUMENTS
;	------------------
;	When assembled, included in SYSTEMDAT.SA9, the OSCALL_MAC and
;	the OUCALL_MAC have to be included too.


; 1.2	DEFINITIONS
;	-----------
;
; 1.2.1	SECTIONS
;	--------
        IF      DEF(SYASMFLG)

;	SECTION SYSTEMJ,  CLASS=JOBBASE   ; base area for application
        SECTION SYSTEMH,  CLASS=HEAD      ; header
        SECTION SYSTEMHH, CLASS=HEADEM    ; endmark
	SECTION	SYSTEMN,  CLASS=INITTAB   ; start of init table
	SECTION	SYSTEMNN, CLASS=INITTABEM ; endmark
	SECTION SYSTEMO,  CLASS=JOBTAB    ; start of job table
	SECTION SYSTEMOO, CLASS=JOBTABEM  ; endmark
	SECTION SYSTEMR,  CLASS=REPTAB    ; start of report table
	SECTION SYSTEMRR, CLASS=REPTABEM  ; endmark
	SECTION SYSTEMY,  CLASS=SURTAB    ; start of suready table
	SECTION SYSTEMYY, CLASS=SURTABEM  ; endmark

        SECTION SYSTEMXX, CLASS=MDATAEM   ; endmark of MDATA

        ENDIF   ; (SYASMFLG)

  PAGE
; 1.2.2	GLOBAL REFERENCES
;	-----------------

        GLOBAL  M.DATA                    ; First address in DATA-map
	GLOBAL	E.DATA                    ; First address in Ext-map
	GLOBAL	M.PROG                    ; First address mapped prog.
	GLOBAL	C.PROG                    ; First address central prog.
        
        IF      DEF(SYASMFLG)
	                                  ; Program map header data,
                                          ; from linker commandfile.
        GLOBAL  CHECKSUM,   CHECKSUMC     ; 
        GLOBAL  MAPNUMPROG, MAPNUMDATA    ;
        
	IF \DEF(PRE_MACASM)
        GLOBAL  SSDCP                     ;
        GLOBAL  SSPRE,      SSABC         ;
        GLOBAL  SSBAS,      SSNUM         ;
        GLOBAL  SSSUF,      SSREV         ;
	ENDIF	; \DEF(PRE_MACASM)

        ENDIF   ; (SYASMFLG)

  PAGE
; 1.2.3	GLOBAL DEFINITIONS
;	------------------
;       EQU-globals are also done by the definition macro 'SYDEF'

	GLOBAL  WREG				; Work register
	GLOBAL  MEREG				; Message register

  PAGE 
; 1.2.4	DEFINITION MACRO
;	----------------
;       SYDEF   the macro will define a value for a symbol and also declare
;               the symbol as global. Ony used an assembling of this file
;
;       FORMAT:    SYDEF  symbolname,value
;--------------------------------------------------------------------------

        MACRO      SYDEF
        IF         "#"<>2
        WARNING    SYDEF:: wrong number of parameters
        ENDIF
        IF      DEF(SYASMFLG)
        GLOBAL     "1"
	ENDIF   ; (SYASMFLG)
"1"     EQU        "2"
        ENDM
	
	MACRO      SYDEF1
        IF         "#"<>2
        WARNING    SYDEF1:: wrong number of parameters
        ENDIF
"1"     EQU        "2"
        ENDM

        
  PAGE
        STITLE     '2. OS-DIMENSIONS'
;----------------------------------------------------------------------------
; 2.    OS-DIMENSIONS
;----------------------------------------------------------------------------
;
;----------------------------------------------------------------------------
; 2.1   JOB QUEUES
;----------------------------------------------------------------------------
; Minimum (with max messagelength) quantity of job queue positions:
;
OSJQBQNT     EQU   16         ; Job queue B  (valid values 1-255) *)
OSJQCQNT     EQU   47	      ; Job queue C  (valid values 1-255) *)
OSJQDQNT     EQU   63         ; Job queue D  (valid values 1-255) *)
                              ;
                              ;  The max values are dependent of the total
                              ;  reserved memory for jobqueues (E1OSSNDSIZE)
                              ;
OSSENDLIM     EQU  20         ; Higest number of OS.SEND at one job-enter.
                              ;  Sending of more messages will cause 
                              ;  an OS.WARNING W.SENDRATE

  PAGE
;
;----------------------------------------------------------------------------
; 2.2   TIMERS
;----------------------------------------------------------------------------
OSTIME.MS    EQU  125         ; The time in ms, of one primary intervall.
                              ; (the time between two timout interrupt from
                              ;  the 'hardware' timer within the SP)


                              ; Timer normal: Request/Trig/Release.
                              ; -------------------------------------
OSTIMERQNT   EQU  255         ; Normal, quantity.   255= max allowed value
OSTIMERSZ    EQU    6         ;  Max (fixed) messagelength for a normal timer
OSTIMERSZD   EQU    7

                              ; Timer extra: Periodic/Delaysend.
                              ; -------------------------------------
OSTIMXQNT    EQU   32         ; Extra, quantity.    64= max allowed value
OSTIMXSZ     EQU  MESSAGESZL
OSTIMXSZMIN  EQU  MESSAGESZMIN ;  Min messagelength for the extratimer

  PAGE
        STITLE     '3. OS-BUFFER and messagelayout'
;
;----------------------------------------------------------------------------
; 3.    OS-BUFFER and MESSAGELAYOUT
;----------------------------------------------------------------------------
OSBUFFQNT     EQU  248	      ; Max number of OS-buffers to allocate within
                              ; one data map. The actual number within each
                              ; data map are limited by the number of ram-
                              ; bytes (MDATA) allocated within the data map.
                              ; See MAPPED DATA MEMORY  6.2 below.
                              ;
                              ;   1= minimum allowed value, 
                              ; 247= maximum allowed value, see OSBUF*.SA9

;______________________
;Note:  Value OS64BQNT is defined later (6.2) because needed constants are
;	declared there!
OS64BQNT    EQU 368
;______________________


;----------------------------------------------------------------------------
; 3.1   BASIC BUFFER
;----------------------------------------------------------------------------
;       Sizes and offsets for data in an OS buffer.

OSBUFFSZ     EQU  64          ; Buffer size - small buffer

OSBUFFSZL    EQU  128	      ; Buffer size - large buffer
;
;                 Offsets     ; Description
;                 ------------;-----------------------------
BUFFNUM      EQU  0           ; Buffert number READ ONLY, (handled by OS)
BUFFLOG      EQU  1           ; Logged use of the buffer, (handled by OS)
BUFFJID      EQU  2           ; Job identity (user),      (handled by OS)
BUFFDAT      EQU  3           ; First user offset in a buffer

BUFFEND      EQU  OSBUFFSZ-1  ; last address in a small buffer
BUFFENDL     EQU  OSBUFFSZL-1 ; last address in a large buffer

  PAGE
;----------------------------------------------------------------------------
; 3.2   MESSAGE BUFFER LAYOUT
;----------------------------------------------------------------------------
                                ; MAX and MIN MESSAGE-LENGTHs (ML-byte included)
				;--------------------------------------------
MESSAGESZMIN	EQU  3		; Min for internal messages (ML,ST,SN)
MESSAGESZ	EQU  OSBUFFSZ-BUFFDAT
				; Max for internal (small) messages (within CP)
MESSAGESZL	EQU  OSBUFFSZL-BUFFDAT
				; Max for internal (large) message (within CP)
				;
MESSAGESZMINRP	EQU  5		; Min for external messages (ML,ST,SN,CA,IND)
MESSAGESZRP	EQU  20		; Max for external messages (within CP to RP)
				;(Default for RP using communication format 1)
MESSAGESZMAXRP	EQU  61		; Max for external messages (within CP to RP)
				;(Actual max reported by RP using format 2)

;                    Offsets    ; Description
;                 --------------;-----------------------------
; BUFFNUM       EQU  0          ; Buffert number READ ONLY, (handled by OS)
;               EQU  1          ; Reserved for system use
;               EQU  2          ;  -''-    -''-   -''-
ML              EQU  BUFFDAT    ; Place for message-length
ST              EQU  BUFFDAT+1  ; Signal-type.
SN              EQU  BUFFDAT+2  ; Signal-number.
CARD            EQU  BUFFDAT+3  ; Card-position.
IND             EQU  BUFFDAT+4  ; Individ-number.
CODE            EQU  BUFFDAT+5  ; Information-code.
DATA            EQU  BUFFDAT+6  ; Data. First byte of 55. (DATA+0 ..DATA+54)
SUBCODE		EQU  DATA	; Alias for first databyte

  PAGE
;----------------------------------------------------------------------------
; 3.3   PROCESS BUFFER LAYOUT
;----------------------------------------------------------------------------
;                    Offsets    ; Description
;                    -----------;-----------------------------
; BUFFNUM       EQU  0          ; Buffert number READ ONLY, (handled by OS)
;               EQU  1          ; Reserved for system use
;               EQU  2          ;  -''-    -''-   -''-
PBSTATE         EQU  BUFFDAT    ; Place for process state
PBTIMER         EQU  BUFFDAT+1  ; Process timer number, 0= No timer
PBDATA          EQU  BUFFDAT+2  ; Process data. First byte of 59.
  PAGE
        STITLE     '4. E2BASE and E2RECORDS'
;
;----------------------------------------------------------------------------
; 4.    E2BASE and E2RECORDS
;----------------------------------------------------------------------------

;----------------------------------------------------------------------------
; 4.1   SIZE
;----------------------------------------------------------------------------
E2BASEQNT    EQU  1500        ; Max number of e2base records in the system.
                              ;  Aslo number of positions in the directory-
                              ;  number table.
                              ; 512= Maximum allowed.
                              ;
                               
E2BASUSERSZ  EQU   51         ; User avaliable size of an e2base, includes
                              ;      *  flags/type        (1 byte)
                              ;      *  directory number  (2 bytes)
                              ;
                              ;  51= Maximum size without changing of 
                              ;      the osbuffer size,
                              ;      (space for data in E2BASE-messages)


E2RECUSERSZ  EQU   50         ; User avaliable size of an e2record.
                              ;
                              ; 50= Maximum size without changing of 
                              ;     the osbuffer size,
                              ;     (space for data in E2REC-messages)
  PAGE
;
;----------------------------------------------------------------------------
; 4.2	Individual type and flags for e2base and RP (CARDREP-message)
;----------------------------------------------------------------------------
;       Symbols for individual type and flag-bits used in e2base records,
;       REPORT-tables with default values for e2base and in OU.CALL E2.--
;	routines.
;
;       The individual type is also used in CARDREP,CREPORTANSW-message
;       and for reading of cardtable, OU.CALL SU.----- routines.
;


;       BIT POSITION NUMBERS in flag-nibble (bit 4-7):

NUMINTBIT	EQU	6	; Directory number interval indicator.
BLOCKBIT	EQU	5	; Blocking of directorynumber.
DATACOMBIT	EQU	4	; Data communication allowed. 



;       BIT MASKS:

TYPEMASK        EQU    00001111b ; Mask for all type common bits
TYPEMASKEX      EQU    00001100b ; Mask for extension type common bits
TYPEMASKTR      EQU    00001100b ; Mask for trunk type common bits
TYPEMASKEXTR    EQU    00000100b ; Mask for extensions and trunks common bits
  PAGE  
;     INDIVIDUAL TYPE VALUES:
;RBEG,INDTYPES
				;   EX-lines:
TYPE.ELUD	EQU	00h	;RP Digital extension lines, DASL.
TYPE.ELUA	EQU	01h	;RP Analogue extension lines.
TYPE.ELUC	EQU	02h	;RP Digital extension lines, DIC-DEC.
TYPE.ICCU	EQU	03h	;RP Cordless extension lines


TYPE.IOU	EQU	04h	;RP I/O-unit, V.24  (same as old TYPE.CMU)
TYPE.SMU	EQU	05h	;RP System modem, built in V.22
TYPE.RSU	EQU	06h	;RP Register signal units.
TYPE.VMU	EQU	07h	;RP Voice Memory Unit.
			

				;   TRunk-lines:
TYPE.BTUDC	EQU	08h	;RP Digital trunk lines, 30 channel CAS.
TYPE.BTUA	EQU	09h	;RP Analouge trunk lines.
TYPE.BTUDP	EQU	0Ah	;RP Digital trunk lines, primary access ISDN.
TYPE.BTUB	EQU	0Bh	;RP Digital trunk lines, basic access ISDN.

TYPE.IAS	EQU	0Ch	;RP I/O-unit, V-24 (located at IAS)
;			D	;   spare
TYPE.IPU	EQU	0Eh	;RP IPU card global parameter handling
TYPE.TSU	EQU	0Fh	;RP Tone sender unit (never in E2base)

;----------------------------------------------------------------------------
TYPE.NONE	EQU	0FFh	;   TYPE.NONE actually does not belong to the
				;   individual type values.
				;   it must not be used in connection with
				;   TYPEMASK !
				;   it is just used for SU.CARDDAT to prevent
				;   old functionality
;----------------------------------------------------------------------------

;REND (indtypes)

TYPE.CPU	EQU	0Fh	; CP-program (only in E2base records)
  PAGE
;----------------------------------------------------------------------------
; 4.3	Directory numbers
;----------------------------------------------------------------------------
;	Default directory numbers used for e2base and for dialling:
;----------------------------------------------------------------------------
DIR.RO          EQU     0FFF0h  ; (   0)        RO Route
DIR.EX          EQU     0F200h  ; ( 200)-( 399) EX Extensions
DIR.TR          EQU     0F700h  ; ( 700)-( 799) TR Trunks
DIR.GP          EQU     0FFF8h  ; (   8)        GP Group call pickup.
DIR.OP          EQU     0FFF9h  ; (   9)        OP Operator queue, common
                                ;                  number for all operators.
DIR.DIKEY	EQU	0FA0Bh  ; ( *0#)	DI Internal directory 'book'.
DIR.DEKEY	EQU	0FB0Ah  ; ( #0*)	DE External directory 'book'.
DIR.PROGIND     EQU     0A00Ah  ; (*00*)        PR Programming, individual. 
DIR.PROG        EQU     0A00Bh  ; (*00#)        PR Programming. 

DIR.EXMLT	EQU	0A11Bh	; (*11#)	EX Multi Line Terminal

DIR.DIVON       EQU     0FA21h  ; ( *21)        EX Diversion on
DIR.DIVOFF      EQU     0FB21h  ; ( #21)        EX Diversion off

DIR.IEDON	EQU	0FA22h	; ( *22)	EX Individual external diversion on
DIR.IEDOFF	EQU	0FB22h	; ( #22)	EX Individual external diversion off

DIR.INFOA	EQU	0A23Ah	; (*23*)	IN Information system
DIR.INFOE	EQU	0B23Bh  ; (#23#)	IN IN Information system /
				;		   erase program information

DIR.EXLOGON	EQU	0FA28h	; ( *28)	EX Logon of slave
DIR.EXLOGOFF	EQU	0FB28h	; ( #28)	EX Logoff of slave

DIR.HOCHK       EQU     0A31Bh  ; (*31#)        HO Checkin/checkout/status
DIR.HOWUA       EQU     0A32Bh  ; (*32#)        HO Admin wakeup
DIR.HOCLN       EQU     0A33Ah  ; (*33*)        HO Guest room clean
DIR.HOBAR       EQU     0A34Bh  ; (*34#)        HO Manual barring

DIR.REMON	EQU	0A32Ah	; (*32*)	RE Reminder on
DIR.REMOFF	EQU	0B32Bh	; (#32#)	RE Reminder off

DIR.MCID        EQU     0A39Bh  ; (*39#)        MC Malicious call identific.

DIR.CDPRINT	EQU	0A40Bh	; (*40#)	CD ACD print procedure.
DIR.EXCOST	EQU	0A41Bh	; (*41#)	EX Cost info act./deactivate
DIR.CMACC	EQU	0A45Bh	; (*45#)	CM Call metering accumulators
DIR.CMLAST	EQU	0A46Bh	; (*46#)	CM Call metering. last call
DIR.CI		EQU	0A48Bh	; (*48#)	CI ISDN caller llist

DIR.SAI		EQU	0A51Ah	; (*51*)	EX Store ind. abbr. number
DIR.DAI		EQU	0FB51h	; ( #51)	EX Delete ind. abbr. number

DIR.ALALR	EQU	0A53Bh	; (*53#)	AL Alarm start
DIR.ALCLR	EQU	0A54Bh	; (*54#)	AL Alarm clear
DIR.HOWUO	EQU	0A55Ah	; (*55*)	HO Wakeup order/cancel
DIR.DICT        EQU     0A58Bh  ; (*58#)        MI Dictaphone in Message System
DIR.MESS        EQU     0A59Bh  ; (*59#)        MI Message system.  

DIR.EXBYP	EQU	0A60Ah	; (*60*)	EX Bypassing Call Diversion

DIR.BISIL       EQU     0A65Ah  ; (*65*)        BI Silent intrusion.

DIR.EXAUON	EQU	0A72Bh	; (*72#)        EX Authority, activate.
DIR.EXAUOFF	EQU	0B72Ah	; (#72*)        EX Authority, deactivate.
DIR.EXAUTMP	EQU	0A72Ah	; (*72*)        EX Authority, temp. deact.
DIR.EXAUPWD	EQU	0BA72h	; (#*72)        EX Authority, change password.
DIR.EXCOB	EQU	0A73Bh	; (*73#)	EX Pickup Code for
				;		   Common Bell Extension
DIR.ALINP	EQU	0A79Bh	; (*79#)	AL Alarm read 

DIR.NSW         EQU     0FA8Bh  ; ( *8#)        PA Night switching, toggling
                                ;                  (common, switches all)
DIR.NSW0        EQU     0A80Bh  ; (*80#)        PA Night switch of system,
                                ;                  (used by TCD etc.)    
DIR.NSW1        EQU     0A81Bh  ; (*81#)-(*88#) PA Night switching of trunk-
                                ;                  groups, toggling.
DIR.NSWACD	EQU	0A898h	; (*898)	PA Night switching of all
				;		   ACD-groups
DIR.NSWACD0	EQU	0A890h	; (*890)-(*897)	PA Night switching of ACD-groups
				;		   (0-7), toggling
  PAGE
DIR.AC          EQU     0FA9Ah  ; ( *9*)        AC Account codes (pre-dial)
DIR.ITST        EQU     0A90Bh  ; (*90#)        OM Instrument test 
DIR.LARM        EQU     0A91Bh  ; (*91#)        OM Alarm.

DIR.EXMAION	EQU	0A92Ah	; (*92*)        EX External voice mail on
DIR.EXMAIOFF	EQU	0B92Ah	; (#92*)        EX External voice mail off

DIR.TRSER	EQU	0A93Bh	; (*93#)        TR No of 'public' extensions

DIR.LNR		EQU	0FAAAh	; ( ***)	EX Last number redial
DIR.NRD		EQU	0FFAAh	; (  **)	EX Number redial
				;		   (last or ind. abbr. number)
   PAGE
;----------------------------------------------------------------------------
;     Directory numbers used for e2base and seizuring. Not used for dialling:
;
;     NOTE!  Avoid 'E' in these numbers.
;            'E' is dispayed as a '-' and in first case used 
;             to indicate 'wild cards' in a number interval
;----------------------------------------------------------------------------
DIR.DI          EQU     0FD10h  ; ( D10)        DI Internal directory 'book'.
DIR.DE          EQU     0FD11h  ; ( D11)        DE External directory 'book'.

DIR.VPN         EQU     0FD20h  ; ( D20)	EX Virtual private networking.
DIR.DIV         EQU     0FD21h  ; ( D21)        EX Diversion key.
DIR.IED		EQU	0FD22h	; ( D22)	EX Individual external diversion
;               EQU     0FD30h  ;  
DIR.HOWUG       EQU     0FD32h  ; ( D32)        HO Guest wakeup.
DIR.HOWUR       EQU     0FD33h  ; ( D33)        HO Wakeup ring.
DIR.REMCALL     EQU     0FD34h  ; ( D34)        RE Remainder call.

DIR.LCR		EQU	0FD40h	; ( D40)	LR Least cost routing prefix

DIR.AA		EQU	0FD45h	; ( D45)	AA Automated Attendant

DIR.INFO        EQU     0FD50h  ; ( D50)        IN Information system.
DIR.CB          EQU     0FD60h  ; ( D60)        CB Call Back.
DIR.BI          EQU     0FD70h  ; ( D70)        BI Break in.
DIR.CO          EQU     0FD80h  ; ( D80)        CO Conference.
DIR.VM          EQU     0FD90h  ; ( D90)        VM Voice memory
DIR.REC		EQU	0FD98h	; ( D98)	MG Conversation recording
DIR.AN          EQU     0FDA0h  ; ( D*0)        AN Annoncement.
DIR.SNR		EQU	0FDAAh	; ( D**)	EX Saved number redial
DIR.EUMOD       EQU     0FDB0h  ; ( D#0)        EU Modem calls.
DIR.CDRDY	EQU     0FDC0h  ; ( DC0)	CD ACD Ready, activemark.
DIR.CDCLER	EQU     0FDC1h  ; ( DC1)	CD ACD Clerical time.
DIR.CDSUP	EQU     0FDC2h  ; ( DC2)	CD ACD Supervision (help).
DIR.CDNONACDCC	EQU	0FDC3h	; ( DC3)
DIR.CDCCODE	EQU	0FDC4h  ; ( DC4)	CD ACD Call code Clerical state.

DIR.VP          EQU     0FDD0h  ; ( DD0)-( DD7) VP Voice paging (8 groups).
                                ;                  FDD = specially selected 
                                ;                  code, EX does suppress FDD
                                ;                  when displaying the number
                                ;                  of the connected party.

;               EQU     0FDE0h  ; ( D-0)           Avoid numbers with 'E'
;                                                  see note above.

DIR.NONUM       EQU     0FFFFh  ; (    )        -- No direcory number defined.
  PAGE
;----------------------------------------------------------------------------
;     Other directory numbers, not used for seizuring or dialling:
;----------------------------------------------------------------------------
                                ;               AN Announcement
                                ;                  references + sparenumbers:
DIR.ANANNO        EQU   0D000h  ;  D000 - D02F     Voice announcement 1-32  (48)
DIR.ANINFO        EQU   0D030h  ;  D030 - D03F     Information 1-7          (16)
DIR.ANMONTHS      EQU   0D040h  ;  D040 - D04F     Months 1-12              (16)
DIR.ANDATES       EQU   0D050h  ;  D050 - D06F     Dates 1-31               (32)
DIR.ANHOURS       EQU   0D070h  ;  D070 - D08F     Hours 0-23   (Lang. 1)   (32)
DIR.AN5MINUTES    EQU   0D090h  ;  D090 - D09F     5 Minutes 0-11 (Lang. 1) (16)
DIR.ANHOURS2      EQU   0D0A0h  ;  D0A0 - D0BF     Hours 0-23   (Lang. 2)   (32)
DIR.AN5MINUTES2   EQU   0D0C0h  ;  D0C0 - D0CF     5 Minutes 0-11 (Lang. 2) (16)
DIR.ANHOURS3      EQU   0D0D0h  ;  D0D0 - D0EF     Hours 0-23   (Lang. 3)   (32)
DIR.AN5MINUTES3   EQU   0D0F0h  ;  D0F0 - D0FF     5 Minutes 0-11 (Lang. 3) (16)
DIR.ANAUTOATT	  EQU	0D100h	;  D100 - D12F	   AA announcement 1-42     (48)
DIR.ANMSGPROMPT   EQU	0D130h	;  D130 - D13F	   Voice Prompt 0-14	    (16)
DIR.ANMSGPROMPT2  EQU	0D140h	;  D140 - D14F	   Voice Prompt 0-6(Lang.2) (16)
DIR.ANMSGPROMPT3  EQU	0D150h	;  D150 - D15F	   Voice Prompt 0-6(Lang.3) (16)
DIR.ANWELCOMEIND  EQU	0D160h	;  D160 - D17F	   Welc.Stor.Ind.Mess. 0-31 (32)
DIR.ANRETRIEVEIND EQU	0D180h	;  D180 - D18F	   Welc.Retr.Ind.Mess. 0-15 (16)
DIR.ANWELCOMECOM  EQU	0D190h	;  D190 - D19F	   Welc.Common Mailbox 0-15 (16)
DIR.ANRETRIEVECOM EQU	0D1A0h	;  D1A0 - D1AF	   Welc.Retr.Mailbox   0-15 (16)
DIR.ANDIGITS	  EQU	0D1B0h	;  D1B0 - D1BF	   Program Digits 0-9	    (16)
DIR.ANDIGITS2	  EQU	0D1C0h	;  D1C0 - D1CF	   Progr.Digits 0-9(Lang.2) (16)
DIR.ANDIGITS3	  EQU	0D1D0h	;  D1D0 - D1DF	   Progr.Digits 0-9(Lang.3) (16)
DIR.ANSYSTEM	  EQU	0D1E0h	;  D1E0 - D1EF	   System Voice Prompt 0-2  (16)
DIR.ANDISA        EQU   0D1F0h	;  D1F0 - D1FF     DISA Voice Prompts 0-9   (16)
DIR.ANTRUNK       EQU   0D200h	;  D200 - D23F     Trunk Announcements 0-63 (64)
DIR.ANACD         EQU   0D300h	;  D300 - D3FF     ACD ind. Greeting 1-255 (256)
DIR.ANAACTI       EQU   0D400h  ;  D400 - D41F     CTI-AA Voice Prompts 1-24(32)
DIR.ANMOH         EQU   0D420h  ;  D420 - D42F     MOH Voice Prompts 0-15   (16)
DIR.ANADDMB	  EQU	0D440h	;  D440 - D45F     Add. mailbox voice
				;                              prompts 0-19 (32)
DIR.ANMONTHS2	  EQU	0D470h	;  D470 - D47F     Months (Language 2) 1-12 (16) (4429)
DIR.ANDATES2	  EQU	0D480h	;  D480 - D49F     Dates  (Language 2) 1-31 (32) (4430)
DIR.ANMONTHS3	  EQU	0D4A0h	;  D4A0 - D4AF     Months (Language 3) 1-12 (16) (4431)
DIR.ANDATES3	  EQU	0D4B0h	;  D4B0 - D4CF     Dates  (Language 3) 1-31 (32) (4432)
DIR.ANMBCNTIN	  EQU	0D4D0h	;  D4D0 - D4EF     Mailbox content information (Language 1) 0-18 (32) (4433)
DIR.ANMBCNTIN2	  EQU	0D4F0h	;  D4F0 - D50F     Mailbox content information (Language 2) 0-18 (32) (4434)
DIR.ANMBCNTIN3	  EQU	0D510h	;  D510 - D52F     Mailbox content information (Language 3) 0-18 (32) (4435)
DIR.ANPBXQUEUE	  EQU	0D530h	;  D530 - D53F     PBX groups queue announcements           0-15 (16) (4436)
DIR.ANPWRSND      EQU   0D540h	;  D540 - D55F     Maiboxsystem - Message forwarding and send message (32) (4437)
DIR.ANOCN         EQU   0D560h	;  D560 - D57F     Maiboxsystem - Outcall notification                (32) (4438)


DIR.CPDAUDIO 	EQU	0DB00h	;  D#00		   Used by MU as identifier 
				;		   for audio input on CPU-D
DIR.PUB		EQU	0DC00h	;  		   Used by PA as identifier
				;		   for public numbers
  PAGE
        STITLE     '5. PCM-CHANNELS'
;----------------------------------------------------------------------------
; 5.    PCM-CHANNELS
;----------------------------------------------------------------------------
;       PCM-channels, a channel is the 2-way connection between 2 parties.
                            
PCMCHANNELQNT	EQU	64		; Total quantity of PCM-channels in 
					; system.
					;
PCMCLOW		EQU	0		; Lowest channel number.
PCMCHIGH	EQU	PCMCHANNELQNT-1	; Highest channel number.
					;
					; Special reserved PCM channels:
					; ------------------------------
PCMCFIXIDLE	EQU	0		; For TS/SX/(MU) idle. silent, music.
PCMCFIXTON1	EQU	1		; For TS/SX/ELU constant ton (bus 0,1)
PCMCFIXTON2	EQU	2		; For TS/SX/ELU constant ton (bus 0,1)
					; NOTE!  SX(TRM) does a control of 
					;       'listen only' for these fixed 
					;        channels

PCMCH.SILENT	EQU	PCMCFIXIDLE	; Silent channel (Listen to bus 0)
PCMCH.MUSIC	EQU	PCMCFIXIDLE+40h	; Music on hold  (Listen to bus 1)

					; PCM timelots at TSU-bus
					;------------------------------------
PCMTSUQNT	EQU	32		; Number of timeslots
PCMTSUHIGH	EQU	PCMTSUQNT-1	; Highest number



        STITLE     '6. MEMORY'
;
;-------------------------------------------------------------------------------
; 6.    MEMORY
;-------------------------------------------------------------------------------
;
;-------------------------------------------------------------------------------
; 6.1   MEMORY CHECK CODES
;-------------------------------------------------------------------------------
;
;        For test of configuration, restart reason and so on is check codes
;        used. The code normally used as a 4 byte code but used by the program
;        in two two-bytes format:
				   ;--------------------------------------------
				   ;
CHKCODE1        EQU        1248h   ; Normal first check code
CHKCODE2        EQU        7BDEh   ; Normal second checkcode
				   ;
				   ;
CHKCODE1SUBS    EQU        2436h   ; Alternative for first check code.
                                   ;
                                   ; Used in program map headers when testing
                                   ; a system with some program-maps placed
                                   ; in PROM and some program-maps loaded in
                                   ; RAM.
                                   ;
                                   ; This alternative check code gives
                                   ; information to the operating system that
                                   ; the program map (normally in RAM) shall
                                   ; be used as a substitute for an orginal 
                                   ; map (PROM) with same program map number
                                   ; in the program map header.
                                   ;
                                   ; The value of the CHKCODE1SUBS is selected
                                   ; with respect to CHKCODE1 to give the 
                                   ; same checsum in the program map.
 				   ;--------------------------------------------


;-------------------------------------------------------------------------------
; 6.2   MAPPED DATA MEMORY (common)
;-------------------------------------------------------------------------------
;
;       There are 24 data maps (RAM) defined for common use.
;       All maps are used for MDATA (dynamic allocated RAM) OSBEG*.SA9,
;       and for OS-buffers OSBUF*.SA9.
;       Actual number of maps are may not be equal on different CPU-boards,
;	the memory area have to be examined by handling program (OSBEG*.SA9).
;       The main use of the data are showed here, the details are specified
;       within the users data description.
;       The global reference M.DATA is the first address in this area.
;
;       The maps are cleared by OSBEG*.SA9 at restart, exeption see NOTE 
;
;       NOTE!  All program blocks in central program map has always OS-buffers
;              in data map 0 (fixed). (Central data map,  MAPCENTRD)
;
;       NOTE!  The program blocks in central program map are not allowed to use
;              class=MDATA for own RAM, have to use class=CDATA (not mapped).
;
;       NOTE!  OM-block has to use map 0 for buffers and MDATA,
;              MDATA is not cleared in map 0 to protect trace-loggs etc.
;
;                   DATA-map 0         DATA-map 1    ---    DATA-map 23/32
;                 ______________     ______________        ______________
;     M.DATA     |__never used__|   |__never used__|      |__never used__|   
;                |__map header__|   |__map header__|      |__map header__|   
;                |   os-buffer  |   |   os-buffer  |      |   os-buffer  |   
;                |__ variables _|   |__ variables _|      |__ variables _|   
;                |  OS-BUFFERS  |   |  OS-BUFFERS  |      |  OS-BUFFERS  |   
;                |  |           |   |  |           |      |  |           |   
;                |  |        |  |   |  |        |  |      |  |        |  |   
;                |       MDATA  |   |       MDATA  |      |       MDATA  |   
;     M.DATAEND  |______________|   |______________|      |______________|
;                                              
;-------------------------------------------------------------------------------
 				  ;
DMAPQNT         EQU     32        ; Quantity (max possible).
DMAPSIZE        EQU   6000h       ; Size of one data map
  				  ;
MAPFIRSTD       EQU      0        ; Data map, first number.
MAPLASTD        EQU  DMAPQNT-1    ; Data map, last number. 
				  ;---------------------------------------------

                                  ;---------------------------------------------
                                  ; D-MAP 00            
                                  ;---------------------------------------------
MAPCENTRD       EQU      0        ; The map is reserved for program blocks in
                                  ; central program map (OS etc.) and OM use.
                                  ; See notes above (MDATA not cleared)
                                  ;---------------------------------------------
MAPCILD		EQU	4
 
                                  ;---------------------------------------------
                                  ; D-MAP (all maps equal)
                                  ;---------------------------------------------
DNEVERSIZE      EQU   OSBUFFSZL   ; Size of a never used area, avoid errors
                                  ; when buffers are addressed without valid 
                                  ; address pointer (first in all maps).
                                  ;
DOSBEGSIZE      EQU 15            ; Size of D.OSBEG part of the mapped RAM,
                                  ; administrated by OSBEG*.SA9.
                                  ; Used for datamap header.
                                  ;
DOSBUFVAR	  EQU	17	  ; Size of segment and buffer variables in 
				  ; the mapped RAM.
DOSBUFNUMBITFIELD EQU	496	  ; Size of the buffer number bit field.
DOSBUFACCESSTAB	  EQU	368	  ; (Max) size of the access table.
				  ;
DOSBUFSIZE EQU DOSBUFVAR+DOSBUFNUMBITFIELD+DOSBUFACCESSTAB
			          ; Size of D.OSBUF part of the mapped RAM,
                                  ; administrated by OSBUF*.SA9. 
                                  ; Used for OS-buffer variables.
				  ;
D.NEVER    EQU  M.DATA            ; First address in never used area.
D.OSBEG    EQU  D.NEVER+DNEVERSIZE; First address in OSBEG part
D.OSBUF    EQU  D.OSBEG+DOSBEGSIZE; First address in OSBUF part,
                                  ; used for buffer handlers variables.
				  ;
D.OSBUFBEG EQU  D.OSBUF+DOSBUFSIZE; First address for OS-buffers.
				  ;
				  ;---------------------------------------------
  
       ;------------------------------------------------------------------------
       ; Below specified part of the data map are shared for OS-buffers and
       ; MDATA.  The OSBEG*.SA9 has first to examine MDATA-need from the 
       ; program map  headers, then allocate the MDATA at highest possible 
       ; addresses, within the M.DATABEG --- M.DATAEND part of map.
       ;
       ; The actual first address for MDATA is then given to the buffer handler
       ; OSBUF*.SA9 to allocate as many buffers as possible from the address
       ; D.OSBUFBEG up to given address (within the range 1 - OSBUFFQNT).
       ;
       ; Note, there is reserved space for at least one buffer (OSBUFFSZ) to 
       ; garantee the operating system at least one buffer in every data-map.
       ;
       ; This MDATA-part are cleared by restart (exeption map 0, see above)
       ;------------------------------------------------------------------------
 					;
M.DATACEND EQU  D.OSBUFBEG+OSBUFFSZL-1  ; Highest address allowed to clear
                                        ; in central data map (0).
                                        ;
M.DATABEG  EQU  M.DATACEND+1            ; Lowest possible address for MDATA
                                        ; 
M.DATAEND  EQU  M.DATA+DMAPSIZE-1       ; Last address in MDATA area.
                                        ; Last address in data map too.
                                        ; Highest address allowed to clear
                                        ; in all other data-maps.
 					;---------------------------------------

 
;-------------------------------------------------------------------------------
; 6.3   EXTENDED MAPPED RAM / E2-PROM.
;-------------------------------------------------------------------------------
;       There are extended (E) mapped data area used by selected,
;       and here defined functions within the system.
;   
;       The memory are built of 64 RAM maps (always installed), one of the RAM-
;	maps (map 24) is battery backed and write protected (located within the
;	real time circuit). 
;	Rest of this area is reserved for up to 32 E2-prom maps. Actual number
;	of E2-maps are installation depended and has to be examined by E2-
;	handling program.
;
; 	In a future version of the card (CPU-E ROF 157 5124) there will be
;	32 additional battery backed RAM-maps with number 32-63). 
;	See the map-port (PORT$MAPE) in chapter 6.6 below)
;
;       Mapnumbers, sizes and startadresses are defined below.
;
;       Name rule:   'E1' is used in names for the RAM-part.
;                    'E2' is used in names for the E2-prom-part.
;
;       The global reference E.DATA is the first address in this area.
;       
;-------------------------------------------------------------------------------
 
;-------------------------------------------------------------------------------
; 6.3.1 RAM PART of mapped extended area.  (SYSTEM RAM MAP area)
;-------------------------------------------------------------------------------
;
;       There are 23 data RAM-maps defined (named E1).
;       Map number 1-23 are normal RAM and map 24 is battery backed.
;
;	Maps 25-31 do not exist due to hardware reasons.
;
;	(There are other battery backed-up RAM maps above map 32,
;	they are described separately in 6.3.2)
;
;       These maps shares the same address range as the E2-memory below.
;       The main use of the data are showed here, the details are specified
;       within the users data description.
;
;       The normal RAM-maps (1-23) are cleared by OSBEG*.SA9 at restart.
;
;       NOTE !
;       The E1-MAP 23 is normally selected by OS when enter a job.
;       In all other routines the previous selected map in this area must 
;       be restored after use of the map.
;
;            
;            E1-map  1   E1-map  2   E1-map  3   E1-map  4-15
;            _________   _________   _________   ____________ 
; E.DATA    |jobqueue | |jobqueue | |normal   | |indiv.      |
;           |   B     | |    D    | |OS-      | |RAM-        |
;           |         | |         | |timers   | |records     |
;           |         | |         | |         | |            |
;           |_________| |         | |periodic+| |            |
;           |jobqueue | |         | |delaysend| |            |
;           |   C     | |         | |timers   | |            |
;           |         | |_________| |_________| |            |
;           |         | | spare   | |spare    | |            |
; E.DATAEND |_________| |________ | |_________| |____________|
;
;            E1-map 16   E1-map 17   E1-map 16-22  
;            _________   _________  ____________  
; E.DATA    |         | |         | |            | 
;           |         | |         | |            | 
;           |  DI     | |   DE    | |            | 
;           |         | |         | |            | 
;           |         | |         | |   free     | 
;           |         | |         | |            | 
;           |         | |         | |            | 
;           |         | |         | |            | 
;           |         | |         | |            | 
; E.DATAEND |_________| |_________| |____________| 
;
;            E1-map 23   E1-map 24-31(D5)  E1-map 24(D4)/192(D5)
;            _________    ____________        _________ 
; E.DATA    |         |  |            |      |battery  |
;           |         |  |            |      |backed   |
;           | default |  |            |      |OS-      |
;           | map,    |  |            |      |records  |
;           |         |  |   free     |      |     
;           |         |  |  (CPU-D5)  |      |---------|
;           | not     |  |            |      |'hidden' |
;           | used    |  |            |      |_________|
;           |         |  |            |      |realtime |
; E.DATAEND |_________|  |____________|      |_________|
;
;-------------------------------------------------------------------------------
				      ;
E1MAPSIZE          EQU     2000h      ; Size of one E1 ram map
				      ;
MAPFIRSTE1         EQU      1         ; Extended mapped RAM, first number
MAPLASTE1	   EQU	    23	      ;
				      ;
MAPFIRSTE1BAT	   EQU	    32	      ; Low number of battery backed RAM map
MAPLASTE1BAT	   EQU	    51	      ; High number of battery backed RAM map
NO.E1BAT.MAP	   EQU	    0FFh
				      ;
E.DATAEND   EQU    E.DATA+E1MAPSIZE-1 ; Last address in extended datamap.
            			      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 0
                                      ;-----------------------------------------
;		EQU	0	      ; MUST NOT be used,
				      ; does not exist physically !
                                      ;-----------------------------------------
				      ;
				      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 01 and E1-MAP 02
                                      ;-----------------------------------------
MAPE1OSSND_B_C	EQU	1	      ; Data map for OSSND-data, job queues B+C
MAPE1OSSND_D	EQU	2	      ; Data map for OSSND-data, job queue D
                                      ; ------
E1OSSNDSIZE     EQU   E1MAPSIZE       ; Size of E1.OSSND part of the RAM in map
                                      ; MAPE1OSSND_..., administrated by 
				      ; OSSND*.SA9
				      ;-----------------------------------------
E1.OSSND    EQU   E.DATA              ; First address for OSSND-part of memory.
            			      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 03
                                      ;-----------------------------------------
MAPE1OSTIM      EQU	3             ; Data map for OSTIM-data, (OS-timers)
                                      ; ------
E1OSTIMSIZE     EQU   E1MAPSIZE       ; Size of E1.OSTIM part of the RAM in map
                                      ; MAPE1OSTIM, administrated by OSTIM*.SA9
				      ;-----------------------------------------
E1.OSTIM    EQU   E.DATA              ; First address for OSTIM-part of memory.
            			      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 04 - 15
                                      ;-----------------------------------------
MAPE1INDFIRST	EQU	 4	      ; First data map in the idividual RAM area
MAPE1INDLAST	EQU	15	      ; Last  data map in the idividual RAM area
                                      ; ------
E1INDRAMSIZE    EQU   8176            ; Size for individual RAM-record, used by
		                      ;      RP-handling CP-program. 
                                      ; This area is administraded by SU, 
				      ; start up
				      ;-----------------------------------------
E1.INDRAM   EQU   E.DATA              ; First address in indvidual RAM
E1.SPAREI   EQU   E1.INDRAM+E1INDRAMSIZE; First address in spare part 
            			      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 16
                                      ;-----------------------------------------
MAPE1DI     EQU   16                  ; Data map for DI, (int. telephone 
				      ; directory)
                                      ; ------
E1DISIZE    EQU   E1MAPSIZE           ; Size of E1.DI part of the RAM in map
                                      ; MAPE1DI, administrated by DI-block
				      ;-----------------------------------------
E1.DI       EQU   E.DATA              ; First address for DI-part of memory.
				      ;-----------------------------------------
            			      ;
            			      ; E1-MAP 17
                                      ;-----------------------------------------
MAPE1DE     EQU   17                  ; Data map for DE, (ext. telephone 
				      ; directory)
                                      ; ------
E1DESIZE    EQU   E1MAPSIZE           ; Size of E1.DE part of the ram in map
                                      ; MAPE1DE, administrated by DE-block
				      ;-----------------------------------------
E1.DE       EQU   E.DATA              ; First address for DE-part of memory.
				      ;
            			      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 23 (normally selected)
                                      ;-----------------------------------------
MAPE1NORM       EQU      23           ; Data map, normally selected (by OS).
                                      ;
				      ;
                                      ;-----------------------------------------
                                      ; E1-MAP 24 (battery backed RAM and RTC)
                                      ;-----------------------------------------
                                      ; CPU-D5 :
MAPE1BATTERY.D5	EQU     192           ; Data map for battery backed RAM.
MAPE1OSRTC.D5	EQU     192           ; Data map for realtime clock and RAM.
MAPE1OSREC.D5	EQU     192           ; Data map for OS-records.
                                      ; CPU-D4 :
MAPE1BATTERY.D4	EQU      24           ; Data map for battery backed RAM.
MAPE1OSRTC.D4	EQU      24           ; Data map for realtime clock and RAM.
MAPE1OSREC.D4	EQU      24           ; Data map for OS-records.
                                      ; ------
E1OSRECSIZE	EQU   1F80h           ; Size for OS records (8064 bytes)
                                      ; This area is administrated by OSREC*.SA9
                                      ; ------
E1HIDESIZE	EQU     60h           ; Size of hidden part, for future
				      ;(112 bytes)
				      ; (not allowed to read with OS.CALL CP.RD)
                                      ; ------
E1OSRTCSIZE	EQU	 8            ; Size of RAM for realtime clock 
                                      ; This area is administrated by OSRTC*.SA9
				      ;-----------------------------------------
E1.OSREC    EQU   E.DATA              ; First address in OS-records
E1.HIDE     EQU   E1.OSREC+E1OSRECSIZE; Hidden part, for future
E1.HIDEEND  EQU   E1.HIDE+E1HIDESIZE-1; Hidden part, last address
E1.OSRTC    EQU   E1.HIDE+E1HIDESIZE  ; First address in realtime RAM
E1.PORT$RTC EQU   E.DATA+1FF8h        ; First address in realtime clock
				      ;
E1.OSBAT    EQU   E.DATA	      ; First address in battery backed RAM maps
            			      ;-----------------------------------------


;-------------------------------------------------------------------------------
; 6.3.2 OS.BATT Part of mapped Battery Backed-Up RAM
;-------------------------------------------------------------------------------
;       There are, depending on the hardware revision of the CPU-D4,
;	3x32 or 4x32 Maps available as BRAM area
;	This area is devided into 2 parts, the lower maps are handled by
;	the OS.BATT interface, the higher maps are handled by the E2 handler.
;	both areas of this non-voatile memory are used for configuration.
;
;       These maps share the same address range as the RAM memory E1 above.
;
;	The OS.BATT maps are supported by the OS.BATT system calls.
;	they supply an interface or dynamic memory allocation with variable
;	sized records and support linked lists.
;	details see description of OS.BATT system call interface.
;
;	OS BATT maps start at mapnumber MAPFIRSTE1BAT (which is the lowest
;	map number 32) and ends at MAPLASTE1BAT.
;
;
;-------------------------------------------------------------------------------
; 6.3.3 E2 Part of mapped Battery Backed-Up RAM
;-------------------------------------------------------------------------------
;       There are, depending on the hardware revision of the CPU-D4,
;	3x32 or 4x32 Maps available as BRAM area
;	This area is devided into 2 parts, the lower maps are handled by
;	the OS.BATT interface, the higher maps are handled by the E2 handler.
;	both areas of this non-voatile memory are used for configuration.
;
;       These maps share the same address range as the RAM memory E1 above.
;
;	the E2 area ranges from MAPFIRSTE2 to MAPLASTE2.
;
;       The E2-block owns the lower part in every map, the first address
;       for the E2-handlers own part of memory is specified here.
;       Other block can be owner of an own part in an E2-map, the mapnumber
;       and size of the blocks own part are specified here.
;       The main use of the data are showed here, the details are specified
;       within the users data description.
;
;                        E2-map 1st        E2-map 2nd   -----   E2-map last
;                      _____________     _____________         _____________
; (E.DATA)     E2.ff  | block owned |   | block owned |       | block owned |
;                     |  (if any)   |   |  (if any)   |       |  (if any)   |
;                     |_____________|   |_____________|       |_____________|
;              E2.### |  e2base     |   |  e2base     |       |  e2base     |
;                     |             |   |             |       |             |
;                     |             |   |             |       |             |
;                     |_ e2records _|   |_ e2records _|       |_ e2records _|
; (E.DATAEND)  E2.END |_____________|   |_____________|       |_____________|
;
;
;	NOTE !!		the CPU-E has space for maps 8-23 and 32-63,
;			there is no access to maps 24-31
;			
;
;-------------------------------------------------------------------------------
;	macro	E2NRDEF
;-----------------------
;	this macro defines a value for the E2.### symbols and declares
;	the symbols as global (### represents the decimal E2 map number).
;	for each symbol lines looking like
;			GLOBAL	E2.###
;		E2.###	EQU	value
;	are generated (using the SYDEF macro).
;	
;       FORMAT:	E2NRDEF	map.nr, value
;		E2NRDEF	map.nr.1st, mapnr.last, value
;-------------------------------------------------------------------------------

	string	e2.s1(3), e2.s2(6), e2.s3	; used string variables

	macro	E2NRDEF				; macro begin

e2.n	set	"1"				; first mapnumber = param 1

	IF	"#" = 3				; IF 3 params
e2.nlst	set	"2"				;   last mapnumber = param 2
e2.s3	set	stringof(3)			;   and value = param 3
	ELSEIF	"#" = 2				; ELSEIF 2 params
e2.nlst	set	e2.n				;   only one symbol declared
e2.s3	set	stringof(2)			;   and value = param 2
	ELSE					; ELSE wrong macro usage
	WARNING	E2NRDEF : wrong number of parameters
	EXITM					;   asm warning and exit macro
	ENDIF					; ENDIF

e2.s1	set	'E2.'				; all symbols begin with E2.

	repeat	e2.n <= e2.nlst			; REPEAT

e2.s2	set	e2.s1 : seg(string(e2.n), 9, 3) ;   get map number

	SYDEF1	"e2.s2", "e2.s3"		; EQU

e2.n	set	e2.n + 1			; count up map number
	endr					; END REPEAT

	endm					; END MACRO


;-------------------------------------------------------------------------------
				  ;
E2MAPSIZE      EQU     2000h      ; Size of one E2 map.
				  ;
MAPFIRSTE2     EQU     64	  ; Data map E2, first number.
MAPLASTE2      EQU    127         ; Data map E2, last number.
				  ;
E2WRITE.MS     EQU      2         ; Time in millisec. for an E2-write cycle
                                  ; Valid values 1-15 ms. Value depends of 
                                  ; E2-circuit-types on the CPU-D/E board. 
				  ;---------------------------------------------

                                  ;---------------------------------------------
                                  ; E2-MAP 64
                                  ;---------------------------------------------
MAPE2OM        EQU     MAPFIRSTE2+0 ; Data map E2, for OM-data.
                                  ; ------
E2OMSIZE       EQU     0C00h      ; Size of E2.OM part of the E2-memory in
                                  ; map MAPE2OM, administrated by OM-block,
                                  ; used for error and alarm logging.
			          ;---------------------------------------------
E2.OM   EQU    E.DATA             ; First address for OM-part of E2-memory.
                                  ;- - - - - - - - - - - - - - - - - - - - - - -
	E2NRDEF	MAPE2OM,E.DATA+E2OMSIZE; First address for E2-blocks own part.
				  ;
			 	  ;---------------------------------------------

                                  ;---------------------------------------------
                                  ; E2-MAP 65
                                  ;---------------------------------------------
MAPE2MG        EQU     MAPFIRSTE2+1 ; Data map E2, for MG-data.
                                  ; ------
E2MGSIZE       EQU     1000h      ; Size of E2.MG part of the E2-memory in
                                  ; map MAPE2MG, administrated by MG-block,
				  ;---------------------------------------------
E2.MG   EQU    E.DATA             ; First address for MG-part of E2-memory.
                                  ;- - - - - - - - - - - - - - - - - - - - - - -
	E2NRDEF	MAPE2MG,E.DATA+E2MGSIZE ; First address for E2-blocks own part.
			 	  ;---------------------------------------------

                                   ;--------------------------------------------
                                   ; E2-MAPs 66 - 95
                                   ;--------------------------------------------
				   ;
	E2NRDEF	MAPFIRSTE2+2,MAPLASTE2,E.DATA ; First address for E2-blocks own part.
E2.END  EQU     E.DATA+E2MAPSIZE-1 ; Last address in E2-map for E2-block use.
  				   ;--------------------------------------------


;-------------------------------------------------------------------------------
; 6.4   PROGRAM MEMORY 
;-------------------------------------------------------------------------------
;
;       There are max 128 maps (EPROM) defined for application program use 
;	and one unmapped program area for operating system and equal. The 
;	main use is showed here, for details see PROGRAM MAP HEADER below.
;       The global reference M.PROG is the first address in the mapped area.
;       The global reference C.PROG is the first address in the unmapped
;	(OS kernel).
;
;                   PROG-map 0         PROG-map 1    ---    PROG-map 127
;                 ______________     ______________        ______________
;    M.PROG      |_ map header _|   |_ map header _|      |_ map header _|   
;                |   &  tables _|   |   &  tables _|      |   &  tables _|   
;                |______________|   |______________|      |______________|   
;                |   program    |   |   program    |      |   program    |   
;                |              |   |              |      |              |   
;    M.PROGEND   |______________|   |______________|      |______________|
;                 ______________  _ 
;    C.PROG      |_ map header _|  \        (CPU-D/E has space for map 0-63)
;                |   &  tables _|   \       (2 pieces of 512 kbytes EPROM)
;                |______________|     
;                |   program    |     Central program map (unmapped)
;                |              |   / OS-kernel
;    C.PROGEND   |___vectors ___| _/
;
;					    CPU-D4 has space for map 0-127
;					    (3 pieces of EPROM)
;-------------------------------------------------------------------------------
					  ;
PMAPQNT		EQU	160		  ; Quantity of maps to be handled by OS.
PMAPQNTPROM	EQU	96		  ; Quantity of maps in EPROM.
PMAPEPQNT	EQU	32		  ; Quantity of maps in each EPROM.
PMAPSIZE	EQU	4000h		  ; Size of one program map.
CMAPSIZE	EQU	2000h		  ; Size of the OS-kernel (unmapped OS part)
MAPFIRSTP	EQU	0		  ; Program map, first number. 
MAPFIRSTTESTP.D4 EQU	MAPLASTPROM+1	  ; Number of first test program map CPU-D4
MAPFIRSTTESTP.D5 EQU	MAPFIRSTTESTP.D4+32 ; CPU-D5
MAPLASTP	EQU	PMAPQNT-1	  ; Program map, last number.  
MAPLASTPROM	EQU	PMAPQNTPROM-1	  ; Number of last EPROM program map.
MAPLASTP.D5	EQU	MAPLASTP	  ; CPU-D5
MAPLASTP.D4	EQU	MAPLASTP.D5-32	  ; CPU-D4
					  ;
MAPOSP		EQU	0		  ; Program map number for mapped OS part.
MAPNOTEXISTP	EQU	1		  ; Map number, which map is necessary for
					  ; compiling of OS (not allowed to use)
MAPOSP2		EQU	2		  ;
					  ;
M.PROGEND	EQU	M.PROG+PMAPSIZE-1 ; Last address in mapped program area
C.PROGEND	EQU	C.PROG+CMAPSIZE-1 ; Last address in central program area
					  ;-----------------------------------------


;-------------------------------------------------------------------------------
; 6.5   JOBBASE, RESERVATIONS (global)
;-------------------------------------------------------------------------------
;       All reservation of used memory in class JOBBASE are done here.
;
;	The OS selects always the section JOBBASE (direct page is set to the
;	high byte of JOBBASE) when a job to execute is selected. Therefore the
;	applications can use the direct addressing mode for all variables which
;	are located in the direct page of the JOBBASE area. This is valid for
;	the WREG, JOBREG, JOBRAM, JOBBUF, MAPDATA, MAPPROG, MAPE and CHNTRPOOL
;
;	The codition IS NOT FULLFILLED for the ME-register. Therefore it IS NOT
;	ALLOWED TO USE THE DIRECT ADDRESSING MODE for the ME-register.
;
;-------------------------------------------------------------------------------

;-------------------------------------------------------------------------------
;
; WORK REGISTER
; -------------
;
; Temporary register, normally used (by application) when sending messages,
; requesting timers or sending timer messages.
; 
;-------------------------------------------------------------------------------
;                                ;----------------------------------------------
;-----    EQU       WREG+BUFFNUM ; Not used yet
;-----    EQU       WREG+BUFFLOG ; Not used yet
;-----    EQU       WREG+BUFFJID ; Not used yet
WRML      EQU       WREG+ML      ; Message length
WRST      EQU       WREG+ST      ; Signal type
WRSN      EQU       WREG+SN      ; Signal number
WRCARD    EQU       WREG+CARD    ; Card address
WRIND     EQU       WREG+IND     ; Individ number
WRCODE    EQU       WREG+CODE    ; Information code
WRDATA    EQU       WREG+DATA    ; Data area
WRSUBCODE EQU       WREG+SUBCODE ; Alias for first data byte

;-------------------------------------------------------------------------------
;
; MESSAGE REGISTER   (READ ONLY)
; ------------------------------
;
; Temporary READ ONLY register. The jobqueue handler (OSSND*.SA9)
; and the timer-handler (OSTIM*.SA9) places here the current message
; before the operating system main loop enter a job (OSBEG*.SA9).
; The message is placed in a job-buffer too (OS-buffer), free to use. 
; The meanig of message-register is to have an untouched orginal copy
; of the message to logg by the OM-block if some later OS.WARNING
; trigs the OM-trace-logg function.
; 
; Is allowed to READ by all program blocks.
;
;-------------------------------------------------------------------------------
;                                  ;--------------------------------------------
;-----     EQU       MEREG+BUFFNUM ; Not used yet
MEROSSID   EQU       MEREG+BUFFLOG ; OS-source identity (Jobqueue etc.)  *)
MERJOBID   EQU       MEREG+BUFFJID ; Job identity   (the latest sender)  *)
MERML      EQU       MEREG+ML      ; Message length
MERST      EQU       MEREG+ST      ; Signal type
MERSN      EQU       MEREG+SN      ; Signal number
MERCARD    EQU       MEREG+CARD    ; Card address
MERIND     EQU       MEREG+IND     ; Individ number
MERCODE    EQU       MEREG+CODE    ; Information code
MERDATA    EQU       MEREG+DATA    ; Data area
MERSUBCODE EQU       MEREG+SUBCODE ; Alias for first data byte
                                   ; |
                                   ; *) Values declared in OSSYS*.DAT
				   ;
				   ;--------------------------------------------


;-------------------------------------------------------------------------------
; 6.6   PORTS (hardware and dummies)
;-------------------------------------------------------------------------------
;
;  It is normally not allowed to read or write direct in the ports by user-
;  programs. There are OS-calls written to be used when using ports. The map-
;  and breakpoints-ports are covered by a shadow RAM and the written value 
;  can be read back (useful when testing the system).
;
;  There are also some dummy-ports (without circuits in hardware) defined
;  as use for emulator breakpoints. During test of a system these addresses 
;  can be used as central breakpoints from emulator. 
;
;-------------------------------------------------------------------------------



;-------------------------------------------------------------------------------
; 6.6.1  Map ports.
;-------------------------------------------------------------------------------
;
;  Ports for selecting data and program maps (port covered by a shadow-RAM).
;  The map ports are cleared by hardware on reset.
;
;  Map number symbols, see MEMORY symbols above.
;
;  PORT$MAPDATA used for data mapping      (0-23)
;	Bit7=0 (for future use?) special select of RAM-bank in E1-area,
;	        for details see 1551-ROF 157 5118
;
;  PORT$MAPPROG used for program  mapping  (0-127)
;
;-------------------------------------------------------------------------------
				;
PORT$MAPDATA	EQU  0DB00h	; Address for data map port           
MAPDATAMASK	EQU  00011111b	;  Bitmask for mapnumber               (0-31)
				;
PORT$MAPPROG	EQU  0DB40h	; Address for program map port        
				;
 			        ;
;-------------------------------------------------------------------------------
;
;  Port for selecting OS-RAM and E2-data maps (port covered by a shadow-RAM).
;  The map port is cleared by hardware on reset.
;  Different versions of CPU-D (ROF 157 5118/1, ROF 157 5118/2 and
;  ROF 157 5124) has different use of the bits in this port.
;
;  Map number symbols, see MEMORY symbols above.
;
;  PORT$MAPE    Used for selecting E1-RAM (extended mapped RAM) and E2-prom
;               Normal read/write RAM (0-23) 
;               Battery backed RAM    (24)
;               E2-prom               (8-31)
;		Battery backed RAM    (32-63) Only in ROF 157 5124
;
;
;-------------------------------------------------------------------------------
;	CPU-D old version, ROF 157 5118/1:
;	----------------------------------
;	Bit 4-1	Select map 0-31
;        
;	Bit 5	Controls writing in E2-memory (map 8-31):
;               1= Enable write in E2-memory 
;               0= Disable write in E2.
;               Transition 1 --> 0 of bit 5 causes a NMI to the SP-processor
;               on the CPU-D board, this will start an E2-write-timing, see
;               SPSYS*.DAT for details.
;
;	Bit 7,6 Controls writing in battery backed RAM and RTC (map 1): 
;               00= Write disabled in E1-map 1
;               01= Real time clock circuit in adjust-mode (for production)
;               10= Write enabled
;               11= Write disabled in E1-map 1
;-------------------------------------------------------------------------------
  
;-------------------------------------------------------------------------------
;	CPU-D2 new version, ROF 157 5118/2:
;	-----------------------------------
;	Bit 4-1	Select map 0-31
;        
;	Bit 5	Not used (is set to 0)
;
;	Bit 7,6 Controls writing in battery backed RAM, RTC (map 1) and E2: 
;               00= Write disabled in E1-map 1 and E2-map 8-31
;               01= Write enabled in E2-map 8-31 *)
;               10= Write enabled in E1-map 1
;               11= not used (any write disabled).
;-------------------------------------------------------------------------------
;	CPU-E future version, ROF 157 5124/2:
;	------------------------------------
;	Bit 5-1	Select map 0-63  (No MAPEMASK declared yet)
;        
;	Bit 7,6 Controls writing in battery backed RAM, RTC (map 1) and E2: 
;               00= Write disabled in E1-map 1, 32-63 and E2-map 8-31
;               01= Write enabled in E2-map 8-31 *)
;               10= Write enabled in E1-map 1
;               11= not used (any write disabled).
;-------------------------------------------------------------------------------
;	*) 	Transition 1 --> 0 of bit 6 causes a NMI to the SP-processor
;		on the CPU-D2 board, this will start an E2-write-timing, 
;		see SPSYS*.DAT for details.
;-------------------------------------------------------------------------------
				;
PORT$MAPE	EQU  0DB20h	; Address for extended RAM / e2 port. 
MAPEMASK	EQU  00011111b	; Bitmask for mapnumber (0-31)
MAPE.E1WR	EQU  10000000b	; Enable e1-write in RTC-E1-map
MAPEMASKBAT	EQU  11111111b	; Bitmask for mapnumber 32-127 (b.b.RAM)
				;
MAPE.E2WR.OLD	EQU  00100000b	; Enable e2-write in map 8-31, Old CPU-D
MAPE.E2WR.NEW	EQU  01000000b	; Enable e2-write in map 8-31, all other 
				;
PORT$MAPE2START EQU  0DB60h	;
MAPE.E2WR.D4	EQU  11000000b	;
MAPE.E1WR.D4	EQU  11000000b  ;
MAPE.E1RTC	EQU  10000000b  ;
MAPE.E1REC	EQU  10000000b  ;
MAPE.E1BAT	EQU  01000000b  ;
				;-----------------------------------------------


;-------------------------------------------------------------------------------
; 6.6.2  Breakpoint port, real hardware. (Only available in ROF 157 5118/1)
;-------------------------------------------------------------------------------
;
;  Port for enable/disable one hardware breakpoint in the program code area
;  (address range 8000-FFFF) The port is covered by a shadow ram and the 
;  written address may be read back.
;
;  The breakpoint is enabled by writing the break address (8000-FFFF) in 
;  this port and disabled by writing 0000 (or to clear first byte in the port)
;
;  When enabled, the breakpoint circuits deliver the OP-code for SWI (3F)
;  instead of the normal program code when the CP (6809) reads the EPROM 
;  (programcode) at the given address.
;
;  To execute the breakpoint some support are needed from the SWI-routine 
;  in the central operative system (OS).
;
;  The port is 16 bits, bit use:
;
;	Bit 15:	0= breakpoint disabled
;		1= breakpoint enabled
;
;	bit 0-14   To be compared with address bus bit A0-A14	
;
;-------------------------------------------------------------------------------
				;
PORT$BREAK 	EQU	0DB60h	; Address for breakpoint port, 2 bytes.
				;
  				;-----------------------------------------------


;-------------------------------------------------------------------------------
; 6.6.3  Input and Output port.
;-------------------------------------------------------------------------------
;
;	Input reads power fail and some straps on the CPU-D/E front.
;
;	Output controls power fail reset, led, alarm and watchdog on CPU-D/E
;  	The led and alarm part are cleared by hardware on reset.
;
;	In:	Function:				Use:
;	Bit 0-4: always=1 when read
;	Bit 5:	0= Strap 2a24-2c24, TST-0 inserted	OS test-mode
;	Bit 6:	0= Strap 2a26-2c26, TST-1 inserted	SU test-mode
;	Bit 7:	1= Power has been failed.		Restart reason
;
;	Out:	Function:				Use:
;	Bit 0:	1= Red coldstart led on.		Indicate coldstart
;	Bit 1:	1= Green warning led on.		Alarms in logg
;	Bit 2:	1= Yellow led led on.			Start up info
;	Bit 3:	1= Alarm output (buffered driver)	Alarm logg
;	Bit 4:	1= Watchdog trig, when toggled		Watchdog CP-SP
;	Bit 5:	--
;	Bit 6:	--
;	Bit 7:	0= Clear the power fail indicator.	Restart reason
;
;-------------------------------------------------------------------------------
				;
PORT$INOUT	EQU  0DB80h	; Address for led / alarm / watchdog-port 
				;
INMASK.TST0	EQU  00100000b	; Strap to read 'OS in test-mode'
INMASK.TST1	EQU  01000000b	; Strap to read 'SU in test-mode'
INMASK.PFAIL	EQU  10000000b	; Power fail indicator.
				;
OUT.REDCOLD	EQU  00000001b	; Red led, indicate cold start strap inserted.
OUT.GREEN	EQU  00000010b	; Green warning led on.
OUT.YELLOW	EQU  00000100b	; Yellow led led on.
OUT.ALARM	EQU  00001000b	; Alarm output 
OUT.WATCHDOG	EQU  00010000b	; Watchdog trig, when toggled
OUT.PFAIL.CLR	EQU  01111111b	; To 'AND' with, for clear of powerfail circ.
  				;
				;-----------------------------------------------



;-------------------------------------------------------------------------------
; 6.6.4  Backplane control (function control port) and
;	 board type informations
;-------------------------------------------------------------------------------
;
;	Backplane control:
;	------------------
;	All (new for ASB 150 02) device cards connections to the backplane
;	bus and the restart of RP are controlled by central software.
;
;	For details see 1/1056-ASB 150 02     Here a brief summary:
;
;	The CP is connected with all cards through 4 wires in the backplane.
;	3 wires from CP to all cards and one wire from cards to CP.
;
;	FCD,	Function control data, 8 bit in serial form:
;		First card address bit 5,4,3,2,1,0 then function code bit 1,0
;
;	FCC,	Function control clock:
;		Low --> high transition when data bit (FCD) is valid.
;
;	FCE,	Function control enable:
;		Low when the function shall be executed on the addr. card.
;
;	SENSE,	To read back information from addressed card, data valid
;		after FCE is set high.
;
;	The function codes:
;	-------------------
FCD.OFF	  EQU	00b  ;	FC0: Switch off addressed card from busses and reset 
		     ;	the RP on the card. SENSE = 0 indicates 'some error'.
		     ;
FCD.ON	  EQU	01b  ;	FC1: Switch on addressed card to backplane busses.
                     ;	SENSE = 0 indicates 'operation succeded'
		     ;
FCD.ONQ	  EQU	10b  ;	FC2: Test addressed card. (question of on?)
		     ;	SENSE = 0 indicates 'the card is switched on'
		     ;
FCD.PRESQ EQU	11b  ;	FC3; Test addressed card. (question of present?)
		     ;	SENSE = 0 indicates 'there is a card on the position'
;
;	The function control wires are controlled by port 'PORT$FC':
;
;	Bit 0:	Write FCD (data)
;	Bit 1:	Write FCC (clock, data stores at low to high transition)
;	Bit 2:	Write FCE This bit is inverted in HW (enable=1, disable=0)
;	Bit :	
;	Bit 7:	Read SENSE from card.
;
;-------------------------------------------------------------------------------
;
; Board type information:
; -----------------------
;	This program must be able to run on different version on CPU-D/E board.
;	The type of the board is used by OS to handle the differences in the
;	hardware:
;	The board type is read from bit 5 and 6 in port 'PORT$FC':
;
;	Bit 	6,5,4:
;
; CPU-D		1 1 1	ROF 157 5118/1 PORT$MAPE uses bit 5 for E2-write,
;						 32 maps for E1/E2.
;
; CPU-D2	0 0 1	ROF 157 5118/2 PORT$MAPE uses bit 6 for E2-write,
;						 32 maps for E1/E2.
; CPU-D3	0 1 1	ROF 157 5118/3 PORT$MAPE uses bit 6 for E2-write,
;						 32 maps for E1/E2 and
;						 32 additional maps of
;						    battery backed RAM.
; CPU-D4	0 1 0	ROF 157 5124/1
;
; CPU-D5	1 0 0	ROF 157 5124/2
;
;		See PORT$MAPE for details.
;
;-------------------------------------------------------------------------------
				;
PORT$FC		EQU  0DBA0h	; Address for function control port.
				;
FC.DATA		EQU  00000001b	; To 'AND' with shifted data. Selects data,
				; set clock low and no 'enable'.
				;
FC.CLOCK	EQU  00000010b	; To 'OR' with shifted data. Sets clock wire
				; high. (does clock valid data)
				;
FC.ENABLE	EQU  00000100b	; To 'OR' with shifted data. This high level
				; sets enable wire to low in backplane.
				; (activates the clocked data in RP)
				;
FCMASK.SENSE	EQU  10000000b	; Mask to read the SENSE-wire.
				;
				;--------------------------------
FCMASK.BTYPE	EQU  01110000b	; Mask to read board type
				;--------------------------------
FC.BT5118.1	EQU  01110000b	; Board type ROF 157 5118/1, CPU-D
FC.BT5118.2	EQU  00010000b	; Board type ROF 157 5118/2, CPU-D2
FC.BT5118.3	EQU  00110000b  ; Board type ROF 157 5118/3, CPU-D3
FC.BT5124	EQU  00100000b	; Board type ROF 157 5124,   CPU-D4
FC.BT5124.2	EQU  01000000b	; Board type ROF 157 5124.2, CPU-D5
;		EQU  01010000b	; not used
;		EQU  00000000b	; not used
;		EQU  01100000b	; not used
				;
				;-----------------------------------------------
  
;-------------------------------------------------------------------------------
; 6.6.5  Switch circuit, handled by OU (PCM-Channel handler).
;-------------------------------------------------------------------------------
;
;	The switch and multiparty circuit uses 4 addresses for control
;	of the switch circuit.
;
;	The CPU-D/E card is ready for 2 switch circuits.
;
;	Here are only the first address of each switch declared as a 
;	port. Complete addressing (redefining of this port-symbols)
;	must be done in the application-block data declarations.
;
;-------------------------------------------------------------------------------
				;
PORT$SX1	EQU	0DBC0h	; First switch, always included
PORT$SX2	EQU	0DBC8h	; Secondary switch, optional
				;
				; SOME SYSTEM COMMON SWITCH DATA
				; -------------------------------
MPPQNT		EQU	64	; Quantity of Multi Party Ports within switch
MPPHIGH		EQU 	MPPQNT-1; Higest port number (lowest= 0)
				;
CNFQNT		EQU	21	; Quantity of conference possibilities
CNFHIGH		EQU 	CNFQNT-1; Higest conference number (lowest= 0)
				;
  				;-----------------------------------------------

;-------------------------------------------------------------------------------
; 6.6.6  Breakpoint ports (dummies, no circuits in hardware)
;-------------------------------------------------------------------------------
;
;  Port-addresses to be used as central breakpoints.
;  The operating system does a write on these addresses at below
;  specified functions. 
;  The address and databus can be used for conditional trigging of
;  the emulator when testing the system.
;
;-------------------------------------------------------------------------------
				;
PORT$JOBENTER  	EQU 0DBE0h	;  8 bytes reserved for job-enter.
PORT$JOBEXIT   	EQU 0DBE8h	;  8 bytes reserved for job-exit.
;              	EQU 0DBF0h	;  14 bytes spare.
PORT$OSWARNING 	EQU 0DBFEh	;  2 bytes reserved for os.warning.
				;
 				;-----------------------------------------------


;-------------------------------------------------------------------------------
; 6.6.7  Bitmasks for OS.CALL QSWITCH (read of input ports from SP and CP).
;-------------------------------------------------------------------------------
;
;	The switches are read by routine OS.CALL QSWITCH,
;	here are defined some bit-mask symbols.
;
;	Bit 0-4 are from a port in SP
;	Bit 5-6 are from PORT$INOUT in CP see chapter 6.6.3
;
;		Function:		   		Use:
;
;	Bit 0:	1= Switch K2 on				Used by OM
;	Bit 1:	1= Switch K1 on				Used by OM
;	Bit 2:	1= Installation strap inserted.		Coldstart
;	Bit 3:	1= External alarm			Used by OM
;	Bit 4:	1= Strap 2a22-2c22, SPARE inserted	-- spare --
;
;	Bit 5:	1= Strap 2a24-2c24, TST-0 inserted	OS test-mode
;	Bit 6:	1= Strap 2a26-2c26, TST-1 inserted	SU test-mode
;	Bit 7:	--
;
;-------------------------------------------------------------------------------
					;
SWMASK.K2	EQU  00000001b		; 
SWMASK.K1	EQU  00000010b		; 
SWMASK.COLD	EQU  00000100b		; 
SWMASK.ALARM	EQU  00001000b		; 
SWMASK.SPARE	EQU  00010000b		; spare
					;
SWMASK.TST0	EQU  INMASK.TST0	; Strap to read 'OS in test-mode'
SWMASK.TST1	EQU  INMASK.TST1	; Strap to read 'SU in test-mode'
  					;
					;---------------------------------------



        STITLE     '7. PROGRAM MAP HEADER'
;
;-------------------------------------------------------------------------------
; 7.    PROGRAM MAP HEADER
;-------------------------------------------------------------------------------
;
;       Program map header is placed at lowest address in the program
;       area for each map, description see REF-SYSMANUAL-3.DES.
;
;	Here are the program map header and the beginning of the
;       init routine table and other program map header tables are defined.
;
;-------------------------------------------------------------------------------

;-------------------------------------------------------------------------------
; 7.1   MAP HEADER OFFSETS
;-------------------------------------------------------------------------------
		    ;
PMHCSUM   EQU   0   ; (__)    2 Bytes, checksum
PMHCSUMC  EQU   2   ; (__)    2 Bytes, checksum correction
PMHCHK1   EQU   4   ; (__)    2 Bytes, check code 1   CHKCODE1
PMHCHK2   EQU   6   ; (__)    2 Bytes, check code 2   CHKCODE2
PMHDOC    EQU   8   ;                  Document number starts here, model:
                    ;                  '255/  3/ABC 123 4567/99 PA12 '
PMHDCP    EQU   8   ; (255/)  4 Bytes, Decimal class prefix, mapnumber string
PMHPRE    EQU  12   ; (  3/)  4 Bytes, Prefix, release number string.
PMHABC    EQU  16   ; (ABC )  4 Bytes, ABC-class string.
PMHBAS    EQU  20   ; (123 )  4 Bytes, Basic number string.
PMHNUM    EQU  24   ; (4567)  4 Bytes, Sequence number string.
PMHSUF    EQU  28   ; (/99 )  4 Bytes, Suffix, version number string.
PMHREV    EQU  32   ; (PA12)  4 Bytes, Revision string.
;         EQU  36   ; (_)     1 Byte,  1 ascii space (SPACE1)
PMHEOT    EQU  37   ; (_)     1 Byte,  Document number string ends here (EOT)
; PMH--   EQU  38   ; (__)    2 Bytes, spare
PMHNUMP   EQU  40   ; (_)     1 Byte,  Program map number.(0-63, 255=Central)
PMHNUMD   EQU  41   ; (_)     1 Byte,  Ram map number MDATA, buffers. (0-15)
PMHMREQ   EQU  42   ; (__)    2 Bytes, Totally requirement of ram in MDATA-
                    ;                  class for all programs within the map.
; PMH--   EQU  44   ; (____)  4 Bytes, spare.
                    ;
		    ;
; Pointers to header tables below here, the pointer points at a one character
; of ascii code (abbreviation for the classname) preciding the actual table. 
; The table is placed direct after this data byte.
		    ;
PMHINIT   EQU  48   ; (__)    2 Bytes, pointer to INIT table 
PMHJOBS   EQU  50   ; (__)    2 Bytes, pointer to JOBSIGNAL table 
PMHREP    EQU  52   ; (__)    2 Bytes, pointer to REPORT table
PMHSUR    EQU  54   ; (__)    2 Bytes, pointer to SURDY table
; PMH--   EQU  56   ; (__)    2 Bytes, spare
; PMH--   EQU  58   ; (_____) 5 Bytes, spare
PMHPADM   EQU  63   ; (_)     1 Byte,  Identifier for product administrative
;                   ;         information (reference for LZY- or RYS-numbers)
		    ;
		    ;-----------------------------------------------------------


;-------------------------------------------------------------------------------
; 7.2   PRODUCT ADMINISTRATIVE DATA
;-------------------------------------------------------------------------------
			;-------------------------------------------------------
 			; IDENTIFIERS FOR PRODUCT ADMINISTRATIVE INFORMATION
			;
 			; The identifiers are used in header at offset 
			; PMHPADM to declare type of information in the
			; field.
			; ------------------------------------------------------
			;
NOREF	EQU	0	; No information is inluded in any header. 
			; This value is used in previous revisions without 
			; info, as R3 - R4.
			;
RYSREF	EQU	1	; Ascii strings with RYS-product number for the
			; EPROM follows. (Only in one header in each EPROM)
			;
LZYREF	EQU	2	; Ascii strings with LZY- and RYS-product numbers 
			; for the whole program package are added to the 
			; mapheader. (Only in one map in whole package)
			;
ENDREF	EQU	EOT	; End of prod. adm. info field. Also used as identi-
			; fier for headers without this field.
			;
			;-------------------------------------------------------
			; STRING LENGTH
			;-------------------------------------------------------
PADMLEN EQU	20	; Length each LZY- or RYS-string in the field.
  			;-------------------------------------------------------


;-------------------------------------------------------------------------------
; 7.3   HEADER AND TABLE RESERVATIONS
;-------------------------------------------------------------------------------
        IF   DEF(SYASMFLG)
	IF DEF(PRE_MACASM)
MAPHEAD	SET	1
        INCLUDE 'system.def'
        
        GLOBAL	MAPNUMPROG1
        GLOBAL	MAPNUMPROG2
        ENDIF         ; DEF(PRE_MACASM)

  RESUME  SYSTEMH

;-------------------------------------------------------------------------------
		      ;
  WORD    CHECKSUM    ; (__)   Check sum
  WORD    CHECKSUMC   ; (__)   Check sum correction
  WORD    CHKCODE1    ; (__)   Check code 1
  WORD    CHKCODE2    ; (__)   Check code 2
                      ;        ---------------- Document number string -----+
                      ;                      'xxx/ xx/CXC xxx xxxx/xx PAxx '|
 	IF \DEF(PRE_MACASM) ;						    |
  LONG    SSDCP       ; (xxx/) Decimal class prefix, MAPNUMBER.             |
  LONG    SSPRE       ; ( xx/) Prefix, RELEASE NUMBER                       |
  LONG    SSABC       ; (CXC ) ABC-class                                    |
  LONG    SSBAS       ; (xxx ) Basic number                                 |
  LONG    SSNUM       ; (xxxx) Sequence number                              |
  LONG    SSSUF       ; (/xx ) Suffix, VERSION NUMBER.                      |
  LONG    SSREV       ; (PAxx) Revision                                     |
	ELSE          ; \DEF(PRE_MACASM)				    |
  ASCII ' '	      ;							    |
  BYTE	MAPNUMPROG1   ; (xx)  Decimal class prefix1 (set by link)	    |
  BYTE	MAPNUMPROG2   ; (x/)  Decimal class prefix2 (set by link)	    |
  ASCII '/'	      ;							    |
  ASCII	HEADSTRING    ; defined symbol  in system.def			    |
  ASCII	MARKETSTRING  ; defined symbol  in system.def			    |
  ASCII	NOIRSTRING    ; Revision 'NOIR'					    |
	ENDIF         ; \DEF(PRE_MACASM)				    |
  BYTE    SPACE1      ; (_)    Ascii space                                  |
  BYTE    EOT         ; (_)    String end  ---------------------------------+
  WORD    0           ; (__)   Spare
  BYTE    MAPNUMPROG  ; (_)    Program map number  (255 (FFh) = central map)
  BYTE    MAPNUMDATA  ; (_)    Data map number for MDATA (FFh= nonmapped)
  WORD    M.DATAREQ   ; (__)   Totally requirements of MDATA-bytes
  WORD    0FFFFh, 0000h  ; (____) PROM checksum and correctioncode
                      ;        only used in Maps 0, 32, 64
                      ;        written by Promtool (PC Version)
		      ;
  WORD    INIT_TAB    ; (__)   Init routine tbl ptr
  WORD    JOB_TAB     ; (__)   Job signal table ptr
  WORD    REP_TAB     ; (__)   Report table ptr
  WORD    SUR_TAB     ; (__)   SU ready table ptr
  WORD    0           ; (__)   Spare
  BYTE    0,0,0,0,0   ; (_____)Spare
	              ; Place for PMHPADM-identifier or endmark (ENDREF).
		      ;
;-------------------------------------------------------------------------------
;
; INIT ROUTINE TABLE     Each block which contents init routines are 
; ------------------     preparing their own init routine table lines.
;                        Here is just the beginning of the init table.
  RESUME SYSTEMN
INIT_TAB ASCII  'N'     ; The table label and one dummy byte (ASCII N):
;
;
;-------------------------------------------------------------------------------
;
; JOBSIGNAL TABLE        Each block which contents job routines are 
; ---------------        preparing their own job signal table lines.
;                        Here is just the beginning of the job signal table.
  RESUME SYSTEMO
JOB_TAB  ASCII  'O'     ; The table label and one dummy byte (ASCII O):
;
;-------------------------------------------------------------------------------
;
; REPORT TABLE           Each block which needs default e2base records are 
; ------------           preparing their own report table lines. 
;                        Here is just the beginning of the report table.
  RESUME SYSTEMR
REP_TAB  ASCII  'R'     ; The table label and one dummy byte (ASCII R):
;
;-------------------------------------------------------------------------------
;
; SU READY TABLE         Each block which contents SU ready job are 
; --------------         preparing their own SU ready table lines. 
;                        Here is just the beginning of the table.
  RESUME SYSTEMY
SUR_TAB  ASCII  'Y'     ; The table label and one dummy byte (ASCII Y):
;
        ENDIF           ; (SYASMFLG)
  			;
			;-------------------------------------------------------


;-------------------------------------------------------------------------------
; 7.4   ENDMARK FOR HEADER, TABLES AND MDATA
;-------------------------------------------------------------------------------
				;
        IF   DEF(SYASMFLG)	;
				;
  RESUME       SYSTEMHH		;
  BYTE   ENDREF               	; End of header (end of prod. adm. information)
				;
				;
				;
  RESUME       SYSTEMNN       	; END OF INIT ROUTINE TABLE
  INITEND			;
				;
				;
  RESUME       SYSTEMOO       	; END OF JOB TABLE
  JOBSIGNALEND			;
				;
				;
  RESUME       SYSTEMRR       	; END OF REPORT TABLE
  REPORTEND			;
				;
				;
  RESUME       SYSTEMYY       	; END OF SU READY TABLE
  SUREADYEND			;
				;
				;

; END OF MDATA        One byte is reserved to give an endmark after the
; ------------        MDATA reservations for a program map, the value is 
;                     given in the program map header and used by OS when 
;                     allocating memory for the program map.
		      ;
  RESUME    SYSTEMXX  ; Dummy reservation to give a value for MDATA-
M.DATAREQ   BLOCK  1  ; requirements.
		      ;
        ENDIF         ; (SYASMFLG)
 		      ;
		      ;---------------------------------------------------------



        STITLE     '8. JOBSIGNALS'
;----------------------------------------------------------------------------
; 8.    JOBSIGNALS
;----------------------------------------------------------------------------
;       The jobsignal is a number to define (identify) a program module,
;       used as 'address' when sending messages.
;
;       The symbol is defined as two bytes data. That means that the
;       signal number is included. The SN is always defined as 0.
;
;       The high byte (ST) is also used by the operative system when
;       logging use of system common resources and when logging error,
;       (OS.BUFFER OS.TIMER OS.SEND OS.WARNING and OU.CHANNEL etc.)
;       To define system-init and job-exit-phase for this purpose,
;       two jobsignal values are excluded from the list (see below).
;       Simular rules apply for the first 64 values (see below)
;
;       Namerule:  ST.ffeee      ff =        Shortening of block name.
;                               eee =        Shortening of function name.
;---------------------------------------------------------------------------
;                 Value(hex)    ; Description
;-------------------------------;------------------------------
;                        0000   ; Not valid
;                               ;
;                     0000-3F00 ; Not used in central software, can be mixed 
;				; up with short IC-code for RP. (Card & Ind)
;				; This range is also locally used for 
;				; jobsignals (ST) in regional software.
;                               ;
;                               ; JOBSTLOW (lowest used jobsignal)
;                     4000-FB00 ; Valid jobsignals, note the constant
;                               ; JOBSTHIGH (highest used jobsignal)
;                               ;
;                     FC00-FD00 ; Not valid
;                     FE00-FF00 ; Not valid, can be mixed up with job identity
;                               ; for the system-init and job-exit phase.
;-------------------------------;---------------------------------------------

;----------------------------------------------------------------------------
; 8.1   LIMITS 
;----------------------------------------------------------------------------
;       The defined jobsignals below must have values within these limits.
;       Used when the jobsignal tables are reserved and handled.
                                
JOBSTLOW       EQU      040h    ; Lowest  used job-signal-type (ST)
                                ; 040h = lowest allowed in CP.

JOBSTHIGH      EQU      0FBh    ; Highest used job-signal-type (ST) 
                                ; 0FBh = highest allowed in CP.
 

                               


;;
;;----------------------------------------------------------------------------
;; 8.2   SURVEY OF JOBSIGNALS
;;----------------------------------------------------------------------------
;;
  PAGE
;  __!______00h______!______10h______!______20h______!______30h______!
;  0 !__ Not valid __!       /       !       /       !       /       !
;  1 !      /       /!      /       /!      /       /!      /       /!
;  2 !     /       / !     /       / !     /       / !     /       / !
;  3 !    /       /  !    /       /  !    /       /  !    /       /  !
;  4 !   /       /   !   /       /   !   /       /   !   /       /   !
;  5 !  /       /    !  /                            !  /       /    !
;  6 ! /       /     ! /     NOT ALLOWED TO USE      ! /       /     !
;  7 !/       /      !/                              !/       /      !
;  8 !       /       !        Normaly mixed up       !       /       !
;  9 !      /       /!       with card position     /!      /       /!
;  A !     /       / !        in short ID-code.    / !     /       / !
;  B !                                                               !
;  C !  This range is also reserved for 'ST' in regional software.   !
;  D !                                                               !
;  E ! /       /     ! /       /     ! /       /     ! /       /     !
;  F !/_______/______!/_______/______!/_______/______!/_______/______!
;    
;; __!______40h______!______50h______!______60h______!______70h______!
;; 0 !  (JOBSTLOW)   !               !    ST.OSTST   !    ST.CMBEG   !
;; 1 !               !               !    ST.OULQU   !    ST.EXMLT   !
;; 2 !               !  ST.ARPRG     !    ST.AAINP   !    ST.CABEG   !
;; 3 !_              !_ ST.ARINP     !_   ST.AABEG   !_   ST.CAINP   !
;; 4 !               !  ST.ACPRG     !    ST.DEBEG   !    ST.CAPRG   !
;; 5 !               !  ST.MGOCN     !    ST.DEINP   !    ST.TNINP   !
;; 6 !               !  ST.IPPRG     !    ST.DEPRG   !    ST.EXLNR   !
;; 7 !_              !_ ST.MGREC     !_   ST.DEE2H   !_   ST.EXTOG   !
;; 8 !               !  ST.CBPRG     !    ST.CTBEG   !    ST.MCINP   !
;; 9 !               !  ST.ROPNR0    !    ST.CTINP   !    ST.LRBEG   !
;; A !               !  ST.ROPNR1    !    ST.EXBYP   !    ST.LRINP   !
;; B !_              !_ ST.ROPNR2    !_   ST.EXLOG   !_   ST.LRPRE   !
;; C !               !  ST.ROPNR3    !    ST.EXVPN   !    ST.NABEG   !
;; D !               !  ST.ROOWN     !    ST.EXSHD   !    ST.NAINP   !
;; E !               !  ST.CIBEG     !    ST.SUPRG   !    ST.EXCOB   !
;; F !_______________!__ST.CIINP_____!____ST.OSOUPRG_!____ST.E2PRG___!
;; 
  PAGE
;; __!______80h______!______90h______!______A0h______!______B0h______!
;; 0 !    ST.OSRTC   !    ST.CMINP   !    ST.EXBEG   !    ST.CBBEG   ! 0
;; 1 ! *) ST.OSSPO   ! *) ST.EUINP   ! *) ST.EXINP   !    ST.CBINP   ! 1
;; 2 !    ST.SXTRM   !    ST.EUPRG   !    ST.EXKTR   !    ST.TDBEG   ! 2
;; 3 !_   ST.SXMPU   !_   ST.TSBEG   !_   ST.EXPRG   !_   ST.TDPRG   ! 3
;; 4 !    ST.E2BEG   ! *) ST.TSINP   !    ST.EXCHG   !    ST.ROBEG   ! 4
;; 5 !    ST.E2INP   !    ST.TRSER   !    ST.EXDSP   !    ST.ROINP   ! 5
;; 6 !    ST.CEBEG   !    ST.OMPRG   !    ST.EXAUT   !    ST.ROPRG   ! 6
;; 7 !_   ST.SUINP   !_   ST.OMWRN   !_   ST.EXMAI   !_   ST.GHBEG   ! 7
;; 8 !    ST.SDINP   !    ST.OMBEG   !    ST.PRBEG   !    ST.GHINP   ! 8
;; 9 !    ST.SDDIR   !    ST.OMINP   !    ST.PRINP   !    ST.GHPRG   ! 9
;; A ! *) ST.SDIND   !    ST.OMCOM   !    ST.PRKDH   !    ST.ADBEG   ! A
;; B !_   ST.ALPRG   !_   ST.OMEPC   !_   ST.PRSPP   !_   ST.ADINP   ! B
;; C !    ST.ADTRA   !    ST.OMTST   !    ST.PRCMD   !    ST.ADPRG   ! C
;; D !    ST.CDSTA   !    ST.ALINP   !    ST.PRIND   !    ST.MUBEG   ! D
;; E !    ST.PABEG   !    ST.ALALR   ! *) ST.TRINP   !    ST.MUINP   ! E
;; F !____ST.PAPRG___!____ST.OMOWN___!____ST.TRPRG___!____ST.MUPRG___! F
;;
;; __!______C0h______!______D0h______!______E0h______!______F0h______!
;; 0 !    ST.GPBEG   !    ST.EXEXT   !    ST.MGBEG   !    ST.HOBEG   ! 0
;; 1 !    ST.GPINP   ! *) ST.RSINP   !    ST.MGINP   !    ST.HOINP   ! 1
;; 2 !    ST.GPPRG   !    ST.CLPRG   !    ST.MGPRG   !    ST.HOPRG   ! 2
;; 3 !_   ST.CDBEG   !_   ST.COBEG   !_   ST.INBEG   !_   ST.PGBEG   ! 3
;; 4 !    ST.CDINP   !    ST.COINP   !    ST.ININP   !    ST.PGINP   ! 4
;; 5 !    ST.CDPRG   !    ST.COPRG   !    ST.INPRG   !    ST.PGPRG   ! 5
;; 6 !    ST.TJOB0   !    ST.BIBEG   !    ST.ANBEG   !    ST.REBEG   ! 6
;; 7 !_   ST.TJOB1   !_   ST.BIINP   !_   ST.ANINP   !_   ST.REINP   ! 7
;; 8 !    ST.TJOB2   !    ST.BIPRG   !    ST.ANPRG   !    ST.REPRG   ! 8
;; 9 !    ST.VPBEG   !    ST.OPBEG   !    ST.VMBEG   !    ST.BISIL   ! 9
;; A !    ST.VPINP   ! *) ST.OPINP   ! *) ST.VMINP   !    ST.LSINP   ! A
;; B !_   ST.VPPRG   !_   ST.OPPRG   !_   ST.VMPRG   !_*)_ST.EDINP___! B
;; C !    ST.DIBEG   !    ST.OPQUE   !    ST.VMERA   !   Not valid   ! C
;; D !    ST.DIINP   !    ST.CLIOP   !    ST.VMSUP   !   Not valid   ! D
;; E !    ST.DIPRG   !    ST.FNINP   !    ST.CLINP   !   Not valid   ! E
;; F !____ST.DIE2H___!____ST.FNPRG___!____ST.ACINP___!__ Not valid __! F
;;    *) CARD and IND are normally used by these Jobsignal inputs
  PAGE
;----------------------------------------------------------------------------
; 8.3   JOBSIGNAL DEFINITIONS (global)
;----------------------------------------------------------------------------
        IF      DEF(SYASMFLG)
;RBEG,JOBSIGNALS,SYDEF
;-------------------------------;------------------------------
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------
;                               ;--------------------------------
;       ---              04000h ; --   Lowest allowed, see above.
                                ;--------------------------------
 SYDEF	ST.ARPRG      ,  05200h ;   AR - Auto Redial prog. input
 SYDEF	ST.ARINP      ,  05300h ;   AR - Auto Redial main input
 SYDEF	ST.ACPRG      ,  05400h ;   AC - Accout code, programming
 SYDEF	ST.MGOCN      ,  05500h ;   MG - OutCall Notification
 SYDEF	ST.IPPRG      ,  05600h ;RP IP - Programming input
 SYDEF	ST.MGREC      ,  05700h ;   MG - Conversation Recording
 SYDEF	ST.CBPRG      ,  05800h ;   CB - Call Back, programming
 SYDEF	ST.ROPNR0     ,  05900h ;   RO - Private Network Router 0
 SYDEF	ST.ROPNR1     ,  05A00h ;   RO - Private Network Router 1
 SYDEF	ST.ROPNR2     ,  05B00h ;   RO - Private Network Router 2
 SYDEF	ST.ROPNR3     ,  05C00h ;   RO - Private Network Router 3
 SYDEF	ST.ROOWN      ,  05D00h ;   RO - Own Location
 SYDEF	ST.CIBEG      ,  05E00h ;   CI - Caller List Prog. input
 SYDEF	ST.CIINP      ,  05F00h ;   CI - Caller List main input
 SYDEF	ST.OSTST      ,  06000h ;   OS - Interface for test tool WILMER
 SYDEF  ST.OULQU      ,  06100h ;   OU - The Load regulation QUeue
 SYDEF  ST.AAINP      ,  06200h ;   AA - Automated Attendant, main input
 SYDEF  ST.AABEG      ,  06300h ;   AA - Automated Attendant, init. and prog.
 SYDEF  ST.DEBEG      ,  06400h ;   DI - Begin, initialisation
 SYDEF  ST.DEINP      ,  06500h ;   DI - Normal input
 SYDEF  ST.DEPRG      ,  06600h ;   DI - Programming
 SYDEF  ST.DEE2H      ,  06700h ;   DI - E2-data interface
 SYDEF  ST.CTBEG      ,  06800h ;   CT - Startup, Programming
 SYDEF  ST.CTINP      ,  06900h ;RP CT - Main input
 SYDEF  ST.EXBYP      ,  06A00h ;   EX - Bypassing Call Diversion
 SYDEF  ST.EXLOG      ,  06B00h ;   EX - Logon/off of Slave 
 SYDEF  ST.EXVPN      ,  06C00h ;   EX - Virtual private networking
 SYDEF  ST.EXSHD      ,  06D00h ;   EX - Shutdown input
 SYDEF  ST.SUPRG      ,  06E00h ;   SU - Programming
 SYDEF  ST.OSOUPRG    ,  06F00h ;   OS & OU - Programming
  PAGE
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------
 SYDEF	ST.CMBEG      ,	 07000h	;   CM - Call metering, progr. and  init.
 SYDEF  ST.EXMLT      ,  07100h ;   EX - Multi Line Terminal
 SYDEF  ST.CABEG      ,  07200h ;   CA - Cost, programming and initialisation
 SYDEF  ST.CAINP      ,  07300h ;   CA - Cost Analysis, main input
 SYDEF  ST.CAPRG      ,  07400h ;   CA - Cost, programming input
 SYDEF  ST.TNINP      ,  07500h ;   TN - Test number, main input
 SYDEF  ST.EXLNR      ,  07600h ;   EX - Last number redial, main input
 SYDEF  ST.EXTOG      ,  07700h ;   EX - Toggle functions, main input
 SYDEF  ST.MCINP      ,  07800h ;   MC - Traffic input
 SYDEF  ST.LRBEG      ,  07900h ;   LR - initialisation
 SYDEF  ST.LRINP      ,  07A00h ;   LR - Traffic input
 SYDEF  ST.LRPRE      ,  07B00h ;   LR - 
 SYDEF  ST.NABEG      ,  07C00h ;   NA - Programming and initialization
 SYDEF  ST.NAINP      ,  07D00h ;   NA - Number Analysis
 SYDEF  ST.EXCOB      ,  07E00h ;   EX - Common Bell Extension
 SYDEF  ST.E2PRG      ,  07F00h ;   E2 - Programming input

 SYDEF  ST.OSRTC      ,  08000h ;   OS - Real time clock handler
 SYDEF  ST.OSSPO      ,  08100h ;RP OS - OSHWI, Send to RP (SP-out)
;                               ;        (must be 8100h this value is
;                               ;        defied in the testcard (TSTX).
 SYDEF  ST.SXTRM      ,  08200h ;   SX - Switch, transmission
 SYDEF  ST.SXMPU      ,  08300h ;   SX - Switch, Multi party
                                
 SYDEF  ST.E2BEG      ,  08400h ;   E2 - Begin, initialisation
 SYDEF  ST.E2INP      ,  08500h ;   E2 - Normal input

 SYDEF  ST.CEBEG      ,  08600h ;   CE - Convert E2data, R1->R2, R2->R3,..

 SYDEF  ST.SUINP      ,  08700h ;RP SU - Input for all signals
  PAGE
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------
 SYDEF  ST.SDINP      ,  08800h ;   SD - Distribution of SEIZ-messages
 SYDEF  ST.SDDIR      ,  08900h ;   SD - Distribution on directory number
 SYDEF  ST.SDIND      ,  08A00h ;   SD - Input for message from RP:s

 SYDEF  ST.ALPRG      ,  08B00h ;   AL - Alarm, programming
 SYDEF  ST.ADTRA      ,  08C00h ;   AD - Abbrev. dial traffic-input
 SYDEF  ST.CDSTA      ,  08D00h ;   CD - ACD statistics
 
 SYDEF  ST.PABEG      ,  08E00h ;   PA - Begin, initialisation
 SYDEF  ST.PAPRG      ,  08F00h ;   PA - Programming

 SYDEF  ST.CMINP      ,  09000h ;   CM - Standard input
 SYDEF  ST.EUINP      ,  09100h ;   EU - Standard input
 SYDEF  ST.EUPRG      ,  09200h ;   EU - Programming
 SYDEF  ST.TSBEG      ,  09300h ;   TS - Begin, initialisation 
 SYDEF  ST.TSINP      ,  09400h ;   TS - Standard input  
 SYDEF  ST.TRSER      ,  09500h ;   TR - Service input
 SYDEF  ST.OMPRG      ,  09600h ;   OM - Programming  
 SYDEF  ST.OMWRN      ,  09700h ;   OM - Warning ram-buffer examine. 
 SYDEF  ST.OMBEG      ,  09800h ;   OM - Begin, initialisation.
 SYDEF  ST.OMINP      ,  09900h ;   OM - RP-communication, etc.
 SYDEF  ST.OMCOM      ,  09A00h ;   OM - Communication with PR
 SYDEF  ST.OMEPC      ,  09B00h ;RP OM - Communication with PC and EPC
 SYDEF  ST.OMTST      ,  09C00h ;   OM - Test of instrument
 SYDEF  ST.ALINP      ,  09D00h ;   AL - Readout of alarm
 SYDEF  ST.ALALR      ,  09E00h ;   AL - Receive alarm
 SYDEF  ST.OMOWN      ,  09F00h ;   OM - Internal signalling.
  PAGE
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------
 SYDEF  ST.EXBEG      ,  0A000h ;   EX - Begin, initialisation
 SYDEF  ST.EXINP      ,  0A100h ;   EX - Traffic input
 SYDEF  ST.EXKTR      ,  0A200h ;   EX - Key translater
 SYDEF  ST.EXPRG      ,  0A300h ;   EX - Programming
 SYDEF  ST.EXCHG      ,  0A400h ;   EX - Traffic input for programming
 SYDEF  ST.EXDSP      ,  0A500h ;   EX - Display information
 SYDEF  ST.EXAUT      ,  0A600h ;   EX - Authority codes
 SYDEF	ST.EXMAI      ,  0A700h ;   EX - External voice mail

 SYDEF  ST.PRBEG      ,  0A800h ;   PR - Begin, initialisation
 SYDEF  ST.PRINP      ,  0A900h ;   PR - Traffic input
 SYDEF  ST.PRKDH      ,  0AA00h ;   PR - Keyboard and display handler
 SYDEF  ST.PRSPP      ,  0AB00h ;   PR - Support
 SYDEF  ST.PRCMD      ,  0AC00h ;   PR - Command
 SYDEF  ST.PRIND      ,  0AD00h ;   PR - Individual programming
 SYDEF  ST.TRINP      ,  0AE00h ;RP TR - Traffic input
 SYDEF  ST.TRPRG      ,  0AF00h ;   TR - Programming

 SYDEF  ST.CBBEG      ,  0B000h ;   CB - Begin, initialisation
 SYDEF  ST.CBINP      ,  0B100h ;   CB - Traffic input

 SYDEF  ST.TDBEG      ,  0B200h ;   TD - Begin, initialisation
 SYDEF  ST.TDPRG      ,  0B300h ;   TD - Programming

 SYDEF  ST.ROBEG      ,  0B400h ;   RO - Begin, initialisation
 SYDEF  ST.ROINP      ,  0B500h ;   RO - Traffic input
 SYDEF  ST.ROPRG      ,  0B600h ;   RO - Programming

 SYDEF  ST.GHBEG      ,  0B700h ;   GH - Begin, initialisation
 SYDEF  ST.GHINP      ,  0B800h ;   GH - Traffic input
 SYDEF  ST.GHPRG      ,  0B900h ;   GH - Programming
  PAGE
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------
 SYDEF  ST.ADBEG      ,  0BA00h ;   AD - Begin, initialisation
 SYDEF  ST.ADINP      ,  0BB00h ;   AD - Traffic input
 SYDEF  ST.ADPRG      ,  0BC00h ;   AD - Programming

 SYDEF  ST.MUBEG      ,  0BD00h ;   MU - Begin, initialisation
 SYDEF  ST.MUINP      ,  0BE00h ;   MU - Traffic input
 SYDEF  ST.MUPRG      ,  0BF00h ;   MU - Programming

 SYDEF  ST.GPBEG      ,  0C000h ;   GP - Begin, initialisation
 SYDEF  ST.GPINP      ,  0C100h ;   GP - Traffic input
 SYDEF  ST.GPPRG      ,  0C200h ;   GP - Programming

 SYDEF  ST.CDBEG      ,  0C300h ;   CD - ACD Begin, initialisation
 SYDEF  ST.CDINP      ,  0C400h ;   CD - ACD Traffic input
 SYDEF  ST.CDPRG      ,  0C500h ;   CD - ACD Programming

 SYDEF  ST.TJOB0      ,  0C600h ;RP TJ - Test job, handles CPJOB from TSTX
 SYDEF  ST.TJOB1      ,  0C700h ;   TJ - Test job, factory testning and others
 SYDEF  ST.TJOB2      ,  0C800h ;   TJ - Test job, factory testning and others

 SYDEF  ST.VPBEG      ,  0C900h ;   VP - Begin, initialisation
 SYDEF  ST.VPINP      ,  0CA00h ;   VP - Traffic input
 SYDEF  ST.VPPRG      ,  0CB00h ;   VP - Programming

 SYDEF  ST.DIBEG      ,  0CC00h ;   DI - Begin, initialisation
 SYDEF  ST.DIINP      ,  0CD00h ;   DI - Normal input
 SYDEF  ST.DIPRG      ,  0CE00h ;   DI - Programming
 SYDEF  ST.DIE2H      ,  0CF00h ;   DI - E2-data interface
  PAGE
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------
 SYDEF  ST.EXEXT      ,  0D000h ;   EX - Individual external diversion
 SYDEF  ST.RSINP      ,  0D100h ;   RS - Register signal

 SYDEF	ST.CLPRG      ,	 0D200h ;   CL - Programming

 SYDEF  ST.COBEG      ,  0D300h ;   CO - Begin, initialisation
 SYDEF  ST.COINP      ,  0D400h ;   CO - Traffic input
 SYDEF  ST.COPRG      ,  0D500h ;   CO - Programming

 SYDEF  ST.BIBEG      ,  0D600h ;   BI - Begin, initialisation
 SYDEF  ST.BIINP      ,  0D700h ;   BI - Traffic input
 SYDEF  ST.BIPRG      ,  0D800h ;   BI - Programming

 SYDEF  ST.OPBEG      ,  0D900h ;   OP - Begin, initialisation
 SYDEF  ST.OPINP      ,  0DA00h ;   OP - Traffic input
 SYDEF  ST.OPPRG      ,  0DB00h ;   OP - Programming
 SYDEF  ST.OPQUE      ,  0DC00h ;   OP - Queue, traffic input

 SYDEF  ST.CLIOP      ,  0DD00h ;   CL - I/O-port handler

 SYDEF  ST.FNINP      ,  0DE00h ;   FN - Traffic input
 SYDEF  ST.FNPRG      ,  0DF00h ;   FN - Programming

 SYDEF  ST.MGBEG      ,  0E000h ;   MG - Begin, initialisation
 SYDEF  ST.MGINP      ,  0E100h ;   MG - Traffic input
 SYDEF  ST.MGPRG      ,  0E200h ;   MG - Programming

 SYDEF  ST.INBEG      ,  0E300h ;   IN - Begin, initialisation
 SYDEF  ST.ININP      ,  0E400h ;   IN - Traffic input
 SYDEF  ST.INPRG      ,  0E500h ;   IN - Programming

 SYDEF  ST.ANBEG      ,  0E600h ;   AN - Begin, initialisation
 SYDEF  ST.ANINP      ,  0E700h ;   AN - Traffic input
 SYDEF  ST.ANPRG      ,  0E800h ;   AN - Programming
  PAGE
;       Jobsignal     , Value   ; Description
;-------------------------------;------------------------------

 SYDEF  ST.VMBEG      ,  0E900h ;   VM - Begin, initialisation
 SYDEF  ST.VMINP      ,  0EA00h ;   VM - Traffic input
 SYDEF  ST.VMPRG      ,  0EB00h ;   VM - Programming
 SYDEF  ST.VMERA      ,  0EC00h ;   VM - Erase 
 SYDEF  ST.VMSUP      ,  0ED00h ;   VM - Supervision

 SYDEF  ST.CLINP      ,  0EE00h ;   CL - Input

 SYDEF  ST.ACINP      ,  0EF00h ;   AC - Traffic input

 SYDEF  ST.HOBEG      ,  0F000h ;   HO - Begin, initialisation
 SYDEF  ST.HOINP      ,  0F100h ;   HO - Traffic input
 SYDEF  ST.HOPRG      ,  0F200h ;   HO - Programming

 SYDEF  ST.PGBEG      ,  0F300h ;   PG - Begin, initialisation
 SYDEF  ST.PGINP      ,  0F400h ;   PG - Traffic input
 SYDEF  ST.PGPRG      ,  0F500h ;   PG - Programming

 SYDEF  ST.REBEG      ,  0F600h ;   RE - Begin, initialisation
 SYDEF  ST.REINP      ,  0F700h ;   RE - Traffic input
 SYDEF  ST.REPRG      ,  0F800h ;   RE - Programming

 SYDEF	ST.BISIL      ,  0F900h	;   BI - Silent intrusion
 SYDEF  ST.LSINP      ,  0FA00h	;   LS - Link supervision
                                ;---------------------------------
 SYDEF  ST.EDINP      ,  0FB00h ;   ED - Text editing for extensions
				; ---- Highest allowed, see above.
                                ;---------------------------------

				;-------------------------------------------
				; Declarations made for test tool WILMER
				; used for a translation of identifiers
				; of same class as the jobsignal (ST)
				; -------
;R SYDEF  JOB.INIT    ,  0FE00h	; Value used as identifier for any at 'init'.
;R SYDEF  JOB.EXIT    ,  0FF00h ; Value used as identifier for OS at job-exit 
 SYDEF  ST.OSINT      ,  0FF00h ; Used for OSDEB Functions, not as signal input
 				;--------------------------------------------
;REND (jobsignals)
        ENDIF   ; (SYASMFLG)
  PAGE
        STITLE     '9. INDIVIDUAL ADDRESS '
;----------------------------------------------------------------------------
; 9.    INDIVIDUAL ADDRESS (Hardware position / card & individual)
;----------------------------------------------------------------------------

;----------------------------------------------------------------------------
; 9.1   LIMITS
;----------------------------------------------------------------------------
CARDPOSQNT  EQU   64            ; Max quantity of possible card positions.  
CARDLOW     EQU   0             ; Lowest allowed card position.
CARDHIGH    EQU   CARDPOSQNT-1  ; Higest allowed card position.
;
INDNUMQNT   EQU	  255		; Max quantity of individuals at one card.
INDLOW      EQU   0             ; Lowest allowed individual number.
INDHIGH     EQU   INDNUMQNT-1   ; Higest allowed individual number.
INDHIGH.F1  EQU   15            ; Higest allowed individual number in format 1

;----------------------------------------------------------------------------
; 9.2   INDIVIDUAL ADDRESSES (Card & Ind)
;----------------------------------------------------------------------------
;RBEG,OTHERS
;				; Not defined addresses
				; ----------------------
CARD.NOD	EQU	0FFh	;   Card not defined, card= FF   
IND.NOD		EQU	0FFh	;RP Individual not defined, individual= FF
INDADDR.NOD	EQU	0FFFFh	;   Card=FF individual= FF

;REND (others)
  PAGE
        STITLE     '10. CARD GLOBAL MESSAGES'
;----------------------------------------------------------------------------
; 10.   CARD GLOBAL MESSAGES
;----------------------------------------------------------------------------
;       When sending card global messages to RP:s an attention code is used 
;       instead of card-position in the message.
;
;       The attention code describes a 'family' of messages.
;
;       The attention code is a 5-bit code, used in the CARD-position
;       in the message, there is one extra bit in same byte in the
;       message which have to be set (card global indicator). 
;	Use the constant RPGLOBAL and add/or it to the attentioncode.
;
;       Example:                          ; First prepare message in WREG
;                                         ; (message lengt = 7 in example)
;        LDA      RPGLOBAL+AT.RPCTRL      ; Make it global.
;        STA      @WRCARD
;        CLR      @WRIND                  ; No individual number.
;        OS.SEND  JQB,WREG,7,ST.OSSPO     ; Send it to RP
;
;---------------------------------------------------------------------------
;RBEG,OTHERS

RPGLOBAL	EQU	40h		;RP    (01000000b = 40h)

;REND (others)
  PAGE
;;----------------------------------------------------------------------------
;; 10.1  SURVEY OF ATTENTION CODES
;;----------------------------------------------------------------------------
;;
;;	Value:	 Symbol:	 Received by RP: (individual type TYPE.xxx)
;;      --------+-----00h-------+--------------------------------------------+
;;	00h	! AT.POLL	! All RP (poll sequence mark)
;;	01h	! AT.RPCTRL	! All RP
;;	02h	! AT.MULTPRES	! ELUC, ELUD 
;;	03h	! AT.LCD	! ELUC, ELUD
;;	04h	! AT.VOICEPAG	! ELUC, ELUD 
;;	05h	! AT.PESGLOBAL	! ELUD
;;	06h	! AT.TONEPAR	! ELUA, ELUC, ELUD
;;	07h	! -		! 
;;	08h	! AT.SYSPAR	! All RP that needs any SYSPAR-messages
;;	09h	! -		! 
;;	0Ah	! -		! 
;;	0Bh	! AT.STATEREP	! Any that need 'State report'
;;	0Ch	! AT.TEST	! TSTX (Test card)
;;	0Dh	! AT.CALENDAR	! used by ICCU, BTUB, VMU
;;	0Eh	! - 		! 
;;	0Fh	! - 		! 
;;	10h	! AT.ELUD	! ELUD 
;;	11h	! AT.ELUA	! ELUA 
;;	12h	! AT.ELUC	! ELUC 
;;	13h	! AT.ICCU2	! ICCU2
;;	14h	! AT.UPGRD	! RPs able to run remote FW upgrade
;;	15h	! -		! 
;;	16h	! -		! 
;;	17h	! -		! 
;;	18h	! -		! 
;;	19h	! -		! 
;;	1Ah	! -		! 
;;	1Bh	! -		! 
;;	1Ch	! -		! 
;;	1Dh	! -		!	 
;;	1Eh	! -		! 
;;	1Fh	! -		! 
;;	--------+---------------+------------------------------------------+


;---------------------------------------------------------------------------
; 10.2  ATTENTION CODE DEFINITIONS (global)
;----------------------------------------------------------------------------
        IF      DEF(SYASMFLG)
;RBEG,ATTCODES,SYDEF
;
;       Attention code , Value  ; Description
;-------------------------------;---------------------------------------
 SYDEF  AT.POLL        ,  00h   ;   Reserved for a Poll sequence mark 
 SYDEF  AT.RPCTRL      ,  01h   ;RP For control of all types of RP.
 SYDEF  AT.MULTPRES    ,  02h   ;RP For MULTPRES-messages
 SYDEF  AT.LCD         ,  03h   ;RP For LCD-information, instrument display.
 SYDEF  AT.VOICEPAG    ,  04h   ;RP For voice paging.
 SYDEF  AT.PESGLOBAL   ,  05h   ;RP For PESGLOBAL-message
 SYDEF  AT.TONEPAR     ,  06h   ;RP Tone data.
; SYDEF                ,  07h   ;   
 SYDEF  AT.SYSPAR      ,  08h   ;RP For messages with system parameters.
; SYDEF                ,  09h   ;   
; SYDEF                ,  0Ah   ;
 SYDEF  AT.STATEREP    ,  0Bh   ;RP For state reports to external units.
 SYDEF  AT.TEST        ,  0Ch   ;RP For test messages to TSTX-card.
 SYDEF	AT.CALENDAR    ,  0Dh	;RP For calendar messages
; SYDEF                ,  0Eh   ;
; SYDEF                ,  0Fh   ;
 SYDEF  AT.ELUD        ,  10h   ;RP Data for digital (DBC 600...) instruments.
 SYDEF  AT.ELUA        ,  11h   ;RP Data for analogue instruments.
 SYDEF  AT.ELUC        ,  12h   ;RP Data for digital (DBC 750...) instruments.
 SYDEF  AT.ICCU2       ,  13h   ;RP Data for cordless.
 SYDEF  AT.UPGRD       ,  14h   ;RP RPs able to run remote FW upgrade

;REND (attcodes)

 SYDEF  AT.LEDRING     ,  AT.MULTPRES  ;   (Alias for AT.MULTPRES)

        ENDIF   ; (SYASMFLG)
  PAGE
        STITLE     '11. INFORMATION CODES'
;----------------------------------------------------------------------------
; 11.   INFORMATION CODES
;----------------------------------------------------------------------------
;       Information codes is used in messages to define the message
;       and the type of data in the message.
;
;                  Value(hex) ; Description
;-----------------------------;-----------------------------------------
;                         00  ; Not valid, used for control of message-tables.
;                      01-DF  ; Common, for general use. Defined below.
;                      E0-FB  ; Reserved for special messages within a block.
;                      FC-FE  ; Reserved, not used.
;                         FF  ; Not valid, used for control of message-tables.
;-----------------------------;-----------------------------------------

;;--------------------------------------------------------------------------
;; 11.1   SURVEY OF INFORMATION CODES
;;--------------------------------------------------------------------------
   PAGE
;; __!______00h_______!______10h______!______20h______!______30h______!
;; 0 ! For table-ctrl ! E2ACK         ! PARKEND       ! INDDATAANSW   ! 0
;; 1 ! ABBRNOANSW     ! E2NAK         ! PARKIND       ! INDDATAQ      ! 1
;; 2 ! ABBRNOCOM      ! E2BASRD       ! CONINFO	      ! CATREAD       ! 2
;; 3 ! ABBRNOIND      ! E2BASRL       ! AUTHCODE      ! DIRCTRL       ! 3
;; 4 ! ACBACT         ! E2BASSZ       ! REROUTE       ! KEYANSW       ! 4
;; 5 ! BREAKINQ       ! E2BASWR       ! SAVENO        ! KEYQ          ! 5
;; 6 ! BREAKINNAK     ! E2RECRD       ! SPEECHCTRL    ! CTIFUNC       ! 6
;; 7 ! BREAKINACK     ! E2RECRL       ! PARKRING      ! PESGLOBAL     ! 7
;; 8 ! CONCTRL        ! E2RECSZ       ! TFRACK        ! LOUDSPCTRL    ! 8
;; 9 ! CONINIT        ! E2RECWR       ! TFRNAK        ! PARKCOM       ! 9
;; A ! CONREL         ! E2RD          ! TFRQ          !               ! A
;; B ! FUNCTCTRL      ! E2WR          ! CONDATAANSW   ! TRANSP        ! B
;; C !                ! E2BASSWAP     ! CONDATAQ      ! PRRD          ! C
;; D ! MULTPRES       ! TIMEOUT1      ! CONFACK       ! PRRDANSW      ! D
;; E ! NEWNO          ! TIMEOUT2      ! CONFNAK       ! PRWR          ! E
;; F ! TEXTSTRING     ! TIMEOUT3      ! CONFQ         ! PRWRANSW      ! F
;; 
;; __!______40h_______!______50h______!______60h______!______70h______!
;; 0 ! CARDREP        ! RPCTRL        ! CPICKUPCTRL   ! SEIZACD       ! 0
;; 1 !                ! RPJOB         ! BTCORDER      ! SEIZACK       ! 1
;; 2 ! SYSPAR         ! MEMEX         ! BTCPAR        ! SEIZACKREL    ! 2
;; 3 ! ACBCTRL        ! ADFUNCTION    !               ! SEIZBOOKED    ! 3
;; 4 ! E2RECORD       ! TESTTRACE     ! BTCSIGNAL     ! SEIZCALL      ! 4
;; 5 ! ECCOM          ! CALENDAR      ! MPCON         ! SEIZINTCOM    ! 5
;; 6 ! TEXTEDIT       ! RPJOBANSW     ! MPCONANSW     ! SEIZNAK       ! 6
;; 7 ! CPJOB          ! LCDPAR        ! MPREL         ! SEIZNAKRERO   ! 7
;; 8 ! IMPCTRL        ! LCDCTRL       ! LCRNUM        ! UPDCARD       ! 8
;; 9 ! SUPERV         ! LCDTEXTALL    ! NUMCONVERT    ! UPDIND        ! 9
;; A ! SUPERVANSW     ! LCDSCROLL     ! KSCDIGRDY     ! ACDINFO       ! A
;; B ! WARN           ! LCDWR         ! KSCDIGSEND    ! ACDCTRL       ! B
;; C ! KSCDIGREQ      ! MUCTRL        ! TONECTRL      ! SEIZDATACOM   ! C
;; D ! MICTRL         ! CICTRL        ! TONESEND      ! AUTHCAT       ! D
;; E ! KEYSEARCH      ! BLOCKINFO     ! TONEPAR       ! SURDY         ! E
;; F ! CONRELCTRL     ! TRSTATUS      ! TONERDY       ! REALTIME      ! F
     PAGE 
;; 
;; __!______80h_______!______90h______!______A0h______!______B0h______!
;; 0 ! DISPLAYCTRL    ! KEYCODE       ! TRANSM        ! COST          ! 0
;; 1 ! DISPLAYWR      ! KEYDATA       ! LINERR        ! SEIZLCR       ! 1
;; 2 !                ! KEYDATARES    ! STATEREP      ! SERVICE       ! 2
;; 3 !                !               ! REGCTRL       ! SISIG         ! 3
;; 4 ! GROUPCTRL      ! ELDTRANSIT    ! HOOKOFF       ! CONPTYNUM     ! 4
;; 5 ! GUEST          ! ELSTATE       ! HOOKON        ! TISIG         ! 5
;; 6 ! HOCILINPUT     ! PNRINFO       ! TONECON       ! VMUCTRLDATA   ! 6
;; 7 ! HOCILOUTPUT    ! ELCTRL        ! TONEREQ       ! VMUSEIZHD     ! 7
;; 8 ! VOICEPAGCTRL   ! LEDCTRL       ! TRTRANSIT     ! VMUORDER2     ! 8
;; 9 ! INSTRTYPE      ! LEDRING       ! E2STATUS      ! VMSEIZ        ! 9
;; A ! VMUSEIZ        ! NUMINFO       ! PGINFO        ! VMSEIZANSW    ! A
;; B ! VMUSEIZANSW    ! RINGCTRL      ! GUESTINFO     ! VMCTRL        ! B
;; C ! VMUDATA        ! ELPAR         ! MISTOCLR      ! OPINFO        ! C
;; D ! VMUDATAANSW    ! RINGSTOP      ! METER         ! OPRING        ! D
;; E ! VMUORDER       ! OMPCCOM       ! PCCTRL        ! DIGREQ        ! E
;; F ! VMUORDERANSW   ! OMPCCOMANSW   ! BTLSUP        ! QUEUEINFO     ! F
;;
;; __!______C0h_______!______D0h______!______E0h______!______F0h______!
;; 0 ! PRINIT         ! IPDATA        !_______________!_______________! 0
;; 1 ! PRCTRL         ! UPGRAD        !_______________!_______________! 1
;; 2 ! PRDATA         ! ACCTRL        !_______________!_______________! 2
;; 3 ! PRDATATRANSFER ! IPSIG         !_______________!_______________! 3
;; 4 ! 		      ! ARCTRL        !_______________!_______________! 4
;; 5 ! CILSERVICE     ! BREAKINCTRL   !_______________!_______________! 5
;; 6 ! CILCONDAT      ! CONFCTRL      !_______________!_______________! 6
;; 7 ! CILCONSTAT     ! TFRCTRL       !_______________!_______________! 7
;; 8 ! CILDIGSEND     ! LICFUNC       !_______________!_______________! 8
;; 9 ! CILCONREL      ! LCDTOG1       !_______________!_______________! 9
;; A ! EUSEIZ         ! LCDTOG2       !_______________!_______________! A
;; B ! EUCTRL         ! -             !_______________!_______________! B
;; C ! IOINIT         ! -             !_______________! Reserved      ! C
;; D ! IOCTRL         ! -             !_______________! Reserved      ! D
;; E ! IODATA         ! -             !_______________! Reserved,     ! E
;; F ! ALARMCTRL      ! TIMEOUT       !_______________! Table-control ! F
  PAGE
;---------------------------------------------------------------------------
; 11.2   INFORMATION CODE DEFINITIONS (global)
;----------------------------------------------------------------------------
        IF      DEF(SYASMFLG)

;    Information code , Value ; Description
;-----------------------------;-----------------------------------------
;RBEG,INFCODES,SYDEF
;                          0  ;   Not allowed
 SYDEF  ABBRNOANSW     , 001h ;   Abbreviated number answer
 SYDEF  ABBRNOCOM      , 002h ;   Common abbreviated number request
 SYDEF  ABBRNOIND      , 003h ;   Individual abbreviated number request
 SYDEF  ACBACT         , 004h ;   Automatic call back activate
 SYDEF  BREAKINQ       , 005h ;   Break-in question
 SYDEF  BREAKINNAK     , 006h ;   Break-in non acknowledgement
 SYDEF  BREAKINACK     , 007h ;   Break-in acknowledgement
 SYDEF  CONCTRL        , 008h ;   Connection control
 SYDEF  CONINIT        , 009h ;   Connection initiate
 SYDEF  CONREL         , 00Ah ;   Connection release
 SYDEF  FUNCTCTRL      , 00Bh ;   Function control
; SYDEF                 , 00Ch ;
 SYDEF  MULTPRES       , 00Dh ;RP Multiple presentation
 SYDEF  NEWNO          , 00Eh ;   New number  
 SYDEF  TEXTSTRING     , 00Fh ;   Teststring, request and answer
  PAGE
 SYDEF  E2ACK          , 010h ;   Ack message from E2
 SYDEF  E2NAK          , 011h ;   Nack message from E2
 SYDEF  E2BASRD        , 012h ;   Read an E2 base record
 SYDEF  E2BASRL        , 013h ;   Release an E2 base record
 SYDEF  E2BASSZ        , 014h ;   Ask for an E2 base record
 SYDEF  E2BASWR        , 015h ;   Write in an E2 base record
 SYDEF  E2RECRD        , 016h ;   Read an E2 record
 SYDEF  E2RECRL        , 017h ;   Release an E2 record
 SYDEF  E2RECSZ        , 018h ;   Ask for an E2 record
 SYDEF  E2RECWR        , 019h ;   Write in an E2 record
 SYDEF  E2RD           , 01Ah ;   Read E2 area
 SYDEF  E2WR           , 01Bh ;   Write in E2 area
 SYDEF  E2BASSWAP      , 01Ch ;   Swap ID-code between two base records
 SYDEF  TIMEOUT1       , 01Dh ;RP Required time has expired
 SYDEF  TIMEOUT2       , 01Eh ;RP Required time has expired
 SYDEF  TIMEOUT3       , 01Fh ;RP Required time has expired

 SYDEF  PARKEND        , 020h ;   Parking condition ended
 SYDEF  PARKIND        , 021h ;   Individual parking
 SYDEF  CONINFO        , 022h ;   Connection information
 SYDEF  AUTHCODE       , 023h ;   Authorization code
 SYDEF  REROUTE        , 024h ;   Reroute
 SYDEF  SAVENO         , 025h ;   Save number
 SYDEF  SPEECHCTRL     , 026h ;   Speech control
 SYDEF  PARKRING       , 027h ;   Parked call ringing on instrument.
 SYDEF  TFRACK         , 028h ;   Transfer acknowledgement
 SYDEF  TFRNAK         , 029h ;   Transfer non acknowledgement
 SYDEF  TFRQ           , 02Ah ;   Transfer question
 SYDEF  CONDATAANSW    , 02Bh ;   Answer at CONDATAQ
 SYDEF  CONDATAQ       , 02Ch ;   Obtain info. about the active connection
 SYDEF  CONFACK        , 02Dh ;   Ack answer at CONFQ
 SYDEF  CONFNAK        , 02Eh ;   Nack answer at CONFQ
 SYDEF  CONFQ          , 02Fh ;   Ask if conference is accepted
  PAGE
 SYDEF  INDDATAANSW    , 030h ;   Answer to individual data question
 SYDEF  INDDATAQ       , 031h ;   Individual data question
 SYDEF	CATREAD	       , 032h ;   Categories read request and answer
 SYDEF  DIRCTRL        , 033h ;   Directory book information
 SYDEF  KEYANSW        , 034h ;   Answer to KEYQ and KEYSEARCH
 SYDEF  KEYQ           , 035h ;   Ask for meaning of programmable key
 SYDEF  CTIFUNC        , 036h ;   Sent between CT and various other CP blocks
                              ;   to exchange data necessary for CTI
 SYDEF  PESGLOBAL      , 037h ;RP Contains information intended for
                              ;   client-application PES
 SYDEF  LOUDSPCTRL     , 038h ;   Loudspeaking control
 SYDEF  PARKCOM        , 039h ;   Information: you are parked for common excess
; SYDEF                 , 03Ah ; 
 SYDEF  TRANSP         , 03Bh ;RP Communication with ICCU2
 SYDEF  PRRD           , 03Ch ;   Program order, read data
 SYDEF  PRRDANSW       , 03Dh ;   Answer at order read data
 SYDEF  PRWR           , 03Eh ;   Program order, start program
 SYDEF  PRWRANSW       , 03Fh ;   Answer at order start program

 SYDEF  CARDREP        , 040h ;RP Ask RP:s for card report
; SYDEF                 , 041h ;
 SYDEF  SYSPAR         , 042h ;RP System parameters
 SYDEF  ACBCTRL        , 043h ;   Control-message to CB-block
 SYDEF  E2RECORD       , 044h ;   General communication with E2 handler
 SYDEF  ECCOM          , 045h ;   General communication with External Computer
 SYDEF  TEXTEDIT       , 046h ;   Text editing support
 SYDEF  CPJOB          , 047h ;RP Run a test job in CP, from TSTX
 SYDEF  IMPCTRL        , 048h ;RP Impulse digit control
 SYDEF  SUPERV         , 049h ;RP Test of RP (software watchdig)
 SYDEF  SUPERVANSW     , 04Ah ;RP Answer at SUPERV
 SYDEF  WARN           , 04Bh ;RP Warning: Message from RP / Log to RP:s
 SYDEF  KSCDIGREQ      , 04Ch ;RP Request digit sending 
 SYDEF  MICTRL         , 04Dh ;   Extension has message or information waiting
 SYDEF  KEYSEARCH      , 04Eh ;   Search for specific programmable key
 SYDEF  CONRELCTRL     , 04Fh ;   Connection release, special requirements
  PAGE
 SYDEF  RPCTRL         , 050h ;RP To/from RP for control
 SYDEF  RPJOB          , 051h ;RP Order to RP to run a job
 SYDEF  MEMEX	       , 052h ;RP Memory Examine
 SYDEF  ADFUNCTION     , 053h ;RP A/D functions (temp and voltage)
 SYDEF  TESTTRACE      , 054h ;RP Test and Trace
 SYDEF  CALENDAR       , 055h ;RP Realtime data to hardware
 SYDEF  RPJOBANSW      , 056h ;RP Answer at RPJOB
 SYDEF  LCDPAR         , 057h ;RP Define parameters for LCD (char-pattern)
 SYDEF  LCDCTRL        , 058h ;RP Control of LCD
 SYDEF  LCDTEXTALL     , 059h ;RP Brodcast text information for LCD
 SYDEF  LCDSCROLL      , 05Ah ;RP Write a character in LCD
 SYDEF  LCDWR          , 05Bh ;RP Write text into LCD
 SYDEF  MUCTRL         , 05Ch ;   Controlling of PCM channel messages
 SYDEF  CICTRL         , 05Dh ;   Controlling of ISDN caller list functionality
 SYDEF  BLOCKINFO      , 05Eh ;   Block Information
 SYDEF  TRSTATUS       , 05Fh ;   Trunk status information

 SYDEF  CPICKUPCTRL    , 060h ;   Call pickup control
 SYDEF  BTCORDER       , 061h ;RP To BTU for detect or send line signal
 SYDEF  BTCPAR         , 062h ;RP Transfer of BTC parameters to BTU
; SYDEF                 , 063h ;
 SYDEF  BTCSIGNAL      , 064h ;RP From BTU on incoming signals
 SYDEF  MPCON          , 065h ;   Multiparty connect
 SYDEF  MPCONANSW      , 066h ;   Multiparty connect answer
 SYDEF  MPREL          , 067h ;   Multipart release
 SYDEF  LCRNUM         , 068h ;   Least cost routing number transfer
 SYDEF  NUMCONVERT     , 069h ;   Number conversion
 SYDEF  KSCDIGRDY      , 06Ah ;   From TS when all digits have been sent
 SYDEF  KSCDIGSEND     , 06Bh ;   To TS when digits shall be sent
 SYDEF  TONECTRL       , 06Ch ;RP To/from TS-TSU 
 SYDEF  TONESEND       , 06Dh ;   To TS when a tone shall be sent
 SYDEF  TONEPAR        , 06Eh ;RP From TS to TSU, ELU: tone parameters
 SYDEF  TONERDY        , 06Fh ;RP From TS, ELU, a tone have been transmited
  PAGE
 SYDEF  SEIZACD        , 070h ;   From automatic call distribution block
 SYDEF  SEIZACK        , 071h ;   Connection is allowed
 SYDEF  SEIZACKREL     , 072h ;   Ack message and no connection is needed
 SYDEF  SEIZBOOKED     , 073h ;   Change originator for the connection
 SYDEF  SEIZCALL       , 074h ;   A normal connection is wanted
 SYDEF  SEIZINTCOM     , 075h ;   Conn. is wanted to dedicate intercom line
 SYDEF  SEIZNAK        , 076h ;   Connection is not allowed
 SYDEF  SEIZNAKRERO    , 077h ;   Terminator can direct reroute the seizure
 SYDEF  UPDCARD        , 078h ;   Update card position
 SYDEF  UPDIND         , 079h ;   Update individual
 SYDEF  ACDINFO        , 07Ah ;   ACD-information, to CD-block
 SYDEF  ACDCTRL        , 07Bh ;   ACD-control, from CD-block
 SYDEF  SEIZDATACOM    , 07Ch ;   Data call.
 SYDEF  AUTHCAT        , 07Dh ;   Authority code categories.
 SYDEF  SURDY          , 07Eh ;   Startup is ready
 SYDEF  REALTIME       , 07Fh ;   Realtime clock order/information.

 SYDEF  DISPLAYCTRL    , 080h ;
 SYDEF  DISPLAYWR      , 081h ;
; SYDEF                , 082h ; 
; SYDEF                , 083h ;
 SYDEF  GROUPCTRL      , 084h ;   Group ringing for multiple call presentation
 SYDEF  GUEST          , 085h ;   Check Guest dependent data
 SYDEF  HOCILINPUT     , 086h ;   Hotel information Input
 SYDEF  HOCILOUTPUT    , 087h ;   Hotel information Output
 SYDEF  VOICEPAGCTRL   , 088h ;RP Voice paging control
 SYDEF  INSTRTYPE      , 089h ;RP From ELU when a key is released
 SYDEF  VMUSEIZ        , 08Ah ;RP VMU-card seizure
 SYDEF  VMUSEIZANSW    , 08Bh ;RP VMU seizure answer
 SYDEF  VMUDATAQ       , 08Ch ;RP Voice memory unit data question
 SYDEF  VMUDATAANSW    , 08Dh ;RP Voice memory unit data answer
 SYDEF  VMUORDER       , 08Eh ;RP Voice memory unit order
 SYDEF  VMUORDERANSW   , 08Fh ;RP Voice memory unit order answer
  PAGE
 SYDEF  KEYCODE        , 090h ;RP From ELU when a key is depressed
 SYDEF  KEYDATA        , 091h ;RP To ELU, info. about programmable keys
 SYDEF  KEYDATARES     , 092h ;RP To ELU, reset all data about pgmable keys
; SYDEF                , 093h ; 
 SYDEF  ELDTRANSIT     , 094h ;RP Transit message from/to telephones
 SYDEF  ELSTATE        , 095h ;RP State report from extension lines
 SYDEF  PNRINFO        , 096h ;   Private network routing information
 SYDEF  ELCTRL         , 097h ;RP Control of ELU-
 SYDEF  LEDCTRL        , 098h ;RP To ELU for update LED status
 SYDEF  LEDRING        , 099h ;RP To ELU for update LED and/or ring status
 SYDEF  NUMINFO        , 09Ah ;   Additional number information. 
 SYDEF  RINGCTRL       , 09Bh ;RP To ELU for update ring status
 SYDEF  ELPAR          , 09Ch ;RP To ELU, parameters
 SYDEF  RINGSTOP       , 09Dh ;RP To/From ELU order stop ringing
 SYDEF  OMPCCOM        , 09Eh ;RP Command to PC-handler in OM-block
 SYDEF  OMPCCOMANSW    , 09Fh ;RP Answer from PC-handler in OM-block

 SYDEF  TRANSM         , 0A0h ;RP Transmission and PCM-channel control
 SYDEF  LINERR         , 0A1h ;RP From ELU when line error is detected
 SYDEF  STATEREP       , 0A2h ;RP State reports to external units
 SYDEF  REGCTRL        , 0A3h ;RP Register control
 SYDEF  HOOKOFF        , 0A4h ;RP From ELU when extension goes off hook
 SYDEF  HOOKON         , 0A5h ;RP From ELU when extension goes on hook
 SYDEF  TONECON        , 0A6h ;   To order orig. connect tone on own device.
 SYDEF  TONEREQ        , 0A7h ;   To request tone sending from terminator.
 SYDEF  TRTRANSIT      , 0A8h ;   Transit information beetween TR-processes.
 SYDEF  E2STATUS       , 0A9h ;   To request/anwer on E2-memory resources.
 SYDEF  PGINFO         , 0AAh ;   Paging (radio) information.
 SYDEF  GUESTINFO      , 0ABh ;   Guest information (EX -- HO)
 SYDEF  MISTOCLR       , 0ACh ;   Message store and clear
 SYDEF  METER          , 0ADh ;RP Metering.
 SYDEF  PCCTRL         , 0AEh ;   PC-communication
 SYDEF  BTLSUP         , 0AFh ;RP Trunk supervision
  PAGE
 SYDEF  COST           , 0B0h ;   Cost of call
 SYDEF  SEIZLCR        , 0B1h ;   Connection before/aftr LCR analysis
 SYDEF  SERVICE        , 0B2h ;RP Handlig of facilitys
 SYDEF  SISIG          , 0B3h ;RP Standard interface signalling
 SYDEF  CONPTYNUM      , 0B4h ;RP Connected/calling party number
 SYDEF  TISIG          , 0B5h ;RP Terminal interface signalling
 SYDEF  VMUCTRLDATA    , 0B6h ;RP Data / Infodmation about resources on VMU-HD
 SYDEF  VMUSEIZHD      , 0B7h ;RP Seizure of VMU-HD card
 SYDEF  VMUORDER2      , 0B8h ;RP Erase data references on VMU-HD
 SYDEF  VMSEIZ         , 0B9h ;   Seize a voice memory 
 SYDEF  VMSEIZANSW     , 0BAh ;   Voice memory seizure answer
 SYDEF  VMCTRL         , 0BBh ;RP Voice memory control
 SYDEF  OPINFO         , 0BCh ;   Information fom op to connected party.
 SYDEF  OPRING         , 0BDh ;   Operator initiated ring
 SYDEF  DIGREQ         , 0BEh ;   Digit request
 SYDEF  QUEUEINFO      , 0BFh ;   Question/answer about camp on queue.

 SYDEF  PRINIT         , 0C0h ;   Program order, init 'owner control'
 SYDEF  PRCTRL         , 0C1h ;   Program control
 SYDEF  PRDATA         , 0C2h ;   Program data request/display
 SYDEF  PRDATATRANSFER , 0C3h ;   Program input data transfer
; SYDEF                 , 0C4h ;   
 SYDEF  CILSERVICE     , 0C5h ;   Call Information Feature (Event) Logging
 SYDEF  CILCONDAT      , 0C6h ;   Call information logging connection data
 SYDEF  CILCONSTAT     , 0C7h ;   Call information logging connection state
 SYDEF  CILDIGSEND     , 0C8h ;   Call information logging digit sending
 SYDEF  CILCONREL      , 0C9h ;   Call information logging connection release
 SYDEF  EUSEIZ         , 0CAh ;   EU-seizure
 SYDEF  EUCTRL         , 0CBh ;   EU-control
 SYDEF  IOINIT         , 0CCh ;RP IO-initialisation
 SYDEF  IOCTRL         , 0CDh ;RP IO-control
 SYDEF  IODATA         , 0CEh ;RP IO-data transfer
 SYDEF  ALARMCTRL      , 0CFh ;   Alarm control

 SYDEF  IPDATA         , 0D0h ;RP IP data transfer
 SYDEF  UPGRAD         , 0D1h ;RP FW Upgrade Data Information
 SYDEF  ACCTRL         , 0D2h ;   Account code control
 SYDEF  IPSIG          , 0D3h ;RP IP signalling
 SYDEF  ARCTRL         , 0D4h ;   Control Automatic Redial feature
 SYDEF  BREAKINCTRL    , 0D5h ;   Control Break In feature
 SYDEF  CONFCTRL       , 0D6h ;   Control Conference feature
 SYDEF  TFRCTRL        , 0D7h ;   Control Transfer function
 SYDEF  LICFUNC        , 0D8h ;RP License function
 SYDEF  LCDTOG1        , 0D9h ;RP Write text into LCD with toggle option
 SYDEF  LCDTOG2        , 0DAh ;RP Write alt. text into LCD with toggle option
; SYDEF                 , 0DBh ; 
; SYDEF                 , 0DCh ; 
; SYDEF                 , 0DEh ; 
 SYDEF  TIMEOUT        , 0DFh ;   Required timeout has expired

;                      ,  E0  ; First Information code for blockinternal use
;                      ,  FB  ; Last  Information code for blockinternal use
;                      ,  FC-FF Not allowed to use at all.
;REND (infcodes)
        ENDIF   ; (SYASMFLG)
  PAGE
        STITLE     '12. MESSAGE-DATA'
;----------------------------------------------------------------------------
; 12.    MESSAGE DATA
;----------------------------------------------------------------------------
;        For details, see separate message descripions
;

;----------------------------------------------------------------------------
; 12.1   RPCTRL-message, mode. (subcode)
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, RPCTRL
;-----------------------------------
RPOFF		EQU	00h	;RP OFF
RPSTARTUP	EQU	01h	;RP STARTUP
RPBLOCKED	EQU	02h	;RP BLOCKED
RPNORMAL	EQU	03h	;RP NORMAL
RPUPGRADE	EQU	04h	;RP UPGRADE

RPSTARTED	EQU	11h	;RP Format and restart information to CP
;-----------------------------------
;REND (subcodes)

;-----------------------------------
;	CPUINFO at DATA+2
;-------------------------
;RBEG,OTHERS

CPULONGMSGS	EQU	01h	;RP Bit 0 : CPU (actually CPU-D4) is
				;           able to handle long messages

;REND (subcodes)
;-----------------------------------

;----------------------------------------------------------------------------
; 12.2   SURDY, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, SURDY
;-----------------------------------
SUWARM		EQU	00h	; Warm start (normal restart)
SUCOLD		EQU	01h	; Cold start (new e2base records)
SUBLKRDY	EQU	02h	; Block ready (answer-message)
SUALLRDY	EQU	03h	; All block ready for traffic.
SUBLKWAIT	EQU	04h	; Block needs more time for initialization
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.3   SEIZ-messages
;----------------------------------------------------------------------------
;       Offset for datafield in seiz-family messages.
;
;                      Offsets    	; Description
;		       -----------------;-----------------------------
;		EQU	0		; Reserved area
;		EQU	1		;
;		EQU	2		;
;		EQU	ML		; 
;		EQU	ST		; 
;		EQU	SN		; 
;		EQU	CARD		; 
;		EQU	IND		; 
;		EQU	CODE		; 
SENDER		EQU	DATA		; ID-code for sender (4 bytes)
DIRCUR		EQU	DATA+4		; Current directory nr (2 bytes)
DIRPRIM		EQU	DATA+6		; Primary directory nr (2 bytes)
CTRLDATA	EQU	DATA+8		; Control data (2 bytes)
ORIGHEAD	EQU	DATA+10		; Originator head (1 byte)
ORIGDATA	EQU	DATA+11		; Originator indiv. data (8 bytes)
ORIGOPT		EQU	DATA+19		; Originator option data (5 bytes)
IMHEAD		EQU	DATA+24		; Intermediary head (1 byte)
IMOPT		EQU	DATA+25		; Intermediary opt. data (5 bytes)
TERMHEAD	EQU	DATA+30		; Terminator head (1 byte)
TERMDATA	EQU	DATA+31		; Terminator indiv. data (8 bytes)
TERMOPT		EQU	DATA+39		; Terminator option data (5 bytes)
FWDDATA		EQU	DATA+44		; Forward optional data (0-11 bytes)
RETDATA		EQU	FWDDATA		; Return optional data (0-11 bytes)
CTRLDATA2	EQU	DATA+55		; Control data, 2nd part (2 bytes)
ORIGDATA2	EQU	DATA+57		; Orig. indiv. data, 2nd part (4 bytes)
TERMDATA2	EQU	DATA+61		; Term. indiv. data, 2nd part (4 bytes)
IMOPT2		EQU	DATA+65		; Int. opt. data, alt. part (15 bytes)
FWDDATA2	EQU	DATA+90		; Add. forward optional data (0-11 bytes)
RETDATA2	EQU	FWDDATA2	; Add. return optional data (0-11 bytes)
  PAGE
;       CTRLDATA   Bit position symbols:

SZAINBIT        EQU     0  ; Allow information
SZKEYBIT        EQU     1  ; Programme key for external line pressed.
SZDWQBIT        EQU     2  ; Demand WAIT QUEUE if busy.
SZKDIBIT        EQU     3  ; Keep display information.
SZNMGBIT	EQU	4  ; Override diversion to MG
SZNAABIT	EQU	5  ; Override diversion to AA
SZBSIBIT	EQU	6  ; Bearer service requires ISDN connection
SZRTRBIT	EQU	7  ; Room To Room calls from orig are allowed


;       CTRLDATA+1 Bit position symbols:

SZOFMBIT        EQU     0  ; Override follow me
SZODVBIT        EQU     1  ; Override diversion (all forms)
SZODMBIT        EQU     2  ; Override disturbance marking.
SZF2ABIT        EQU     3  ; Force a call on 2'nd access, (call waiting)
SZAWQBIT        EQU     4  ; Allow wait-queqe on 2'nd access.
SZTCDBIT        EQU     5  ; No TCD-control needed.
SZNPCBIT        EQU     6  ; No PCM-channel wanted.
SZEMUBIT        EQU     7  ; Exclude calling party from MULTPRES-message.


;       CTRLDATA2+0
;			Duo position symbols for bits 0,1,2,3 :

PNRROUTEDUO	EQU     0	; Number of PNR route which shall be accessed
PNRMAXALTDUO	EQU	1	; Number of PNR alternative routes which may be accessed :
				; value (0 - 3), only valid if originator is TR

;			Bit position symbols for bits 4,5,6,7 :

TFRBIT		EQU	4	; TFR = 1 : a user initiated call transfer is executed
				; by setting up the new connection
CDTBIT		EQU	5	; CDT = 1: Cordless instrument shall be treated as
				; display instrument in case of predefined text info -
				; IN block will send text info
				; CDT = 0: Cordless instrument shall be treated as
				; analog instrument in case of predefined text info -
				; IN block will send voice info
ORGBIT		EQU	6	; ORG = 1: Call originated within CN
PNRIPBIT	EQU	7	; PNRIP=1 : PNR IP route not allowed


;       CTRLDATA2+1

;			Bit position symbols for bits 0,1,2,... :

UERWTBIT	EQU	0	; UERWT=1 : ERWT category for a call originator (EX, OP)
				; is active
RERWTBIT	EQU	1	; RERWT=1 : ERWT category for a selected alternative
				; PNR route is active
WSEIZBIT	EQU	2	; WSEIZ=1 : wait with seizure of BTU until the
				; calling number is forwarded (TR->TR)
CA2ME		EQU	3	; CA2ME=1:  call to an Integrated Mobile Extension
				; (EX->TR)
CPNNA		EQU	4	; CPNNA=1: requests number analysis of inband received digits
				; (EX->TR)

;	ORIGDATA2+1

;			Bit position symbols :

IPTRUNKBIT	EQU	3	; IPTRUNK=1 : Call originator is an IP trunk (TR->TR)


; 	Symbols for calltype (SeiZure Calltype).

SZC.NOTS        EQU     0       ; Not specified.
SZC.EXT         EQU     1       ; External, not answered, normal.
SZC.EXT1        EQU     2       ; External, not answered, superior ex I
SZC.EXT2        EQU     3       ; External, not answered, superior ex II
SZC.EXT3        EQU     4       ; External, not answered, superior ex III
SZC.EXTA        EQU     5       ; External, answered.
SZC.INT         EQU     6       ; Internal.
SZC.CB          EQU     7       ; Call back, (answer from CB).
SZC.REM         EQU     8       ; Alarm (Reminder)
SZC.WU          EQU     9       ; Wake up.
SZC.AUT         EQU    10       ; Internal, authority code.
SZC.TIE         EQU    11       ; Tie line.
SZC.DID         EQU    12       ; Direct indialling.
SZC.TIEA	EQU    13	; Tieline answer
SZC.SIL		EQU    14	; Silent intrusion.
SZC.EXTSBA	EQU    15	; External, ISDN Basic Access call setup

;                               ; 16-31  reserved for OP-use
SZC.EXTP        EQU    16       ; External / Extension parked, recall
SZC.TFRC        EQU    17       ; Transferred call (OP-internal use)

SZC.EXTINF	EQU    31	; External, information call (used by TR)
SZC.CONREC	EQU    32	; Conversation recording
SZC.OCNFULL	EQU    33	; Outcall notification with allowed full mailbox access
SZC.OCNBRIEF	EQU    34	; Outcall notification with allowed brief mailbox access
  PAGE
;       Symbols for intermediary part. (SeiZure Intermediary).
 
SZI.DIRECT      EQU     0       ; Direct, no intermediary part.
SZI.ROUTE       EQU     1       ; Routing (orginal route)
SZI.GRHUNT      EQU     2       ; Group hunting.
SZI.ROALT	EQU	3       ; Routing (alternative route used).
SZI.ROSBA	EQU	4	; Routing to Basic Access, S-interface
SZI.SLAVE	EQU	5	; Call to a SLAVE extension
SZI.CNC		EQU	6	; Corporate Network Call
SZI.MASTER	EQU	7	; Call rerouted from SLAVE to MASTER extension

; Symbols for terminatorstate and the not specified statedetail, used in 
; the TERMHEAD in the SEIZ-family-messages (SeiZureTerminator).

SZT.NONE        EQU    00h      ; No old terminator, no data, for seiz forward
SZT.NU          EQU    00h      ; Number unobtainable, no data, not specified.
SZT.BLKN        EQU    10h      ; Blocked, no data, not specified.
SZT.FREE        EQU    20h      ; Free, with data, not specified.
SZT.BUSY        EQU    30h      ; Busy, with data, not specified.
SZT.BLKD        EQU    40h      ; Blocked, with data, not specified.
SZT.RCALL       EQU    50h      ; Recall, with data, not specified.
SZT.DIV         EQU    60h      ; Diversion, with data, not specified.
SZT.PICKUP      EQU    70h      ; Call pickup, with data, not specified
SZT.RER		EQU    80h	; Rerouted call
SZT.NUFWD       EQU    90h      ; Number unobtaiable, with data, not spec.
SZT.CNDIV	EQU   0A0h	; CN diversion, with data, not specified
SZT.CNRER	EQU   0B0h	; CN rerouted call
  PAGE
;----------------------------------------------------------------------------
; 12.3.1 SEIZ-messages and others, INDIVIDUAL data field
;----------------------------------------------------------------------------
                                ; Relative address offset, 
                                ; within the 8-byte field:
IDIR            EQU     0       ; Directory number
ICOS            EQU     2       ; A and B-COS
ITCD            EQU     3       ; TCD-DAY and NIGTH
ITRAF           EQU     4       ; Abbcos and trafficgroup
ITERM           EQU     5       ; Terminaltype
IBITS           EQU     6       ; Information bit field

ACOSNIB         EQU     1       ; ACOS nibble position symbol:

				; BCOS bitposition symbols:
BRKINBIT        EQU     0       ; Break in allowed bit
CWAITBIT        EQU     1       ; Call waiting allowed bit
CBACKBIT        EQU     2       ; Call back allowed bit

ABBCOSDUO       EQU     2       ; ABBCOS duet position (?)<remove later on> 
TENANTNIB	EQU	1	; Tennant category nibble position
TRAFNIB         EQU     0       ; Traffic-group nibble position

				;---------
				; IBITS+0 Information bit-position symbols:
CFSBIT          EQU     0       ; Clear forward signal available.
INFBIT          EQU     1       ; Text Information is available.
NAMBIT          EQU     2       ; Name-string available.
TPCBIT          EQU     3       ; Trunk-pool PCM-channel allowed to use.
VCEBIT          EQU     4       ; Voice Information is available.
OGTBIT          EQU     5       ; Outgoing trunk-call (set by trunkblock)
GUEBIT          EQU     6       ; Guest room extension.
PRKBIT          EQU     7       ; Parking of data call allowed.

				;---------
				; IBITS+1 Information bit-position symbols:
TAUBIT          EQU     0       ; Terminal adaptor present on line.
CLIBIT		EQU	1	; ISDN, A-number allowed to display
AADBIT		EQU	2	; TR has played an announcement according to
				;    the facility voice message before answer
AGLBIT          EQU     3       ; ACD agent which is logged on.
ICHBIT          EQU     4       ; Extension individual charging.
ACHBIT		EQU	5	; Not allowed to show the acc. charge
OLRBIT		EQU	6	; Override trunk LCR control flag
SLABIT		EQU	7	; Connected party is a SLAVE extension

ITCDS		EQU	0	; TCD-DAY and NIGHT suffix digit sending
IBITS2		EQU	1	; Information bit field 2

				;----------
				; IBITS2+0 Information bit/nibble-position symbols:
PRCLIBIT	EQU	0	; Restriction for numbers of the
				; Corporate Numbering Plan
;		EQU	1	; 
ACCOUBIT	EQU	2	; Auccount Code Bit
VTQNIB		EQU	1	; IP data: Voice Transmission Quality,
				; 1-4 level values 

				;----------
				; IBITS2+1 Information bit/nibble-position symbols:
TRANSEOSBIT	EQU	0	; Direct/ non-direct type of transit call (TR-TR)
CCBBIT		EQU	1	; Collected Call Blocking bit (0 allowed, 1 blocked)
;		EQU	2	; 
CLISTNIB	EQU	1	; Caller List nibble
				; for answerde incoming calls

				;----------
				; IBITS2+2 Information bit/nibble-position symbols:
TCM		EQU	0	; Travalling Class Mark
UCDBIT		EQU	4	; unlimited call duration

  PAGE
;----------------------------------------------------------------------------
; 12.3.2 Instrument- and Terminal-types. (INSTRTYPE)
;----------------------------------------------------------------------------
                              ;-------------------------------------------
TERM.TYPEMASK   EQU 11000000b ; Type-mask for check of terminal types of
                              ; INSTRUMENTS, TRUNKS or FACILITIES.
                              ; Do an AND and CMP with TERM.I TERM.T or TERM.F
                              ;-------------------------------------------

;-----------------------------------
;RBEG,SUBCODES
;RCODE, INSTRTYPE
;-----------------------------------
                              ; Terminal types: INSTRUMENTS
                              ;----------------------------
TERM.I          EQU    0      ;RP Instrument, not specified
TERM.ISTD       EQU    1      ;RP Instr, digital standard.           (DBC 751)
TERM.IMIN       EQU    2      ;RP Instr, digital minor system.       (DBC 752)
TERM.IMAJ       EQU    3      ;RP Instr, digital major system.       (DBC 753)
;               EQU    4      ;   
;               EQU    5      ;   
TERM.IBOX       EQU    6      ;RP Instr, digital line-relay-box.
TERM.IMINL      EQU    7      ;RP Instr, digital minor, loudspeaking (DBC 755)
TERM.IOP        EQU    8      ;RP Instr, operator.                   (DBC 754)

TERM.IGUE       EQU    12     ;RP Instr, guestroom, hotel            (DBC  ? )

TERM.IANA       EQU    15     ;RP Instr, analouge.

TERM.SPOTS	EQU    20     ;RP Instr (std PCM) POTS telephone     (DBC 199)
TERM.SSTD	EQU    21     ;RP Instr (std PCM) standard           (DBC 601)
TERM.SMIN	EQU    22     ;RP Instr (std PCM) minor system       (DBC 631)
TERM.SMAJ	EQU    23     ;RP Instr (std PCM) major system       (DBC 662)
TERM.SOP	EQU    24     ;RP Instr (std PCM) operator           (DBC 663)

TERM.DSTD	EQU    25     ;RP Standard D3-phone		     (DBC 202)
TERM.DMAJ	EQU    26     ;RP Major D3-phone		     (DBC 203)
TERM.DMAJD	EQU    27     ;RP Major D3-phone + 1st DSS	     (DBC 203)
TERM.DMAJE	EQU    28     ;RP Major D3-phone + 1st EXT	     (DBC 203)
TERM.DMAJND	EQU    29     ;RP Major D3-phone + 2nd DSS	     (DBC 203)
TERM.DMAJDD	EQU    30     ;RP Major D3-phone + 1st DSS + 2nd DSS (DBC 203)
TERM.DMAJED	EQU    31     ;RP Major D3-phone + 1st EXT + 2nd DSS (DBC 203)
TERM.DMAJNE	EQU    32     ;RP Major D3-phone + 2nd EXT	     (DBC 203)
TERM.DMAJDE	EQU    33     ;RP Major D3-phone + 1st DSS + 2nd EXT (DBC 203)
TERM.DMAJEE	EQU    34     ;RP Major D3-phone + 1st EXT + 2nd EXT (DBC 203)
TERM.DMIN	EQU    35     ;RP Minor D3-phone                     (DBC 201)
TERM.D1MAJ	EQU    36     ;RP Major D3-My phone                  (DBC 213)
TERM.D1OP	EQU    37     ;RP Operator D3-phone                  (DBC 214)
TERM.D3POTS	EQU    38     ;RP D3 POTS telephone                  (DBC 210)

;                      39-45      spare for new telephones

TERM.D422	EQU    46     ;RP D4 Office IP telephone             (DBC 422)
TERM.D425	EQU    47     ;RP D4 Vision IP telephone             (DBC 425)
TERM.H323	EQU    48     ;RP H.323 Standard client
TERM.D3IP	EQU    49     ;RP D3 IP telephone
TERM.GEN3.1	EQU    50     ;RP Analogue terminal, 3.1 kHz audio
TERM.G3FAX	EQU    51     ;RP Group 3 facsimile, 3.1 kHz audio
TERM.MODEM	EQU    52     ;RP Modem connection,  3.1 kHz audio
TERM.FAX	EQU    53     ;RP regular facsimile,3.1 kHz audio
TERM.MOBEXT	EQU    54     ;RP mobile extension (HW solution)

;                      55-58      spare

TERM.IMOBEXT    EQU    59     ;RP mobile extension (integrated SW solution)



;                      55-59      spare

TERM.DECT	EQU    60     ;RP CORDLESS equipment supporting
		              ;   DECT-A-protocol
TERM.GAP	EQU    61     ;RP CORDLESS equipment supporting
		              ;   DECT-GAP-protocol
TERM.GAP20	EQU    62     ;RP Cordless equipment supporting
			      ;   DECT GAP protocol release GAP2.0


;                      62-63      spare

;                             ; ONLY FOR SEIZFAMILY:
;-----------------------------------------------------------------------------

                              ; Terminal types: TRUNKS
                              ;-----------------------
TERM.T          EQU   64      ;RP Trunk, not specified.
TERM.TEXG       EQU   65      ;RP Trunk, exchange line.
TERM.TTIE       EQU   66      ;RP Trunk, tie-line.
TERM.TDID       EQU   67      ;RP Trunk, direct indialling.
TERM.TPRA	EQU   68      ;RP Trunk, ISDN primary access
TERM.TBRA	EQU   69      ;RP Trunk, ISDN basic rate access, T-interface
TERM.TSBA	EQU   70      ;RP Trunk, ISDN basic access, S-interface
TERM.TCNINT	EQU   71      ;RP Trunk, internal CN call handling
TERM.TCNEXT	EQU   72      ;RP Trunk, external CN call handling
TERM.TH323	EQU   73      ;RP Trunk, H.323 standard trunk
;-----------------------------------
;REND (subcodes)  PAGE
;-----------------------------------


                              ; Terminal types: FACILITIES
                              ;---------------------------
TERM.F          EQU  128      ; Facility, not specified.
TERM.FBI        EQU  129      ; Break In (normal).
TERM.FBISIL     EQU  130      ; Break In (silent intrusion).
TERM.FLCR	EQU  131      ; Least cost routing
TERM.FTSTNOMFC	EQU  132      ; Test number for MFC-test call Belgium
TERM.FAA	EQU  133      ; Automated Attendant
TERM.FSTORET	EQU  134      ; Storing and retrieving messages
TERM.FACD	EQU  135      ; Automated Call Distribution
TERM.FTSTNOPL	EQU  136      ; Test number for MFC-test call Poland
TERM.FGRHUNT	EQU  137      ; Group call hunting
TERM.FFN	EQU  138      ; Fictive number


                              ; Terminal types: ...
                              ;---------------------------
TERM.N          EQU  240      ; Not defined terminal.
TERM.NUNOB      EQU  241      ; Not defined, number unobtainable.
TERM.NINCOMPL   EQU  242      ; Not defined, number incomplete.
  PAGE
;----------------------------------------------------------------------------
; 12.3.3	Forward and return data field
;----------------------------------------------------------------------------
;			; SEIZCALL:
			;----------
SZCF.NONE		EQU   0		; The FWDDATA-field contains no data
SZCF.DIRPREV		EQU   1		; dirno of previous called party
SZCF.COST		EQU   2		; cost of an operator handled call
SZCF.LCRREQ		EQU   3		; LCR request
SZCF.EXTERNDIV		EQU   4		; External diverted transit call
SZCF.CBCALLIMM		EQU   5		; Incoming or outgoing CN callback call
					; immediate
SZCF.CBCALLDEL		EQU   6		; Incoming or outgoing CN callback call
					; delayed
SZCF.CBREQINTFREE	EQU   7		; Request of CN callback on free from
					; an internal extension user
SZCF.CBREQINTBUSY	EQU   8		; Request of CN callback on busy from
					; an internal extension user
SZCF.ALGRP		EQU   9		; header indicates that an alarm
					; extension requests clearing of its
					; previous set alarm
SZCF.DISA		EQU   0Ah	; AA and DISA call
SZCF.INTREQ		EQU   0Bh	; header indicates outgoing CN intrusion
					; request call
SZCF.CBACTIVE		EQU   0Ch	; dirno of actual wanted party in callback call
SZCF.MOBEXT		EQU   0Dh	; Call from a Mobile Group
SZCF.VIRVOIPGW		EQU   0Eh 	; indicates virtual VoIP GW call  

SZCF.CBREQFREE		EQU   0F0h	; Incoming or outgoing CN callback
					; on free request call
SZCF.CBREQBUSY		EQU   0F1h	; Incoming or outgoing CN callback
					; on busy request call
SZCF.CBDEL		EQU   0F2h	; Outgoing callback cancel call
SZCF.CBFREE		EQU   0F3h	; Outgoing free notification call
SZCF.CNINFTR		EQU   0F4h	; Transit information call
SZCF.CNFMREG		EQU   0F5h	; Outgoing CN follow me registration
					; request call

;			; SEIZBOOKED:
			;------------
SZBF.NONE	EQU   0	; The FWDDATA-field contains no data
SZBF.DIRPREV	EQU   1	; dirno of previous called party
SZBF.MOBEXT	EQU   2	; Call caused by rerouting on Mobile Extension call
SZBF.MECHNL	EQU   3 ; FWDDATA2+1 contains the PCM-channel to be used
			; by the block receiving the SEIZBOOKED-message

			; SEIZACK
			;---------
SZAR.NONE	EQU   0	; the RETDATA-field does not contain any data
SZAR.LCR	EQU   1	; the RETDATA-field contains return data for
			; the Least Cost Routing facility
SZAR.PICKUP	EQU   2	; the field contains return data needed for
			; the Call Pickup facility
SZAR.TRANSIT	EQU   3	; the field contains return data needed for
			; transit call conditions
SZAR.DTMF	EQU   4	; the RETDATA-field does not contain valid data.
			; the originator has to order a DTMF receiver
SZAR.MOBEXT	EQU   5	; SEIZ-answer from a Mobile Extension individual

  PAGE
;----------------------------------------------------------------------------
; 12.4   CONCTRL-message, subcodes (states).
;----------------------------------------------------------------------------
;        Note, some of these subcodes are used for CILCONSTAT message too.
;              (keep these subcodes in range 00 - 2F)
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, CONCTRL
;RCODE, CILCONSTAT
;-----------------------------------
CON.REG         EQU    0        ; Register
CON.RING        EQU    1        ; Ringing
CON.SPEECH      EQU    2        ; Speech
; CON.            EQU    3        ; spare
CON.TTTB        EQU    4        ; Totally transparent, totally busy.
CON.TTNB        EQU    5        ; Totally transparent, normal busy.
CON.PTNB        EQU    6        ; Partial transparent, normal busy.
; CON.            EQU    7        ; spare
CON.OPTEST      EQU    8        ; Test of operatorinstrument.
CON.VPAG        EQU    9        ; Group voice paging
CON.WAIT        EQU   10        ; Waiting, queued
CON.BREAKA      EQU   11        ; Break-in 'A'-part
CON.BREAKB      EQU   12        ; Break-in 'B'-part
CON.BREAKC      EQU   13        ; Break-in 'C'-part
CON.CONF        EQU   14        ; Conference
CON.TTTBV	EQU   15	; Totally transparent, totally busy, volume
CON.TTNBV	EQU   16	; Totally transparent, normal busy, volume
CON.PTNBV	EQU   17	; Partial transparent, normal busy, volume
CON.REGREQ	EQU   18	; Register, request of keys one by one
CON.ALERT	EQU   19	; Ringing strted in network
CON.PROCEED	EQU   20	; End of selection in network
CON.SPEECHREG	EQU   21	; Speech and register state
CON.PROGRESS	EQU   22	; Progress indicator from ISDN line
CON.CONREC	EQU   23	; Converstation recording facility
CON.3PTYCONF	EQU   24	; External Call Hold and External Conference facility 	
;-----------------------------------
;REND (subcodes)

; Other data in CONCTRL message, Restriction field:
;--------------------------------------------------
;RBEG,  OTHERS
;			0	;     Zero, not used
COND.RESTROFF	EQU	1	; RP  No restriction
COND.RESTRON	EQU	2	; RP  restricted

;REND  (others)
  PAGE
;----------------------------------------------------------------------------
; 12.5    KEYCODE-message, keycodes, keytypes.
;----------------------------------------------------------------------------
;	Symbols for keycodes, dummy keycodes and keytypes, used in the 
;	KEYCODE-
;	message and in the OU.CALL PA.KEYASCII routine.
;
;	Same symbols can be used for LED-number in the LEDRING
;	and the LEDCTRL message.
;
;		; 2'nd funktion of a key is indicated by bit7 =1 in 
K2ND EQU 80h	; the key value. 2'nd funktion of KEY0= KEY0+K2ND
;
;	Range:	00h - 6Fh   for keycodes
;		70h - 74h   for keytypes
;		75h - 7Bh   for keycodes
;		7Ch - 7Fh   for dummy keys
;		80h - EFh   for 2'nd function of keycodes
;		F0h - FFh   for 2'nd function of keytypes and dummy keys
;---------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, KEYCODE
;-----------------------------------

;--------------------------------------------------------------------------
; keycodes
;--------------------------------------------------------------------------
KEY0            EQU     00h     ;RP Keypad digit 0
KEY1            EQU     01h     ;RP              1
KEY2            EQU     02h     ;RP              2
KEY3            EQU     03h     ;RP              3
KEY4            EQU     04h     ;RP              4
KEY5            EQU     05h     ;RP              5
KEY6            EQU     06h     ;RP              6
KEY7            EQU     07h     ;RP              7
KEY8            EQU     08h     ;RP              8
KEY9            EQU     09h     ;RP              9
KEYSTAR         EQU     0Ah     ;RP Keypad  *
KEYSQR          EQU     0Bh     ;RP         #
  PAGE
KEYSAVE         EQU     0Ch     ;RP SAVE
KEYMESS         EQU     0Dh     ;RP MESSAGE
KEYINFO         EQU     0Eh     ;RP INFO
KEYPF_0         EQU     0Fh     ;RP Funktion key 0
KEYPICKUP       EQU     0Fh     ;RP PICKUP  (alternative name of PF_0)
KEYONOFF        EQU     10h     ;RP ON/OFF
KEYMUTE         EQU     11h     ;RP MUTE       alias KEYPF_4P (DBC 2XX familiy)
KEYCLEAR        EQU     12h     ;RP CLEAR
KEYR            EQU     13h     ;RP R
KEYPROG         EQU     14h     ;RP PROG
KEYDIAL         EQU     15h     ;RP Speed DIAL   (erase,backspace in text mode)
KEYREAD         EQU     16h     ;RP READ &       (space in text-mode)
KEYMENU         EQU     17h     ;RP MENU       alias KEYPF_4Q (DBC 2XX familiy)
KEYHOLD         EQU     18h     ;RP HOLD
KEYTRANS        EQU     19h     ;RP TRANSFER

KEYDIV          EQU     1Ah     ;RP DIVERSION
KEYLINE1        EQU     1Bh     ;RP LINE 1
KEYLINE2        EQU     1Ch     ;RP LINE 2
KEYINQ          EQU     1Dh     ;RP INQUIRY

KEYPF_A         EQU     1Eh     ;RP Function key A
KEYPF_B         EQU     1Fh     ;RP              B
KEYPF_C         EQU     20h     ;RP              C
KEYPF_D         EQU     21h     ;RP              D
KEYPF_E         EQU     22h     ;RP              E
KEYPF_F         EQU     23h     ;RP              F
KEYPF_G         EQU     24h     ;RP              G
KEYPF_H         EQU     25h     ;RP              H
KEYPF_I         EQU     26h     ;RP              I
KEYPF_J         EQU     27h     ;RP              J
KEYPF_K         EQU     28h     ;RP              K
KEYPF_L         EQU     29h     ;RP              L
KEYPF_M         EQU     2Ah     ;RP              M
KEYPF_N         EQU     2Bh     ;RP              N

KEYPF_1A	EQU	2Ch	;RP	Function keys for DSS 1
KEYPF_1B	EQU	2Dh	;RP	
KEYPF_1C	EQU	2Eh	;RP	KEYPF_O - KEYPF_Z alias for _1A _1L
KEYPF_1D	EQU	2Fh	;RP	defined after ;RPREND (subcodes)
KEYPF_1E	EQU	30h	;RP
KEYPF_1F	EQU	31h	;RP	
KEYPF_1G	EQU	32h	;RP
KEYPF_1H	EQU	33h	;RP
KEYPF_1I	EQU	34h	;RP
KEYPF_1J	EQU	35h	;RP
KEYPF_1K	EQU	36h	;RP
KEYPF_1L	EQU	37h	;RP

KEYPF_1         EQU     38h     ;RP Soft key 1
KEYPF_2         EQU     39h     ;RP          2
KEYPF_3         EQU     3Ah     ;RP          3
KEYPF_4         EQU     3Bh     ;RP          4

KEYENTER        EQU     3Ch     ;RP ENTER
KEYCONF 	EQU	3Dh     ;RP CONFERENCE

KEYMINUS	EQU	3Eh	;RP Volume -
KEYPLUS		EQU	3Fh	;RP Volume +
  PAGE

KEYPF_1M	EQU	40h	;RP 	Function keys for DSS 1 (cont.)
KEYPF_1N	EQU	41h	;RP 
KEYPF_1O	EQU	42h	;RP 
KEYPF_1P	EQU	43h	;RP 
KEYPF_1Q	EQU	44h	;RP 
  
KEYPF_2A	EQU	45h	;RP 	Function keys for DSS 2
KEYPF_2B	EQU	46h	;RP 
KEYPF_2C	EQU	47h	;RP 
KEYPF_2D	EQU	48h	;RP 
KEYPF_2E	EQU	49h	;RP 
KEYPF_2F	EQU	4Ah	;RP 
KEYPF_2G	EQU	4Bh	;RP 
KEYPF_2H	EQU	4Ch	;RP 
KEYPF_2I	EQU	4Dh	;RP 
KEYPF_2J	EQU	4Eh	;RP 
KEYPF_2K	EQU	4Fh	;RP 
KEYPF_2L	EQU	50h	;RP 
KEYPF_2M	EQU	51h	;RP 
KEYPF_2N	EQU	52h	;RP 
KEYPF_2O	EQU	53h	;RP 
KEYPF_2P	EQU	54h	;RP 
KEYPF_2Q	EQU	55h	;RP 
  PAGE
KEYPF_3A	EQU	56h	;RP
KEYPF_3B	EQU	57h	;RP
KEYPF_3C	EQU	58h	;RP
KEYPF_3D	EQU	59h	;RP
KEYPF_3E	EQU	5Ah	;RP
KEYPF_3F	EQU	5Bh	;RP
KEYPF_3G	EQU	5Ch	;RP
KEYPF_3H	EQU	5Dh	;RP
KEYPF_3I	EQU	5Eh	;RP
KEYPF_3J	EQU	5Fh	;RP

KEYPF_3K	EQU	60h	;RP
KEYPF_3L	EQU	61h	;RP
KEYPF_3M	EQU	62h	;RP
KEYPF_3N	EQU	63h	;RP
KEYPF_3O	EQU	64h	;RP
KEYPF_3P	EQU	65h	;RP
KEYPF_3Q	EQU	66h	;RP
KEYPF_4A	EQU	67h	;RP
KEYPF_4B	EQU	68h	;RP
KEYPF_4C	EQU	69h	;RP
KEYPF_4D	EQU	6Ah	;RP
KEYPF_4E	EQU	6Bh	;RP
KEYPF_4F	EQU	6Ch	;RP
KEYPF_4G	EQU	6Dh	;RP
KEYPF_4H	EQU	6Eh	;RP

KEY2ND		EQU	6Fh	;RP 	2'nd function key

  PAGE
;--------------------------------------------------------------------------
; Special 'keycodes' for 'keytype (group of keys).
;--------------------------------------------------------------------------
;        Keytype symbols for group of KEYS used in 
;        utility routine OU.CALL PA.KEYASCII
;--------------------------------------------------------------------------
KEYS.INV        EQU     70h     ; Invalid as key-code
KEYS.DIGIT      EQU     71h     ; Keypad (digits and *#)
KEYS.LINE       EQU     72h     ; Line-keys (3-line)
KEYS.PGM        EQU     73h     ; Programmable
KEYS.SOFT       EQU     74h     ; Soft function-keys

;--------------------------------------------------------------------------
; keycodes
;--------------------------------------------------------------------------
KEYPF_4I	EQU	75h	;RP
KEYPF_4J	EQU	76h	;RP
KEYPF_4K	EQU	77h	;RP
KEYPF_4L	EQU	78h	;RP
KEYPF_4M	EQU	79h	;RP
KEYPF_4N	EQU	7Ah	;RP
KEYPF_4O	EQU	7Bh	;RP
;--------------------------------------------------------------------------
; 	Dummy keycodes for special functions, to be used in KEYCODE-messages
;--------------------------------------------------------------------------
KEYD.CTI	EQU	7Ch	;   A certain number is requested without knowing
				;   the keynumber where this function is located.
KEYD.ENBLOCK	EQU	7Dh	;RP Transfer one or more numbers or parts of
				;   numbers in one message.
KEYD.WAITDT     EQU     7Eh     ;   Wait for second dialtone.
KEYD.INQSUP     EQU     7Fh     ;   Inquiry in superior exchange.
KEY_ALBUT	EQU	80h	;RP Keycode for alarmbutton

;--------------------------------------------------------------------------
;-----------------------------------
;REND (subcodes)


;--------------------------------------------------------------------------
; Alias for some keycodes
;--------------------------------------------------------------------------
;RBEG, OTHERS
;----------------------------------
KEYPF_O         EQU     2Ch     ;RP              O
KEYPF_P         EQU     2Dh     ;RP              P
KEYPF_Q         EQU     2Eh     ;RP              Q
KEYPF_R         EQU     2Fh     ;RP              R
KEYPF_S         EQU     30h     ;RP              S
KEYPF_T         EQU     31h     ;RP              T
KEYPF_U         EQU     32h     ;RP              U
KEYPF_V         EQU     33h     ;RP              V
KEYPF_W         EQU     34h     ;RP              W
KEYPF_X         EQU     35h     ;RP              X
KEYPF_Y         EQU     36h     ;RP              Y
KEYPF_Z         EQU     37h     ;RP              Z

KEYPF_4P	EQU	11h	;RP
KEYPF_4Q	EQU	17h	;RP
;----------------------------------
;REND   (others)


;--------------------------------------------------------------------------
; Component IDs used for number component for keycode KEYD.ENBLOCK
;--------------------------------------------------------------------------

EBLK_BNUM	EQU	00h
EBLK_ACCESS	EQU	01h
EBLK_AUTHORITY	EQU	02h
EBLK_ACCOUNT	EQU	03h
EBLK_OWNDIRNO	EQU	04h
EBLK_ANUM	EQU	05h
EBLK_ENDCOMP	EQU	0FFh
;----------------------------------
  PAGE
;----------------------------------------------------------------------------
; 12.6    LCDCTRL-messages, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, LCDCTRL
;-----------------------------------
LCDTEXTSEL	EQU	00h	;RP Select broadcast information
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.7    Tones, used in TONE- MPCON- and ELCTRL messages.
;----------------------------------------------------------------------------
;	Symbols for tones used in TONE- and ELCTRL-messages.

;RBEG,SUBCODES
;RCODE, TONECON
;-----------------------------------
TONE.STOP	EQU	 0	;RP  Stop tone sending  (Reconnect last PCM)
TONE.DIAL	EQU	 1	;    Dial tone
TONE.DIALSP	EQU	 2	;    Special dial tone
TONE.RINGSP	EQU	 3	;    Special Ring Tone  (internally to LINE 2)
TONE.RING	EQU	 4	;RP  Ring Tone (freq. used for call waiting)
TONE.BUSY	EQU	 5	;    Busy Tone
TONE.CONG	EQU	 6	;    Congestion Tone (blocked)
TONE.NU		EQU	 7	;    NU-tone
TONE.ACK	EQU	 8	;    Acknowledgement Tone
TONE.CALLVP	EQU	 9	;    Voice Paging Call Tone
TONE.DISC	EQU	10	;    Disconnection Tone
TONE.CALLHA	EQU	11	;    Handsfree Answering Call Tone
TONE.ERRMIN	EQU	12	;    Minor Error Tone	( Used by PR-block )
TONE.ERRMAJ	EQU	13	;    Major Error Tone	( Used by PR-block )
TONE.QUEUE	EQU	14	;    Queue-tone
TONE.INACT	EQU	15	;    Inactive tone
TONE.CONF	EQU	16	;    Conference tone
TONE.BI		EQU	17	;    Intrusion tone (Break in)
TONE.BIOP	EQU	18	;    Intrusion tone (Break in from operator)
TONE.CONFOP	EQU	19	;    Conference tone, operator
TONE.PARK	EQU	20	;    Parking tone
TONE.ALTRING	EQU	21	;    Alternative ring tone
TONE.ALTBUSY	EQU	22	;    Alternative busy tone
TONE.ALTNU	EQU	23	;    Alternative NU tone
TONE.ALTDIAL	EQU	24	;    Alternative dial tone
TONE.OKAY	EQU	25	;    Okay, continue (Short muted tone burst)
TONE.CWAIT	EQU	26	;    Call waiting (tone burst)
TONE.CWAITR	EQU	27	;    Call waiting (repetitive)
TONE.CONGRES	EQU	28	;    Congestion tone (no resources)
TONE.PUBDIAL	EQU	29	;    Public dial tone
TONE.TEST	EQU	30	;    Test tone
TONE.ERWT	EQU	31	;    Expensive Route Warning Tone
;-----------------------------------
;REND (subcodes)


;RBEG, OTHERS
;--------------------------------------------------------------------------
; Alias for some tones
;--------------------------------------------------------------------------
TONE.SILENCE	EQU	 0	;RP  Silence (request a 'quiet' toneprocess)



;--------------------------------------------------------------------------
; 'Tones' used only in MPCONN:
;--------------------------------------------------------------------------
MPTONE.NONE	EQU	0FEh	;     No need for any tone
MPTONE.PROCEED	EQU	0FFh	;     Proceed with earlier tone


;
; 	Symbols for tonelevels used in TONE- messages.
;
TONELEV.INT	EQU	0	;RP   Tonelevel for internal part.
TONELEV.EXT	EQU	1	;RP   Tonelevel for external part.

;REND (others)
  PAGE
;RBEG,OTHERS
;----------------------------------------------------------------------------
; 12.8    LEDRING- LEDCTRL- and MULTPRES messages, ledcadences.
;----------------------------------------------------------------------------
LEDCAD.FREE     EQU     0               ;RP   Free indication, led off
LEDCAD.BUSY     EQU     1               ;RP   Busy indication, Continuous on
LEDCAD.CALL     EQU     2               ;RP   Call flash
LEDCAD.PARK     EQU     3               ;RP   Parking flash
LEDCAD.CONN     EQU     4               ;RP   Connected

;       Alternative symboles for led on and off.

LEDCAD.OFF      EQU     0               ;RP   Led off
LEDCAD.ON       EQU     1               ;RP   Continuous on

;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.9    ACD-messages, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ACDINFO
;-----------------------------------
;                                 ACDINFO-message (to CD-block):
ACDREADY        EQU	01h	; Ready for a new ACD-call
ACDKEYS         EQU	02h	; Info about keys that are defined for ACD
ACDNIGHT	EQU	03h	; nightswitching
ACDTRPOS	EQU	04h	; answering positions
ACDTRQ		EQU	05h	; question of answeringpos
ACDTCD		EQU	06h	; tcd-categories
ACDSILINTR	EQU	07h	; Silent intrusion info
ACDGROUP	EQU	08h	; Login / logout ACD group from CTI
ACDGROUPACK	EQU	09h	; Acknowledge to ACD group from CTI
ACDGROUPNAK	EQU	0Ah	; Not acknowledge to ACDGROUP message
ACDAGSTAT	EQU	0Bh	; Set ACD agent status from CTI
ACDAGSTATACK	EQU	0Ch	; Acknowledge to ACDAGSTAT message
ACDAGSTATNAK	EQU	0Dh	; Not ackowledge to ACDAGSTAT message
ACDCCODE	EQU	0Eh	; Send an ACD call code from CTI
ACDCCODEACK	EQU	0Fh	; Acknowledge to ACDCCODE message
ACDCCODENAK	EQU	10h	; Not acknowledge to ACDCCODE message
ACDGRPINFOQ	EQU	11h	; Request ACD group parameter
ACDTIMOUTPAUS	EQU	12h	; ACD pause time is elapsed
ACDCOMINFOUPD	EQU	13h	; Common ACD parameter update
ACDRRERANSW	EQU	14h	; Report answer of rerouted ACD call
ACDRRERDISC	EQU	15h	; Report disconnect of rerouted ACD call
ACDRRERABAND	EQU	16h	; Report abandon of rerouted ACD call
ACDRTFRANSW	EQU	17h	; Report answer of transferred ACD call
ACDRTFRDISC	EQU	18h	; Report disconnect of transferred ACD call
ACDRTFRABAND	EQU	19h	; Report abandon of transferred ACD call
ACDRCALLTFRORIG	EQU	1Ah	; Report ACD call transfer by originator
ACDRCALLTFRAG	EQU	1Bh	; Report ACD call transfer by agent
ACDRTRSTATIDLE	EQU	1Ch	; Report trunk goes idle
ACDRTRSTATBUSY	EQU	1Dh	; Report trunk is being seized
ACDRONOACDCONN	EQU	1Eh	; Report connect outgoing non ACD call
ACDRONOACDDISC	EQU	1Fh	; Report disconnect outgoing non ACD call
ACDRINOACDANSW	EQU	20h	; Report answer incoming non ACD call
ACDRINOACDDISC	EQU	21h	; Report disconnect incoming non ACD call
ACDALLAGSTATQ	EQU	22h	; Request status info of all agents
ACDALLAGSTAT	EQU	23h	; Response to ACDALLAGSTATQ message
ACDOPDIR	EQU	24h	; Directory numbers of operator
ACDCLERTIMQ	EQU	25h	; Request ACD-group clerical times
ACDCOMINFOQ	EQU	26h	; Request common ACD parameter
ACDNONBUSY	EQU	27h	; ACD-agent busy with non-ACD-calls
ACDNONIDLE	EQU	28h	; ACD-agent finished non-ACD-calls
ACDREROCTIAA	EQU	29h	; ACD call was rerouted by AA for CTI
ACDSEIZREQ	EQU	2Ah	; ACD-agent requests a seizcall message
;-----------------------------------
;REND (subcodes)



;RBEG,SUBCODES
;RCODE, ACDCTRL
;-----------------------------------
;                                 ACDCTRL-message (from CD-block):
ACDACTIVE       EQU    1        ; Agent activated
ACDPASSIVE      EQU    2        ; Agent passivated
ACDDELETED      EQU    3        ; Agent deleted
ACDPAUSE	EQU    4	; Agent paused
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------
;	Common Data Descriptions for ACDINFO-message
;

;	Result codes for ACK-message

AIA_OK		EQU	00h	; Request completely sucessfully completed
AIA_NOPIN	EQU	01h	; No PIN code required
AIA_NOAGNO	EQU	02h	; No agent number required
AIA_NOCCODE	EQU	03h	; No call code required
AIA_NOMIS	EQU	04h	; No MIS link active, continue without MIS
AIA_NOPINAGNO	EQU	05h	; No PIN and agent number required
AIA_NOGRPACTIVE	EQU	06h	; No ACD group is logged in
AIA_ZEROAGNO	EQU	07h	; Agent number is 0, no individual greeting

;	Result codes for NAK-message

AIN_NOAGENT	EQU	80h	; Requested extension is not a ACD agent
AIN_NOREADYKEY	EQU	81h	; ACD agent has not programmed a ready key
AIN_NOPAUSEKEY	EQU	82h	; ACD agent has not programmed a pause key
AIN_INVPIN	EQU	83h	; Invalid PIN code has been received
AIN_INVAGNO	EQU	84h	; Invalid agent number has been received
AIN_INVAGSTAT	EQU	85h	; Invalid agent status has been required
AIN_NOGROUPKEY	EQU	86h	; ACD agent has not programmed at least 1 group
AIN_INVCCODE	EQU	87h	; Invalid call code has been received

;	Type of call for report messages

AIC_INTEX	EQU	00h	; Internal call from extension
AIC_INTOP	EQU	01h	; Internal call from operator
AIC_EXTERN	EQU	02h	; External call from trunk
AIC_INTAGT	EQU	03h	; Internal call from ACD agent
AIC_INTFAC	EQU	04h	; Internal call from facility

;	Traffic information for report messages

AII_NOTS	EQU	00h	; Not specified
AII_DISC	EQU	01h	; Disconnect by originator or terminator
				; (speech)
AII_TFRAFA	EQU	02h	; Transfer by originator or terminator
				; after answer (speech)
AII_CONF	EQU	03h	; Conference is set up
AII_CPPCA	EQU	04h	; Picked up after parked for common access

AII_AREL	EQU	11h	; Release by originator (A-party)
				; before answer (ring)
AII_TFRBFA	EQU	12h	; Transfer by originator (A-party)
				; before answer (ring)

;	Bit positions for ACD common bits

AIB_MISLINK	EQU	00h	; MIS link active
AIB_NONACDCC	EQU	01h	; Callcode for outgoing non-ACD call

;	Bit positions for ACD agent status

AIB_READY	EQU	00h	; Ready
AIB_PAUSE	EQU	01h	; Pause
AIB_CLERICAL	EQU	02h	; Clerical key

;	Bit positions for Callcode information

AIB_LASTTRY	EQU	00h	; Last try for non-ACD call

  PAGE
;----------------------------------------------------------------------------
; 12.10   REROUTE-message, subcodes (cause).    
;----------------------------------------------------------------------------
;        Note, some of these subcodes are used for CILCONREL message too.
;              (keep these subcodes in range 00 - 2F) 
;	 Update always CILCONREL too
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, REROUTE
;-----------------------------------
RER.NOTS        EQU     0       ; Not specified
RER.TFR         EQU     1       ; Transfer.
RER.DNR         EQU     2       ; Diversion on no reply.
RER.BRK		EQU     3       ; Break in.
RER.CNF         EQU     4       ; Conference
RER.OPR         EQU     5       ; Operaror recall, 
                                ; after 'parked by operator'
RER.NIN         EQU     6       ; Information not available,
                                ; do not 'allow infirmation' in the SEIZ..
RER.MG          EQU     7       ; Reroute call to MG ......
RER.TFRBFA      EQU     8       ; Transfer before answer.
RER.CB		EQU	9	; Call back.
RER.ACD		EQU	10	; Reroute of ACD-call.
RER.SIL		EQU	11	; Reroute on silent intrusion.
RER.BRKKEEP	EQU	12	; Reroute, break in, keep display
RER.LCRRDY	EQU	13	; Least cost routing ready
RER.LCRREQ	EQU	14	; Least cost routing request
RER.COBEXT	EQU	15	; Reroute common bell extension
RER.CANSWPOS	EQU	16	; Exit storing and retrieving of messages
RER.NMSG	EQU	17	; Override multiple diversion to MG
RER.FACEXIT	EQU	18	; Exit from a facility to the desired dir.nr.
RER.CTI		EQU	19	; Reroute caused by CTI.
RER.BYP		EQU	20	; Reroute bypassing call diversion
RER.DNA		EQU	21	; Diversion on cordless not available
RER.CNBYP	EQU	22	; Reroute bypassing call diversion
				; at calls to a CN party
RER.CNDNR	EQU	23	; Reroute on no reply to a CN diverted-to party
RER.CNDIV	EQU	24	; Reroute on CN call diversion immediate, on
				; busy or on no reply when diverting party
				; is another PBX
RER.FACBUSY	EQU	25	; Reroute from facility to exit position
				; because the desired party is busy
RER.CNDNA	EQU	26	; Diversion on cordless not available to a
				; CN diverted-to party.
RER.CONREC	EQU     27	; Reroute on conversation recording
RER.3PTYCONF	EQU	28	; Reroute request to EX/OP from TR......
RER.OCN         EQU     29      ; Reroute on outcall notification
RER.MOBEXT	EQU	30	; Reroute on Mobile Extension call
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.11   EU- and IO-messages, subcodes.
;----------------------------------------------------------------------------
; 12.11.1 EUSEIZ subcodes (IO-mode).   
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, EUSEIZ
;-----------------------------------
EUSPRINT	EQU    10h	; Local printing.
EUSDATA		EQU    11h      ; Data transparent, local.
EUSMESS		EQU    14h      ; Message transparent, local.
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.11.2 EUCTRL, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, EUCTRL
;-----------------------------------
EUCSZACK        EQU    00h      ; Seizure (EUSEIZ) acknowledge.
EUCSZNAK        EQU    01h      ; Seizure (EUSEIZ) negative acknowledge.
EUCCALL         EQU    02h      ; Call from connected PC/terminal.
EUCONRDY        EQU    03h      ; Ready for transfer.
EUCONREL        EQU    04h      ; Release IO-connection.
EUCONEND        EQU    05h      ; IO-connection released.
EUCMCALLOW	EQU    06h	; Allow multiplexed communication.
EUCWAITREQ	EQU    07h	; Request to interrupt current output
EUCWAITACK	EQU    08h	; Interrupt acknowledged
EUCWAITNAK	EQU    09h	; Interrupt not acknowledged
EUCWAITRDY	EQU    0Ah	; Current output is copleted, ready to wait
EUCRESUME	EQU    0Bh	; Resume interrupted output
EUCBUSY		EQU    0Ch	; ASB-block is busy, answer to EUCCALL
EUCRDYSWUPD	EQU    0Dh	; Ready for remote software update
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.11.3 IOINIT subcodes.   
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, IOINIT
;-----------------------------------
V24IDLE         EQU    01h      ;RP   Idle.

V24PRINT        EQU    10h      ;RP   Local printing.

V24DATAA        EQU    12h      ;RP   Data transparent, local, A-part.
V24DATAB        EQU    13h      ;RP   Data transparent, local, B-part.

V23DATAA        EQU    22h      ;RP   Data transparent, remote, A-part.
V23DATAB        EQU    23h      ;RP   Data transparent, remote, B-part.
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.11.4 IOCTRL, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, IOCTRL
;-----------------------------------
IOCINITACK      EQU    00h      ;RP   Init acnowledge. 
IOCINITNAK      EQU    01h      ;RP   Init negative acnowledge.
IOCCALL         EQU    02h      ;RP   Call from conneced PC/terminal.
IOCERR          EQU    03h      ;RP   IO-error,(please, release me).
IOCCONREL	EQU    04h	;RP   Release CSM connection
;
IOCSNDREQ       EQU    08h      ;RP   Request of data sending.
IOCSNDRDY       EQU    09h      ;RP   RP ready to send data. (IODATA)
IOCSNDEND       EQU    0Ah      ;RP   No more data to send, stand by.
IOCRECREQ       EQU    0Bh      ;RP   Request of data receiving.
IOCRECRDY       EQU    0Ch      ;RP   CP ready to receive data (IODATA)
IOCRECEND       EQU    0Dh      ;RP   No more to receive, stand by.
IOCNEWPROT	EQU    0Eh	;RP   Change line protocol
IOCMDMRDY	EQU    0Fh	;RP   Modem is ready to send data
IOCSNDENDREQ	EQU    10h	;RP   No more data to send and request
				;     of correct sending to external unit
IOCSNDOUT	EQU    11h	;RP   RP sends current data package to
				;     external unit correctly
IOCSNDCLEAR	EQU    12h	;RP   all temporariliy stored data packages
				;     are deleted
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.11.5 IODATA, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, IODATA
;-----------------------------------
IODSND          EQU    00h      ;RP   Data to external unit.
IODREC          EQU    01h      ;RP   Data from external unit.
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.12   QUEUEINFO, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE,  QUEUEINFO
;-----------------------------------
QUEUEINFOQ      EQU    00h      ; Question of calls in a camp-on queue 
QUEUEINFOANSW   EQU    01h      ; Answer
;-----------------------------------
;REND (subcodes)




;----------------------------------------------------------------------------
; 12.13   OPINFO, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, OPINFO
;-----------------------------------
OPMETER         EQU   00h      ; Set meteringcall info
OPMETERR        EQU   01h      ; Reset meteringcall info
OPSERIAL        EQU   02h      ; Set serialcall info
OPSERIALR       EQU   03h      ; Reset serialcall info
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.14     CONRELCTRL-message, subcodes, info, data
;----------------------------------------------------------------------------
;        *) Note, these subcodes are used to build subcodes for CILCONREL-
; 	          message too. (keep these subcodes in range 00 - 2F)
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CONRELCTRL
;-----------------------------------
CRCREGNEW	EQU	00h	; *) Release, start with new regtone
CRCREGKEEP	EQU	01h	; *) Release, start with new regtone, keep proc
CRCCBBOOK	EQU	02h	; *) Release, book for specified party.
CRCACDRERO	EQU	03h	; Release from ACD, reroute.
CRCLCRBUSY	EQU	04h	; No free trunk after Least cost routing anal.
CRCCALLPROG	EQU	05h	; Release with progress info from net
CRCPICKUP	EQU	06h	; Pickup common bell extension not allowed
CRCPICKUPNR	EQU	07h	; Pickup common bell extension not allowed
				; extension not in ringing state
CRCDISA		EQU	08h	; Setup of transitcall after succesful
				; DISA login
CRCALTROUTE	EQU	09h	; Alternativ routing because of a
				; network specific reason
CRCROP		EQU	0Ah	; 'Switch over' of an ongoing IP-call
CRCRESTONE	EQU	0Bh	; Release connection by the called party
				; requesting special tone.
;-----------------------------------
;REND (subcodes)

;RBEG, OTHERS

; Reason information used for subcode CRCCALLPROG:
;-------------------------------------------------

;			0	;    Zero, not used
CREL.UNDEF	EQU	1	;RP  Undefined reason
CREL.NORM	EQU	2	;RP  Normal release
CREL.BUSY	EQU	3	;RP  Number/destination busy
CREL.BLOCK	EQU	4	;RP  Number/dest. blocked
CREL.VAC	EQU	5	;RP  Number unobtaiable
CREL.INCMPL	EQU	6	;RP  Number incomplete
CREL.CONG	EQU	7	;RP  Congestion, undefined reason
CREL.NOANSW	EQU	8	;RP  No answer from called party
CREL.LINKERR	EQU	9	;RP  Layer 2 not working, ....
CREL.NETFAULT	EQU	10	;RP  Network out of order	
CREL.INCOMPDEST EQU	11	;RP  Incompatible destination, bearer service
				;	not supported by the system
CREL.FACREJ	EQU	12	;RP  Facility rejected
CREL.DESTOUTORD	EQU	13	;RP  Destination out of order
CREL.LICEXCEED	EQU	14	;RP  no IP Voice channel licenses available
				;
CREL.BUSYTRIND	EQU	64	;RP  Trunk ind. is busy in CSW, select next possible 
CREL.CFPR	EQU	65	;RP  Call Forwarding with Partial Rerouting,
				;       disconnection return result
CREL.CCB	EQU	66	;RP  Collected Call Blocked

;REND (others)

  PAGE
;----------------------------------------------------------------------------
; 12.15		TEXTSTRING-message
;----------------------------------------------------------------------------
; 12.15.1	Subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TEXTSTRING
;-----------------------------------
TXTINFOQ	EQU	00h	; Ask for text information
TXTINFOACK	EQU	01h	; Answer with text.
TXTINFONAK	EQU	02h	; Answer without text.
TXTACD		EQU	10h	; Text fom ACD
TXTDINAME	EQU	20h	; Name string information (from DI)
TXTGUESTQ	EQU	30h	; Ask for guest checkin data
TXTGUESTACK	EQU	31h	; Answer, with text for guest
TXTGUESTNAK	EQU	32h	; Answer, without text for guest
TXTFSOPI	EQU	40h	; Name string for free seating CTI OPI
TXT3PTYCONF	EQU	50h	; Feature activation request as display text string response
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.15.2	Other symbols
;----------------------------------------------------------------------------
DI.NAME.LEN	EQU   20	; Length of name string in TXTDINAME 
				; from the telephone directory (DI).
				; (The length is also used in INDDATAANSW
				;  and for other use of this namestring)
  PAGE
;----------------------------------------------------------------------------
; 12.16   MICTRL-message, subcodes and controldata.   
;----------------------------------------------------------------------------
; 12.16.1 MICTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, MICTRL
;-----------------------------------
MIMGIND         EQU   00h      	; Message indication from MG-block
MIININD         EQU   01h      	; Information indication from IN-block
MIHOIND         EQU   02h      	; Wakeup indication, DNDindication,
				; clear last saved number,
				; individual status for RTR and DID
MIEXIND		EQU   03h      	; Voice mail indication from EX-block
MIININDQ	EQU   04h	; Check Voice information from IN-block
MIINREL		EQU   05h	; Release connection and stop play
MIININDANSW	EQU   06h	; Information from IN
MIMGINDQ	EQU   07h	; Check unanswered messages from MG-block
MIMGINDANSW	EQU   08h	; Answer message to MIMGINDQ
MIINDIRECT     	EQU   09h       ; direct diversion
MIINBUSY        EQU   0Ah       ; diversion on busy
MIINNOREPLY    	EQU   0Bh       ; diversion on no reply
MIMGREC		EQU   0Ch	; Conversation recording indication


;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.16.2 MICTRL-message, controldata.   
;----------------------------------------------------------------------------
                               ; On MIMGIND and on MIMGINDANSW
MIMGNONE        EQU    0       ; No message to extension
MIMGX           EQU    1       ; Message exists
MIMGCHECK	EQU    2       ; Message checked

                               ; On MIININD and on MIININDANSW
MIINNONE        EQU    0       ; No information for extension
MIINTEXT        EQU    1       ; Text information active
MIINVOICE       EQU    2       ; Voice information active
MIINPREDEF      EQU    3       ; Predefined information active
MIINGRTON	EQU    4       ; Ind. mailbox greeting exists
MIINGRTOFF	EQU    5       ; Ind. maibox greeting does not exist
MIINOFF		EQU    6       ; Absence info exists, but switched off

                               ; On MIHOIND
MIHONONE        EQU    0       ; Wakeup not ordered for extension
MIHOWAKEUP      EQU    1   	; Wakeup ordered for extension
MIHONODND	EQU    2	; Deactivate Do not disturb for extansion
MIHODND		EQU    3	; Activate do not disturb for extansion
MIHOLSCLR	EQU    4	; Delete last saved number
MIHOINDBARR	EQU    5	; Individual status for RTR and DID

				; On MIEXIND	
MIEXNONE	EQU    0       	; No external voice mail to extension
MIEXVMAIL	EQU    1       	; External voice mail to extension exist

				; On MIINIINDQ
MIINNOPLAY	EQU    0        ; No play, if absence information active
MIINPLAY	EQU    1	; Play voice or predefined info for ext.
MIINRECORD     	EQU    2        ; record personal greeting
MIINERASE      	EQU    3        ; erase personal greeting
MIINSTORE      	EQU    4        ; store personal greeting
MIINREWPLAY	EQU    5	; rewind play during config of pers.gr.

				; On MIINIDANSW
MIINCONN	EQU    4	; Connection with IN established
MIINACK         EQU    5        ; pos. answer for PG request
MIINNAK         EQU    6        ; neg. answer for PG request
MIINFAULT       EQU    7        ; neg. answer for PG request

				; On MIINREL
MIINRELNOANSWER	EQU    0        ; No answer message to MG necessary
MIINRELANSWER	EQU    1	; Answer after VMU channel is released

				; On  MIMGREC
MIMGRECOFF	EQU    0	; Conversation recording off
MIMGRECON	EQU    1	; Conversation recording on
MIMGRECFLASH	EQU    2	; Conversation recording last 10 seconds


  PAGE
;----------------------------------------------------------------------------
; 12.17   REALTIME-message, subcodes.   (used in OU.CALL EU.RTCMESSAGE too)
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, REALTIME
;-----------------------------------
                              ; Used in messages and in the OU.CALL 
                              ; -----------------------------------
                              ; NOTE! this values for periodical messages
                              ;       must be keept in a continous incremen-
                              ;       ting number series with start from 00h
RTCMIN01        EQU   00h     ; Every minute
RTCMIN05        EQU   01h     ; Every 5:th minute
RTCMIN15        EQU   02h     ; Every 15:th minute
RTCMIN30        EQU   03h     ; Every 30:th minute
RTCMIN60        EQU   04h     ; Every 60:th minute
RTCHOUR01       EQU   04h     ; Every hour (same as 60 min)
RTCHOUR03       EQU   05h     ; Every 3:rd hour
RTCHOUR06       EQU   06h     ; Every 6:th hour
RTCHOUR12       EQU   07h     ; Every 12:th hour
RTCHOUR24       EQU   08h     ; Every 24:th hour
                              ;----------------------------------------------


                              ; Used only as subcode in messages:
                              ; ---------------------------------
RTCWR           EQU   40h     ; Write time in time circuit
RTCWRANSW       EQU   41h     ; Answer after a write
RTCRD           EQU   50h     ; Request real time
RTCRDANSW       EQU   51h     ; Answer after a read
                              ;
RTCMINUTE       EQU   60h     ; Periodical minute-message from RP
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.18   VMU- and VM-messages, subcodes.    
;----------------------------------------------------------------------------
; 12.18.1 VMUSEIZ-, VMSEIZ- and VMUSEIZHD-message. 
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, VMUSEIZ
;RCODE, VMSEIZ
;RCODE, VMUSEIZHD
;-----------------------------------
WRINFO          EQU   10h     ;RP   Write (record) voice information
WRMESS          EQU   11h     ;RP   Write voice message
WRANNO          EQU   12h     ;RP   Write voice announcement
RDINFO          EQU   20h     ;RP   Read (play) voice information
RDMESS          EQU   21h     ;RP   Read voice message
RDANNO          EQU   22h     ;RP   Read voice announcement
VMRESERVE		EQU   23h     ;		Reserve a channel at VMU-card
VMRELEASE		EQU   24h     ;		Release a reserved channel at VMU-card 

;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.18.2 VMUSEIZANSW-, VMUSEIZHD-, VMSEIZANSW-,
;         VMUORDERANSW, VMUORDER2-message.
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, VMUSEIZANSW
;RCODE, VMUSEIZHD
;RCODE, VMSEIZANSW
;RCODE, VMUORDERANSW
;RCODE, VMUORDER2
;-----------------------------------
VMACK           EQU    0      ;RP   Seizure accepted
VMRESACK        EQU    1      ;     Reservation of a VMU-channel accepted
VMNAKBUSY       EQU    2      ;RP   Seizure rejected, channel busy
VMNAKREF        EQU    3      ;RP   Seizure rejected, reference error
VMNAKCAP        EQU    4      ;RP   Seizure rejected, capacity shortage
VMNAKINS        EQU    5      ;RP   Seizure rejected, card not installed
VMNAKPROG       EQU    6      ;RP   Seizure rejected, no reference for the dir.no
VMNAKTO         EQU    7      ;RP   Seizure rejected, time out (no VMU-answer)
VMNAKBLK        EQU    8      ;RP   Seizure rejected, no card or no time allocated
VMNAKQ			EQU    9      ;		Reservation not possible
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.18.3  VMUDATAANSW, VMUCTRLDATA-message.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, VMUDATAANSW
;RCODE, VMUCTRLDATA
;-----------------------------------
VMREFACK        EQU    0      ;RP   Reference found
VMREFNAK        EQU    1      ;RP   Reference not found
VMREFERR        EQU    2      ;RP   Reference error
;                      3            see 12.18.6
;                      4            see 12.18.6
PREDEFACK       EQU    5      ;RP   deliveres references
PREDEFNAK       EQU    6      ;RP   no VMU-HD or storing not allowed
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.18.4  VMUORDER- and VMUORDER2-message.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, VMUORDER
;RCODE, VMUORDER2
;-----------------------------------
ERINFO          EQU    30h    ;RP   Erase one voice information
ERMESS          EQU    31h    ;RP   Erase one voice message
ERANNO          EQU    32h    ;RP   Erase one voice announcement
CLINFO          EQU    40h    ;RP   Erase all voice informations
CLMESS          EQU    41h    ;RP   Erase all voice messages
CLANNO          EQU    42h    ;RP   Erase all voice announcements
CLALL           EQU    50h    ;RP   Erase all
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.18.5 VMCTRL-message.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, VMCTRL
;-----------------------------------
VMPLAY          EQU    10h    ;RP Start play
VMREWPLAY       EQU    11h    ;RP Rewind and start play
VMSTOP          EQU    12h    ;RP Stop
VMEXIT          EQU    13h    ;RP Release connection without storing/erase

VMREC           EQU    20h    ;RP Start record
VMREWREC        EQU    21h    ;RP Rewind and start record
VMSTORE         EQU    22h    ;RP Store information and release connection

VMPLAYRESA	EQU    25h    ;	  Start playing of announcment
VMPLAYRESI	EQU    26h    ;	  Start playing of information
VMPLAYRESM	EQU    27h    ;	  Start playing of message

VMTIM           EQU    30h    ;RP Time information
VMPLAYRDY       EQU    31h    ;RP End of play 
VMRECEND        EQU    32h    ;RP End of record
VMREL           EQU    33h    ;RP Answer on a VMEXIT or a VMSTORE
VMSTORERDY      EQU    34h    ;RP Answer on a VMSTORE
VMRELRES	EQU    35h    ;	  Answer signal to CP block form VM
VMRECSIL	EQU    36h    ;RP Silence detected

VMSTATE		EQU	040h  ;   Report current CTI state
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.18.6  VMUCTRLDATA-message.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, VMUCTRLDATA
;-----------------------------------
;			0		see 12.18.3
;			1		see 12.18.3
;			2		see 12.18.3
DATAQ		EQU	3	;RP	Data information about VMU-HD
PREDEF		EQU	4	;RP	Inquire prerecorded announcements
;			5		see 12.18.3
;			6		see 12.18.3
RESOURCE	EQU	7	;RP	Resource information about VMU-HD
;-----------------------------------
;REND (subcodes)


  PAGE
;----------------------------------------------------------------------------
; 12.19   METER- messages, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, METER
;-----------------------------------
METSTART	EQU	 0	;RP   Init metering
METCHANGE	EQU	 1	;RP   Int metering for new extension/trunk
METREL		EQU	 2	;RP   Stops metering
METRDYCHG	EQU	 3	;RP   Metering for a call is ended and restarted
METRDYREL	EQU	 4	;RP   Metering for a call is ended and released
METCONQ		EQU	 5	;RP   Ask for pulses and duration
METANSW		EQU	 6	;RP   Answer
;			7
;			8
METSEIZ		EQU	 9	;RP   Seizure of a meter
METSEIZACK	EQU	10	;RP   Answer, metering present and available
METSEIZNAKNA	EQU	11	;RP   Answer, metering equipment not present
METSEIZNAKB	EQU	12	;RP   Answer, metering equipment busy
;			13	;
METAOCNAK	EQU	14	;RP   Reject of metering at ISDN
METREADCALL	EQU	15	;     Answer message for current call
METRESETCALL	EQU	16	;     Reset addressed accumulator of a caller
METACKCALL	EQU	17	;     Answer contained accumulated pulses...
METNAKCALL	EQU	18	;     Negative answer to read or reset.....
METCONANSW	EQU	19	;     Answer message for current call
METLASTCALL	EQU	20	;     Last adding to meter of caller
METSAVECALL	EQU	21	;     Adding to meter of a caller
METLASTTRNK	EQU	22	;     Last adding to meter of a trunk
METSAVETRNK	EQU	23	;     Adding to meter of a trunk
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.20    CIL- messages, subcodes and data.
;----------------------------------------------------------------------------
; 12.20.1  CILCONDAT, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CILCONDAT
;-----------------------------------
CLINIT     EQU     0    ; 
CLINITTR   EQU     1    ;
CLCDTEST   EQU     2    ;
CLRECALL   EQU     3    ;
CLTAG      EQU     4    ;
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.20.2  CILCONSTAT, subcodes
;----------------------------------------------------------------------------
; CON.----              ; Subcodes from CONCTRL-message are used (range 00-2F)


;----------------------------------------------------------------------------
; 12.20.3  CILDIGSEND, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CILDIGSEND
;-----------------------------------
				; Subcodes
CLDIG		EQU	0	; Digits transmitted to external destination
CLACCINIT	EQU	1	; (Re)start reception of Account Code digits
CLACCDIG	EQU	2	; Account Code digits
CLLCRDIAL	EQU	3	; Dialled digits at LCR-analysed calls
CLLCRSENT	EQU	4	; Sent digits at LCR-analysed calls
CLPNRSENT	EQU	5	; Sent digits at private network router
CLACCREQ	EQU	6	; Request for Account Code digits
CLACCACK	EQU	7	; Sending of Accout Code
CLACCNAK	EQU	8	; No Accout Code
;-----------------------------------
;REND (subcodes)

CLVLDSND   EQU     0    ; Validity data
CLVLDCON   EQU     1    ;
  PAGE
;----------------------------------------------------------------------------
; 12.20.4  CILCONREL
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CILCONREL
;-----------------------------------
; RER.---- 			; Subcodes from REROUTE-message are used 
;				; (range 00-2F)
				;--------------
;R  RER.NOTS	EQU RER.NOTS	;0	; Not specified
;R  RER.TFR	EQU RER.TFR	;1	; Transfer.
;R  RER.DNR	EQU RER.DNR	;2	; Diversion on no reply.
;R  RER.BRK	EQU RER.BRK	;3	; Break in.
;R  RER.CNF	EQU RER.CNF	;4	; Conference
;R  RER.OPR	EQU RER.OPR	;5	; Operaror recall, 'parked by op'
;R  RER.NIN	EQU RER.NIN	;6	; Information not available....
;R  RER.MG	EQU RER.MG	;7	; Reroute call to MG ......
;R  RER.TFRBFA  EQU RER.TFRBFA	;8	; Transfer before answer.
;R  RER.CB	EQU RER.CB	;9	; Call back.
;R  RER.ACD	EQU RER.ACD	;10	; Reroute of ACD-call.
;R  RER.SIL	EQU RER.SIL	;11	; Reroute on silent intrusion.
				; -------------
				; Subcodes CRC- from CONRELCTRL-message are 
				; used (range 00-2F gives here range 30-5F)
CLREGNEW  EQU	CRCREGNEW+30h	; Release, start with new regtone
CLREGKEEP EQU	CRCREGKEEP+30h	; Release, start with new regtone, keep proc
CLCBBOOK  EQU	CRCCBBOOK+30h	; Release, book for specified party.
                 		;--------------
CLSZBOOK  EQU	60h		; Call rerouted or transferred
CLMETER   EQU	61h		; Update metering information
CLCONSENT EQU	62h		; CONREL is sent and connection released
CLCONREC  EQU	63h		; CONREL is received and connection released
				;--------------
CLBUFCONG EQU	90h		; Free logging buffer not available
CLACCONG  EQU	91h		; Account code not dialled
CLACCERR  EQU	92h		; Faulty account code dialled
CLCFPR    EQU   93h             ; Partial rerouting
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.20.5	CILSERVICE, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CILSERVICE
;-----------------------------------
CNTFR		EQU	0	; at CN transfer
CFPR		EQU	1	; at Partial Rerouting (ISDN suppl. service)
THREEPTYCONF	EQU	2	; at 3 party conference (ISDN stimulus service)
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.21    DIGREQ- messages, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, DIGREQ
;-----------------------------------
DIGTFRQ     EQU    0           ; Question of operators pre-dialled digits
DIGTFRANSW  EQU    1           ; Answer on DIGTFRQ
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.22    PCCTRL- messages, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, PCCTRL
;-----------------------------------
PCCPWNAK	EQU    0	; Neg acknowledge
PCCPWACK	EQU    1	; Acknowledge
PCCPWRD		EQU    2	; Password read
PCCPWRDANSW	EQU    3	; Password read, answer
PCCPWWR		EQU    4	; Password write
PCCCONREL	EQU    5	; Connection release
PCCACCESS	EQU    6	; Accesslevel request
PCCACCESSANSW	EQU    7	; Accesslevel respond
PCCTRANSP	EQU    8	; Transparent communication with EC
PCCRECALL	EQU    9	; Recall proceed control (from EC)
PCCRECALLQ	EQU   10	; Recall question (from EC)
PCCRECALLANSW	EQU   11	; Recall answer (from CP)
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.23    MISTOCLR- messages, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, MISTOCLR
;-----------------------------------
MIMGCLRTO   EQU    0           ; Clear all messages to extension
MIMGSTORE   EQU    1           ; Store 'call-me' message
MIINCLR     EQU    2           ; Clear information for extension
MIMGERASE   EQU    3           ; Erase message
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.24    GUESTINFO- message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, GUESTINFO
;-----------------------------------
HOGUESTOFF  EQU    0           ; Guest extension facillity deactivated
HOGUESTON   EQU    1           ; Guest extension facillity activated
HOGUESTACK  EQU    10h         ; Operation successed
HOGUESTNAK  EQU    11h         ; Operation failed
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.25    CPJOB. Used from TSTX card
;
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CPJOB
;-----------------------------------
CPJUNDEF	EQU	000h	;RP  Job undefined 

CPJPRODNUM	EQU	010h	;RP  Ask of part of CXC-number
CPJPRODNUMANSW	EQU	011h	;RP  Answer

CPJSETFORMAT	EQU	020h	;RP  Set communication format

CPJREAD		EQU	030h	;RP  Read CP-memory
CPJREADI	EQU	031h	;RP  Read CP-memory, indirect
CPJREADIND	EQU	032h	;RP  Read CP-memory, individual ram
CPJREADANSW	EQU	03Fh	;RP  Answer

CPJTESTSTART	EQU	040h	;RP  Setup message for test
CPJTESTLOG	EQU	041h	;RP  Setup message for starting log
CPJTESTEND	EQU	042h	;RP  Test disable
CPJTESTLOGMPD	EQU	043h	;RP  Setup message for starting log for MPD

CPJTESTBOARD	EQU	050h	;RP  Identification of testboard 

CPJOMPCCOM	EQU	0E0h	;RP  Command to PC handler in OM-block.

CPJMESS		EQU	0F0h	;RP  A short message packed and sent in com-
                        	;    plete form with one CPJOB-message
CPJMESSFST	EQU	0F1h	;RP  First part of a long, packed, message.
CPJMESSMID	EQU	0F2h	;RP  Middle parts, of a packed message.
CPJMESSLST	EQU	0F3h	;RP  Last part of a packed message.       
;-----------------------------------
;REND (subcodes)

;-----------------------------------
;	Values for DATA-area
;
;RBEG,OTHERS

TESTBOARD.CPUD4	EQU	01h	;RP  testboard is CPU-D4

;REND (others)


  PAGE
;----------------------------------------------------------------------------
; 12.26    ELPAR-message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ELPAR
;-----------------------------------
ELPCOMA		EQU	00h	;RP   Common parameters
ELPTRANSMA	EQU	01h	;RP   Transmission parameters ELUA
ELPRINGCADA	EQU	02h	;RP   Ring cadences for ELUA
ELPRINGCADC	EQU	03h	;RP   Ring cadences for ELUC
ELPRINGCADD	EQU	04h	;RP   Ring cadences for ELUD
ELPRINGDEFD	EQU	05h	;RP   Ring character, volume
ELPTRANSMD	EQU	06h	;RP   Transmission parameters ELUD
ELPALRTIM	EQU	07H	;RP   Alerting timeout parameter ICCU2
ELPLCDCHG	EQU	08H	;RP   Changed display handling for ELUDs

ELPACK		EQU	80h	;RP   Parameter okay
ELPNAK		EQU	81h	;RP   Parameter not okay
;-----------------------------------
;REND (subcodes)


  PAGE
;----------------------------------------------------------------------------
; 12.27    E2STATUS message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, E2STATUS
;-----------------------------------
E2STATMAPQ	EQU	1	; E2 status question, single map
E2STATALLQ	EQU	2	; E2 status question, all maps
E2STATANSW	EQU	3	; E2 status answer
E2TEST  	EQU	4	; E2 test request
E2TESTANSW	EQU	5	; E2 test answer
E2TESTERROR	EQU	6	; E2 test error
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.28    PGINFO message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, PGINFO
;-----------------------------------
PGINPROG	EQU	00h	; Paging in progress
PGABSENCE	EQU	01h	; Paged party not present
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.29    TRTRANSIT message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TRTRANSIT
;-----------------------------------
TRSEOSF		EQU	00H	; End of selection, free
TRSEOSB		EQU	01H	; End of selection, busy
TRSENDS		EQU	02H	; End signal

TRSSUBS		EQU	10h	; Calling party is a subscriber
TRSOPER		EQU	11h	; Calling party is an operator
TRSADIG		EQU	12h	; A-number digit
TRSAEND		EQU	13h	; End of A-number
TRSAREJ		EQU	14h	; Request of A-number rejected
TRSEXTDIV	EQU	15h	; External diverted call

TRSACAT		EQU	20h	; Request of A-chategory
TRSADDCMP	EQU	21h	; Complete address
TRSBAR		EQU	22h	; Congestion or barred number
TRSBUSY		EQU	23h	; Called party busy
TRSCONG		EQU	24h	; Congestion before complete address
TRSFREE		EQU	25h	; Called party free
TRSSETUP	EQU	26h	; No result available, setup speech
TRSUNALLO	EQU	27h	; Unallocated number
TRSNXTDIG	EQU	28h	; Transfer of next digit
TRSREQANO	EQU	29h	; A-number request
TRSREQCLL	EQU	2Ah	; A-number request to incoming conn. TRUNK
TRSREQGRA	EQU	2Bh	; A-group digits of B-number req...-''-
TRSREQGRC	EQU	2Ch	; C-group digits of B-number req...-''-
TRSREQALL	EQU	2Dh	; All digits of B-number req.......-''-
TRSSUBREJ	EQU	2Eh	; Request of A-category rejected
TRSLINEOUT	EQU	2Fh	; Lineout before complete address

TRSIRELEASE	EQU	40h	; ISDN trunk has been released
TRSIFREE	EQU	41h	; IDSN trunk is released and free
TRSIPROGRESS	EQU	42h	; Informs opposite ISDN party that ISDN trunk
				; received SISIG,SIPROGRESS
				; (with transparent data)

				; Transparent transfer of ISDN data
				; between two TR parties :
TRSIFDATA	EQU	45h	; i->o
TRSIFDATAEND	EQU	46h	; o->i ended
TRSIBDATA	EQU	47h	; i->o
TRSIBDATAEND	EQU	48h	; o->i ended
TRSISETUP	EQU	49h	; Sends SISETUP data to opposite trunk
TRSICNSETUP	EQU	4Ah	; Sends SICNSETUP data to opposite trunk
TRSIUUISETUP	EQU	4Bh	; Sends SIUISETUP to opposite trunk
TRSISEIZACK	EQU	4Ch	; Seizure acknowledge from FW on outgoing side
TRSICNALERT	EQU	4Dh	; Sends SICNALERT data to opposite trunk
TRSIUUIALERT	EQU	4Eh	; Sends SIUUIALERT data to opposite trunk
TRSIADDUUIALERT	EQU	4Fh	; Sends SIUUIBANSWER data to opposite trunk
TRSISPEECH	EQU	50h	; Sends SIBANSWER data to opposite trunk
TRSICNSPEECH	EQU	51h	; Sends SICNBANSWER to opposite trunk
TRSIUUISPEECH	EQU	52h	; Sends SIUUIBANSWER to opposite trunk
TRSICNDISC	EQU	53h	; Sends SICNDISC data to opposite trunk
TRSIUUIDISC	EQU	54h	; Sends SIUUIDISC data to opposite trunk
TRSIUUI		EQU	55h	; Sends SIUUIIN data to opposite trunk
TRSIADDUUI	EQU	56h	; Sends SIADDUUIIN data to opposite trunk
TRSIFACILITY	EQU	57h	; Sends SIFACILITY data to opposite trunk
TRSIUUISERVICE	EQU	58h	; Sends SIUUISERVICE data to opposite trunk
TRSIVIRSEIZACK	EQU	59h	; Seizure acknowledge from FW on outgoing side

TRSIRGSDIGIT	EQU	70h	; Sends data received in SIRGSDIGIT to opp. trunk

TRSLOCSPEECH	EQU	0B4h	; MFC transit, call category : local speech
TRSLOCDATA	EQU	0B5h	; MFC transit, call category : local data
TRSSEMIAUTO	EQU	0B6h	; MFC transit, call category : semi automatic
TRSTOLLCALL	EQU	0B7h	; MFC transit, call category : toll automatic
TRSTESTCALL	EQU	0B8h	; MFC transit, call category : test

;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.30    HOCIL-messages, subcodes.
;----------------------------------------------------------------------------
;          			For HOCILINPUT- and HOCILOUTPUT-messages
; 
;RBEG,SUBCODES
;RCODE, HOCILINPUT
;RCODE, HOCILOUTPUT
;-----------------------------------
CLHOCHECKIN	EQU	1	; Checkin
CLHOCHECKOUT	EQU	2	; Checkout
CLHOUPDATE	EQU	3	; Update Guest
CLHOMESSORD	EQU	4	; Message Order
CLHOMESSCLR	EQU	5	; Message Clear
CLHOWAKEORD	EQU	6	; Wake-Up Order
CLHOWAKEANS	EQU	7	; Wake-Up Answer
CLHOWAKECLR	EQU	8	; Wake-Up Clear
CLHOBAR		EQU	9	; Phone Barring
CLHOUNBAR	EQU	10	; Phone Unbarring
CLHOROOMSTAT	EQU	11	; Room Status
CLHOPHONE	EQU	12	; Phone Status
CLHOGUEST	EQU	13	; Guest Data
CLHOBARSTAT	EQU	14	; RTR/DID Status
CLHOBARALL	EQU	15	; All guest extensions are barred to do
				; outgoing calls because of an overflow
				; concerning the CIL buffers
CLHOUNBARALL	EQU	16	; All guest extension barring status are
				; restored because there are CIL bufers
				; available again
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.31    UPDCARD-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, UPDCARD
;-----------------------------------
SUCARDDEL	EQU	1	; E2-data for a removed card will be deleted.
SUCARDINS	EQU	2	; E2BASE areas for a new card are installed.
SUSHDWNREQ	EQU	3	; Request shutdown of card
SUSHDWNEXEC	EQU	4	; Execute card shutdown
SUSHDWNACK	EQU	5	; Acknowledge to SUSHDWNREQ and SUSHDWNEXEC
SUSHDWNDEL	EQU	6	; Delete card after shutdown
SUSHDWNDELACK	EQU	7	; Acknowledge to SUSHDWNDEL
SUSHDWNINS	EQU	8	; ShutDown of VMU-HD unit
SUSHDWNAUT	EQU	9	; Automatic restart of VMU-HD unit
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.32     ACBCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE,  ACBCTRL
;-----------------------------------
ACBDEL		EQU	0	; Delete callback orders
ACBCNDEL	EQU	1	; Delete CN call back mission request
ACBCNDELANSW	EQU	2	; Answer to delete CN call back mission request
ACBCNACT	EQU	3	; CN call back free notification
ACBCNACTANSW	EQU	4	; Answer to CN call back free notification
ACBCNDELINFO	EQU	5	; CN call back mission was deleted
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.33     NEWNO-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, NEWNO
;-----------------------------------
NEW.ABBR	EQU	0	; New number, from abbreviated dialling
NEW.NAME	EQU	1	; New number, from directory book
NEW.LNR		EQU	2	; New number, from last dialled number
NEW.SNR		EQU	3	; New number, from last saved number
NEW.CTI		EQU	4	; New number, from telephony server
NEW.VPN		EQU	5	; New number, from virtual private networking
NEW.ABBI	EQU	6	; New number, from ind. abbr. dialling
NEW.CI		EQU	7	; New number, from ISDN caller list
NEW.IED		EQU	8	; New number, from ind. ext. diversion
NEW.ROP		EQU	9	; New number, for route optimizing
NEW.MOBEXT	EQU	10	; New number, from Mobile Ext. assignm. list
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.34     E2RECORD, E2ACK and E2NAK-message, subcodes.
;----------------------------------------------------------------------------
;		For these messages an Information code is used as subcode.
;		The definitions here are maid for extraction of subcodes for
;		external files (Test-tool 'WILMER' and 'RASC')
;		All information codes are not vallid for all three messages,
;		see message descriptions for details.
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, E2RECORD
;RCODE, E2ACK
;RCODE, E2NAK
;-----------------------------------
;R    E2BASRD	EQU	E2BASRD
;R    E2BASRL	EQU	E2BASRL
;R    E2BASSZ	EQU	E2BASSZ
;R    E2BASWR	EQU	E2BASWR
;R    E2RECRD	EQU	E2RECRD
;R    E2RECRL	EQU	E2RECRL
;R    E2RECSZ	EQU	E2RECSZ
;R    E2RECWR	EQU	E2RECWR
;R    E2RD	EQU	E2RD
;R    E2WR	EQU	E2WR
;R    E2BASSWAP	EQU	E2BASSWAP
;R    E2RECORD	EQU	E2RECORD

E2RECRDFST	EQU	0EDh	; Read first record linked to basic E2-record
E2RECRDNXT	EQU	0EEh	; Read next record linked to basic E2-record
E2BASPRMRD	EQU	0EFh	; Read  programming model number of E2-base
E2BASPRMWR	EQU	0F0h	; Write programming model number of E2-base
E2RECPRMRD	EQU	0F1h	; Read  programming model number of E2-record
E2RECPRMWR	EQU	0F2h	; Write programming model number of E2-record

CERECCREATE	EQU	01h	; Indication for application blocks that CE
				; has seized additional E2 record
				; (contents only data converted by CE)

;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.35     ECCOM-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ECCOM
;-----------------------------------
ECBASRD		EQU	00h	; E2base-connected messages, forward
ECBASWR		EQU	01h	;
ECBASSZ		EQU	02h	;
ECBASRL		EQU	03h	;
ECBASSWAP	EQU	04h	;

ECBASRDANSW	EQU	10h	; E2base-connected messages, backward
ECBASWRANSW	EQU	11h	;
ECBASSZANSW	EQU	12h	;
ECBASRLANSW	EQU	13h	;
ECBASSWAPANSW	EQU	14h	;

ECRECRD		EQU	20h	; E2record-connected messages, forward
ECRECRDFST	EQU	21h	;
ECRECRDNXT	EQU	22h	;
ECRECWR		EQU	23h	;
ECRECSZ		EQU	24h	;
ECRECRL		EQU	25h	;

ECRECRDANSW	EQU	30h	; E2record-connected messages, backward
ECRECRDFSTANSW	EQU	31h	;
ECRECRDNXTANSW	EQU	32h	;
ECRECWRANSW	EQU	33h	;
ECRECSZANSW	EQU	34h	;
ECRECRLANSW	EQU	35h	;

ECPRRD		EQU	40h	; PR-family-connected messages, forward
ECPRWR		EQU	41h	; 

ECPRRDANSW	EQU	50h	; PR-family-connected messages, backwards
ECPRWRANSW	EQU	51h	; 

ECDEFPRM	equ	60h	; Define programmodel
ECDEFPRMSTOP	equ	61h	;

;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.36     NUMINFO-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, NUMINFO
;-----------------------------------
NUM.NEWORIG	EQU	0	; Display new original number
;-----------------------------------
;REND (subcodes)




;----------------------------------------------------------------------------
; 12.37	 CONINFO -message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CONINFO
;-----------------------------------
CONI.REAACT	EQU	00h	; Reanswer function activated
CONI.REAREL	EQU	01h	; Release during activated reanswer
CONI.REANSW	EQU	02h	; Reanswer during activated reanswer 
CONI.KEYREQ	EQU	03h	; Request of one key from the orginator
CONI.CALLPROG	EQU	04h	; Call progress info, from external party
CONI.KEYRES	EQU	05h	; Trunk must reset the keybuffer
CONI.CNDIV	EQU	06h	; Diversion was executed in another CN PBX
CONI.CNDNR	EQU	07h	; Diversion info was forwarded to term. PBX
CONI.CNSOR	EQU	08h	; Signal to term. to initiate ringing
CONI.CNTFR	EQU	09h	; New connected provate identity
CONI.ANUM	EQU	0Ah	; Calling party number
CONI.FREL	EQU	0Bh	; A-party requests forced release of C-party
CONI.ACDTFR	EQU	0Ch	; CONINFO ACD transfer
CONI.BUSY	EQU	0Dh	; Call queued because of busy destination
CONI.REGREQ	EQU	0Eh	; Request DTMF register
CONI.REGACK	EQU	0Fh	; Register posivite acknowledge
CONI.REGNAK	EQU	10h	; Register negative acknowledge
CONI.REGREL	EQU	11h	; Register release
CONI.RELREQ	EQU	12h	; Release request from connected party
CONI.SUSPEND	EQU	13h	; Call suspended

;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.38     ELCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ELCTRL
;-----------------------------------
ELCKEYREL	EQU	01h	;RP   Control of INSTRTYPE messages
ELCLINEBR	EQU	02h	;RP   Order linebreak
ELCINDMODEC	EQU	03h	;RP   Instrument mode for ELUC
ELCINDMODED	EQU	04h	;RP   Instrument mode for ELUD
ELCFUNC		EQU	05h	;RP   Function control
ELCTONE		EQU	06h	;RP   Start/stop tonesending
ELCANAMODE	EQU	07h	;RP   Mode control (ELUA)
ELCLEVELD	EQU	08h	;RP   Loudspeaker and earpice level (ELUD)
ELCDIR		EQU	09h	;RP   Accociated directory number
ELCLCDPAR	EQU	0Ah	;RP   Special cordless display characters 
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.39	 CARDREP-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CARDREP
;-----------------------------------
CREPORT		EQU	00h	;RP   Card report request
CREPORTANSW	EQU	10h	;RP   Card report answer
CTYPEANSW	EQU	11h	;RP   Card type answer
CVTREP		EQU	12h	;RP   Card report info for virtual card
CVTREPANSW	EQU	13h	;RP   Card report answer for virtual card
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.40	 BTCORDER-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, BTCORDER
;-----------------------------------
;			0	;     not used
BTOSEIZURE	EQU	01h	;RP   Seizure trunk for outgoing call
BTODETEPTS	EQU	02h	;RP   Detect 'proceed to send' signal
BTOSTDEPTS	EQU	03h	;RP   Stop detect 'proceed to send' signal
BTOPARKING	EQU	04h	;RP   Put trunk in parking condition
BTOSPEECH	EQU	05h	;RP   Put trunk in speech condition 
BTORELEASE	EQU	06h	;RP   Send release to PE
BTOFWEOS	EQU	07h	;RP   Forward EOS (registersignalling ready)
;BTO		EQU	08h	; 
BTOINQUIRY	EQU	09h	;RP   Initiate inquiry in PE
BTOSEOSFREE	EQU	0Ah	;RP   Send EOS signal, extension free
BTOSEOSBUSY	EQU	0Bh	;RP   Send EOS signal, extension busy
BTOBLOCK	EQU	0Ch	;RP   Block individual trunk
BTODEBLOCK	EQU	0Dh	;RP   Deblock individual trunk
BTOSENDPTS	EQU	0Eh	;RP   Send 'proceed to send' signal
BTOSEOS		EQU	0Fh	;RP   Send EOS signal

BTOSENDPES	EQU	10h	;RP   Send (periodic) end signal
BTOSENDSEIZ	EQU	11h	;RP   Send seize signal to PE
BTOSENDREL	EQU	12h	;RP   Send release signal to to PE
BTODETESPTS	EQU	13h	;RP   Detect special proceed-to-send signal

BTOSEIZACK	EQU	20h	;RP   Seizure accepted
BTOSEIZNAK	EQU	21h	;RP   Seizure rejected
BTOLOOP		EQU	22h	;RP   Loop back line on net side
BTODELOOP	EQU	23h	;RP   Stop loop back line on net side

;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.41	 BTCPAR-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, BTCPAR
;-----------------------------------
BTPAN1		EQU	00h	;RP   Parameters for analogue trunk
BTPAN2		EQU	01h	;RP   Additional  -''-
BTPCASI		EQU	02h	;RP   Parameters for CAS trunks
BTPCASC		EQU	03h	;RP   Parameters for CAS link
BTPISDNPC	EQU	04h	;RP   Parameters for ISDN-trunk
BTPSBAC		EQU	05h	;RP   Parameters for ISDN BA, S-interface
BTPISDNPCI	EQU	06h	;RP   Parameters for ISDN PRA/BTA
BTPSBACI	EQU	07h	;RP   Parameters for ISDN BA
BTPISDNINFCI	EQU	08h	;RP   Information for ISDN PRA/BTA
BTPMCINFO	EQU	09h	;RP   Packet mode comm. link param. for BA,(T-,S-)
BTPACK		EQU	0Ah	;RP   Parameters are accepted
BTPNAK		EQU	0Bh	;RP   Parameters are rejected

BTPAN1READ	EQU	20h	;RP   Read parameters from analogue trunk
BTPAN2READ	EQU	21h	;RP   Read additional parameters -''-
BTPCASIREAD	EQU	22h	;RP   Read parameters from CAS trunk
BTPCASCREAD	EQU	23h	;RP   Read parameters from CAS link
BTPISDNPCREAD	EQU	24h	;RP   Read parameters from PRA/BRA T-interface
BTPSBACREAD	EQU	25h	;RP   Read parameters from ISDN BA S-interface
;-----------------------------------
;REND (subcodes)


  PAGE
;----------------------------------------------------------------------------
; 12.42	 BTCSIGNAL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, BTCSIGNAL
;-----------------------------------
;		EQU	00h	;     reserved for RP
BTSDETEPTS	EQU	01h	;RP   'Proceed to send' detected
;BTS		EQU	02h	; 
BTSBANSWER	EQU	03h	;RP   B-answer
BTSLINEOK	EQU	04h	;RP   Trunk line OK
BTSLINFAUL	EQU	05h	;RP   Trunk line faulty
BTSEOS		EQU	06h	;RP   'End of selection' detected
BTSDIGIT	EQU	07h	;RP   Digit received
BTSINCCALL	EQU	08h	;RP   Incoming call
BTSINCDID	EQU	09h	;RP   Indialling call
BTSINCIOP	EQU	0Ah	;RP   Incoming call with internat. operator
BTSINCRING	EQU	0Bh	;RP   Incoming call with external ring signal
BTSDETEPES	EQU	0Ch	;RP   Periodic end signal detected
BTSINQUIRY	EQU	0Dh	;RP   Inquiry signal detected
BTSDISCONN	EQU	0Eh	;RP   Disc. or time out at incoming ring
BTSFREE		EQU	0Fh	;RP   Trunk is free
BTSPAGING	EQU	10h	;RP   Paging in progress
BTSPAGABS	EQU	11h	;RP   Paging equipment absent
BTSBLOCKED	EQU	12h	;RP   Trunk line blocked
BTSDEBLOCK	EQU	13h	;RP   Trunk line deblocked
BTSEOSFREE	EQU	14h	;RP   EOS detected, subscriber free
BTSEOSBUSY	EQU	15h	;RP   EOS detected, subscriber busy
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.43	 BTLSUP-message, subcodes and data.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, BTLSUP
;-----------------------------------
BTLERRP1	EQU	 0	;RP   Alarm, prio 1
BTLERRP2	EQU	 1	;RP   Alarm, prio 2
BTLSLIP		EQU	 2	;RP   Slip detected
BTLNAT		EQU	 3	;RP   Alarms international/nationa bits
BTLDISC		EQU	 4	;RP   Order to TR, disconnect outgoing calls
BTLBLOCK	EQU	 5	;RP   Order to TR, block trunk for outg. traf.
BTLNOERR	EQU	 6	;RP   No error (disable blocking)
BTLSYNCEN	EQU	 7	;RP   Enable sync. of system (from trunk)
BTLSYNCDIS	EQU	 8	;RP   Disable syncronisation of system 
BTLSCENACK	EQU	 9	;RP   Acknowledge of synk. enable
BTLSCDISACK	EQU	10	;RP   Acknowledge of synk. disable
BTLINKBLOCK	EQU	11	;RP   Order to block link for traffic
BTLINKDEBLOCK	EQU	12	;RP   Order to deblock link for traffic
BTLL2ERR	EQU	13	;RP   Alarm cond...layer 2 on ISDN-trunk
BTLTEI		EQU	14	;RP   TEI assignment for the specific ISDN link
;-----------------------------------
;REND (subcodes)

;RBEG,OTHERS
; Bit positions for alarm in BTLERRP1

BTLLOSBIT	EQU	0	;RP   LOS, loss of signal
BTLAISBIT	EQU	1	;RP   ALS, alarm indication signal
BTLLFABIT	EQU	2	;RP   LFA, loss of frame sync
BTLEBRBIT	EQU	3	;RP   EBR, excessive biterror rate

; Bit positions for alarm in BTLERRP2

BTLRAIBIT	EQU	0	;RP   RAI, remote alarm indication
BTLLMFBIT	EQU	1	;RP   LMF, loss of multiframe sync
BTLLMFRBIT	EQU	2	;RP   LMFR, remote loss of multiframe sync
BTLCCEIBIT	EQU	3	;RP   CCEI, continuous CRC error information

;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.44	 IMPCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, IMPCTRL
;-----------------------------------
IMPSEND		EQU	00h	;RP   Start digit impulsing
IMPSTOP		EQU	01h	;RP   Stop digit impulsing
IMPRDY		EQU	02h	;RP   Digit impulsing ready
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.45	 MPCONANSW-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, MPCONANSW
;-----------------------------------
MPCACK		EQU	0	; Acknowledge of MPCON
MPCNAK		EQU	1	; Unsuccessful connection
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.46	 REGCTRL-message, subcodes and data.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE,  REGCTRL
;-----------------------------------
;	Subcodes for register control:

RGCSEIZ		EQU	 1	;     Seize register		TR->RS
RGCREL		EQU	 2	;RP   Release register		TR->RS->RSU
RGCCHANGE	EQU	 3	;RP   Change signalling		TR->RS->RSU
RGCRELFR	EQU	 4	;     Force Release register
				;     sequence			RS->TR

RGCSTART	EQU	10h	;RP   Start register sign.	RS->RSU
RGCPCM		EQU	11h	;RP   Control pcm-channel	TR->RS->RSU
RGCRDY		EQU	12h	;     Signaling terminated	RS->TR
RGCCHGMFE	EQU	13h	;RP   Change MFE receiving	RS->RSU
RGCTIMEOUT	EQU	14h	;     MFE timeout		RS->TR
RGCINVSIG	EQU	15h	;     Invalid signal		RS->TR
RGCACTIV	EQU	16h	;     Activate already seized	TR->RS
				;     register process

RGCACK		EQU	80h	;RP   Acknowledgement		RSU->RS->TR
RGCACKSEIZ	EQU	81h	;     Acknowledgement on seiz	RS->TR
RGCACKREL	EQU	82h	;     Acknowledgement on rel.	RS->TR
RGCACKCHANGE	EQU	83h	;RP   Acknowledgement on change	RS->TR
RGCNAK		EQU	84h	;RP   Non-acknowledgement	RSU->RS->TR
RGCQUEUE	EQU	85h	;     Seizure in queue		RS->TR

;	Subcodes for register order:

RGODIGIT	EQU	20h	;     Send digit/digits		TR->RS
RGONXTDIG	EQU	21h	;     Request next digit	TR->RS
RGOADDCMP	EQU	22h	;     Address complete		TR->RS
RGOCONG		EQU	23h	;     Congestion.		TR->RS
RGOBUSY		EQU	24h	;     Called party busy		TR->RS
RGOUNALLO	EQU	25h	;     Unallocated number	TR->RS
RGOFREE		EQU	26h	;     Called party free		TR->RS
RGOSUBS		EQU	27h	;     Calling is subscriber	TR->RS
RGOOPER		EQU	28h	;     Calling is operator	TR->RS
RGOACAT		EQU	29h	;     Send A category		TR->RS
RGOREJ		EQU	2Ah	;     Request rejected		TR->RS
RGOADIG		EQU	2Bh	;     Send A-number digit	TR->RS
RGOAEND		EQU	2Ch	;     End of A-number		TR->RS
RGOSETUP	EQU	2Dh	;     Address complete, speech	TR->RS
RGOREQANO	EQU	2Eh	;     Request of A-number 	TR->RS	 
RGOEXTDIV	EQU	2Fh	;     External diversion 	TR->RS	 

RGOFSTA		EQU	90h	;     First A-signal	 	TR->RS	 
RGOLOCSPEECH	EQU	91h	;     Local call speech (KD)	TR->RS
RGOLOCDATA	EQU	92h	;     Local call data (KD)	TR->RS
RGOSEMIAUTO	EQU	93h	;     Semi automatic call (KD)	TR->RS
RGOTOLLCALL	EQU	94h	;     Toll automatic call (KD)	TR->RS
RGOTESTCALL	EQU	95h	;     Test call (KD)		TR->RS
RGOLINEOUT	EQU	96h	;     Subscribe out of order	TR->RS
RGOSUBREJ	EQU	97h	;     A-number restricted	TR->RS

RGOPROB		EQU	0A0h	;     Provinc. norm. B-charge	TR->RS
RGOPROL		EQU	0A1h	;     Provinc. norm. L-charge	TR->RS
RGONATB		EQU	0A2h	;     National norm. B-charge	TR->RS
RGONATL		EQU	0A3h	;     National norm. L-charge	TR->RS
RGOINTB		EQU	0A4h	;     Internat. norm. B-charge	TR->RS
RGOINTL		EQU	0A5h	;     Internat. norm. L-charge	TR->RS
RGOSPECB	EQU	0A6h	;     Special service B-charge	TR->RS
RGOSPECL	EQU	0A7h	;     Special service L-charge	TR->RS
RGOREQCLL	EQU	0A8h	;     Call class request	TR->RS
RGOREQALL	EQU	0A9h	;     Req. all digits of called	TR->RS
RGOREQBC	EQU	0AAh	;     Req. 'BC' digit group	TR->RS
RGOREQGRA	EQU	0ABh	;     Group A request		TR->RS
RGOREQGRC	EQU	0ACh	;     Group C request		TR->RS

RGOSENBEG	EQU	30h	;RP   Begin sending signal	RS->RSU
RGOSENEND	EQU	31h	;RP   Stop sending signal	RS->RSU
RGOSENPLS	EQU	32h	;RP   Send signal pulse		RS->RSU
RGOCLIEN	EQU	33h	;     A-number enabled          TR->RS
RGOCLIDIS	EQU	34h	;     A-number disabled         TR->RS

;	Subcodes for register signal:

RGSDIGIT	EQU	40h	;     Received digit/digits	RS->TR
RGSNXTDIG	EQU	41h	;     Next digit from TR	RS->TR
RGSADDCMP	EQU	42h	;     Address complete		RS->TR
RGSCONG		EQU	43h	;     Congestion		RS->TR
RGSBUSY		EQU	44h	;     Called party busy		RS->TR
RGSUNALLO	EQU	45h	;     Unallocated number	RS->TR
RGSFREE		EQU	46h	;     Called party free		RS->TR
RGSSUBS		EQU	47h	;     Calling is subscriber	RS->TR
RGSOPER		EQU	48h	;     Calling is operator	RS->TR
RGSACAT		EQU	49h	;     Send A category		RS->TR
RGSREJ		EQU	4Ah	;     Request rejected		RS->TR
RGSADIG		EQU	4Bh	;     Send A-number digit	RS->TR
RGSAEND		EQU	4Ch	;     End of A-number		RS->TR
RGSSETUP	EQU	4Dh	;     Address complete, speech	RS->TR
RGSREQANO	EQU	4Eh	;     Request of A-number 	RS->TR	 
RGSEXTDIV	EQU	4Fh	;     External diversion 	RS->TR	 

RGSFSTBDIG	EQU	0B0h	;     Send first dig of B-numb	RS->TR
RGSLASTBX	EQU	0B1h	;     Send last but x digit	RS->TR
RGSSUBSWP	EQU	0B2h	;     Calling is subscriber
				;     with priority		RS->TR
RGSADDCMPKD	EQU	0B3h	;     Address complete, send KD	RS->TR
RGSLOCSPEECH	EQU	0B4h	;     Local call speech (KD)	RS->TR
RGSLOCDATA	EQU	0B5h	;     Local call data (KD)	RS->TR
RGSSEMIAUTO	EQU	0B6h	;     Semi automatic call (KD)	RS->TR
RGSTOLLCALL	EQU	0B7h	;     Toll automatic call (KD)	RS->TR
RGSTESTCALL	EQU	0B8h	;     Test call (KD)		RS->TR
RGSTESTREQ	EQU	0B9h	;     Test request		RS->TR
RGSSUBREJ	EQU	0BAh	;     A-number restricted	RS->TR
RGSLINEOUT	EQU	0BBh	;     Lineout			RS->TR

RGSPROB		EQU	0C0h	;     Provinc. norm. B-charge	RS->TR
RGSPROL		EQU	0C1h	;     Provinc. norm. L-charge	RS->TR
RGSNATB		EQU	0C2h	;     National norm. B-charge	RS->TR
RGSNATL		EQU	0C3h	;     National norm. L-charge	RS->TR
RGSINTB		EQU	0C4h	;     Internat. norm. B-charge	RS->TR
RGSINTL		EQU	0C5h	;     Internat. norm. L-charge	RS->TR
RGSSPECB	EQU	0C6h	;     Special service B-charge	RS->TR
RGSSPECL	EQU	0C7h	;     Special service L-charge	RS->TR
RGSREQCLL	EQU	0C8h	;     Call class request	RS->TR
RGSREQALL	EQU	0C9h	;     Req. all digits of called	RS->TR
RGSREQBC	EQU	0CAh	;     Req. 'BC' digit group	RS->TR
RGSREQGRA	EQU	0CBh	;     Group A request		RS->TR
RGSREQGRC	EQU	0CCh	;     Group C request		RS->TR

RGSSENRDY	EQU	50h	;RP   Pulse sent		RSU->RS
RGSRECBEG	EQU	51h	;RP   Receiving signal begun 	RSU->RS
RGSRECEND	EQU	52h	;RP   Receiving signal ended  	RSU->RS
RGSRECDTMF	EQU	53h	;RP   Signal received		RSU->RS
RGSTRLDTMF	EQU	54h	;     Signal translated		RS->TR
RGSTRC		EQU	55h	;RP   TRC detected		RSU->RS->TR
RGSCLIREQ	EQU	56h	;     Send A-Number methode     RS->TR
RGSCLIEN	EQU	57h	;     A-Number enabled          RS->TR
RGSCLIDIS	EQU	58h	;     A-Number disabled         RS->TR
RGSCCINVOKE	EQU	59h	;     Collected Call invoke	RS -> TR 
;-----------------------------------
;REND (subcodes)

  PAGE
;RBEG,OTHERS
;	Data for failure cause:

RSN_LACKCAP	EQU	0	;RP   Lack of capacity
RSN_BUSY	EQU	1	;RP   Individual is busy
RSN_RPDSP	EQU	2	;RP   Error between RP and DSP
RSN_FUNCNOTIMP	EQU	3	;RP   Function not implemented
RSN_TONEOUTRGE	EQU	4	;RP   Tone level out of range
RSN_DIGOUTRGE	EQU	5	;RP   Digit out of range
RSN_NOCHGMFE	EQU	6	;RP   Error in change betw. det. of 1-&2 freq.

;	Data for register type:

REGT_DTMFCEPT	EQU	1	;RP   CEPT DTMF-receiver
REGT_DTMFCEPTEW	EQU	2	;RP   CEPT DTMF-receiver, early warning
REGT_DTMFETOE	EQU	3	;RP   End-to-end DTMF-receiver
REGT_DTMFETOEEW	EQU	4	;RP   End-to-end DTMF-receiver, early warning
REGT_MFCOUT	EQU	5	;RP   MFC outgoing direction
REGT_MFCIN	EQU	6	;RP   MFC incoming direction
REGT_TRC	EQU	7	;RP   TRC receiving
REGT_MFCAS	EQU	8	;RP   MFC Forward, high freq. group, sending.
REGT_MFCAR	EQU	9	;RP   MFC Forward, high freq. group, rec.
REGT_MFCBS	EQU	10	;RP   MFC Backward, low freq. group, sending.
REGT_MFCBR	EQU	11	;RP   MFC Backward, low freq. group, rec.
REGT_MFE1S	EQU	12	;RP   MFE Sending MFE1
REGT_MFE1IR	EQU	13	;RP   MFE Receiving MFE1 information
REGT_MFE1VR	EQU	14	;RP   MFE Receiving MFE1 verification
REGT_MFE2S	EQU	15	;RP   MFE Sending MFE2
REGT_MFE2IR	EQU	16	;RP   MFE Receiving MFE2 information 
REGT_MFE2VR	EQU	17	;RP   MFE Receiving MFE2 verification 

REGT_MFE1OUT	EQU	20	;RP   MFE1 Outgoing direction
REGT_MFE1IN	EQU	21	;RP   MFE1 Incoming direction
REGT_MFE2OUT	EQU	22	;RP   MFE2 Outgoing direction
REGT_MFE2IN	EQU	23	;RP   MFE2 Incoming direction
REGT_DTMFCEPTVS	EQU	24	;RP   CEPT DTMF-receiver for voice services
REGT_DTMFETOEVS	EQU	25	;RP   End-to-end DTMF-receiver for voice
				;     services

; 	Data for MFC signalling scheme:

REGS_MFCSTD	EQU	0	;RP   Standard MFC CCITT R2
REGS_MFCSMP	EQU	1	;RP   Simplified MFC CCITT R2
REGS_MFCFIN	EQU	2	;RP   Finnish MFC CCITT R2
REGS_MFCNOR	EQU	3	;RP   Norweigian MFC CCITT R2
REGS_MFCMEX	EQU	4	;RP   Mexican MFC CCITT R2
REGS_MFCAUS	EQU	5	;RP   Australian MFC CCITT R2
REGS_MFCBEL	EQU	6	;RP   Belgian simplified MFC CCITT R2
REGS_MFCMAL	EQU	7	;RP   Malaysian MFC CCITT R2
REGS_MFCBRA	EQU	8	;RP   Brazilian MFC CCITT R2
REGS_MFCBLM	EQU	9	;RP   Brazilian MFC LME
REGS_MFCCHI	EQU	10	;RP   China MFC R2
REGS_MFCISR	EQU	11	;RP   Israel MFC R2
REGS_MFCIND	EQU	12	;RP   India MFC  

; 	Data for DTMF signalling scheme:

REGS_DTMFSTD	EQU	0	;RP   Standard DTMF 


;	Data for type of TRC:

REGR_STD	EQU	0	;RP   Standard TRC


;	Data fpr DTMF-Signal (digits):

DTMF_0		EQU	0	;RP   digit 0
DTMF_1		EQU	1	;RP   digit 1
DTMF_2		EQU	2	;RP   digit 2
DTMF_3		EQU	3	;RP   digit 3
DTMF_4		EQU	4	;RP   digit 4
DTMF_5		EQU	5	;RP   digit 5
DTMF_6		EQU	6	;RP   digit 6
DTMF_7		EQU	7	;RP   digit 7
DTMF_8		EQU	8	;RP   digit 8
DTMF_9		EQU	9	;RP   digit 9
DTMF_STAR	EQU	0Ah	;RP   *
DTMF_SQU	EQU	0Bh	;RP   #
DTMF_A		EQU	0Ch	;RP   signal A
DTMF_B		EQU	0Dh	;RP   signal B
DTMF_C		EQU	0Eh	;RP   signal C
DTMF_D		EQU	0Fh	;RP   signal D

;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.47	 TONEPAR-message, subcodes and data (tones see 12.7)
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TONEPAR
;-----------------------------------
				;     SUBCODES
TSPKSCPAR	EQU	1	;RP   DTMF parameters
TSPTONEFREQ	EQU	2	;RP   Traffic tone frequencies
TSPTONECAD	EQU	3	;RP   Traffic tone cadences
TSPELU		EQU	4	;RP   Traffic tone cadences for ELU
TSPACK		EQU	5	;RP   Tone parameter acknowledge
TSPNAK		EQU	6	;RP   Tone parameter non ackn.
;-----------------------------------
;REND (subcodes)

;RBEG,OTHERS
				;     Number of DTMF digits in TSPKCPAR
TS_DTMF12	EQU	0	;RP   12 codes. 0-9, *, #
TS_DTMF16	EQU	1	;RP   16 codes. 0-9, *, #, A-D

				;     Failure cause in TSPNAK
TSEGENERR	EQU	00h	;RP   General 
TSEKNODTMF	EQU	10h	;RP   Illegal number of DTMF-signals
TSEKLEVEL	EQU	11h	;RP   Illegal level
TSEFRAGNO	EQU	20h	;RP   Illegal tone fragment number
TSEFLEVEL1	EQU	21h	;RP   Illegal level 1
TSEFFREQ1	EQU	22h	;RP   Illegal frequency 1
TSEFLEVEL2	EQU	23h	;RP   Illegal level 2
TSEFFREQ2	EQU	24h	;RP   Illegal frequency 2
TSECTONENO	EQU	30h	;RP   Illegal tone number
TSECNOELEM	EQU	31h	;RP   Illegal number of elements in tone
TSECREPET	EQU	32h	;RP   Repetition from illegal element
TSECFRAGI1	EQU	33h	;RP   Illegal internal tone frag. in element 1
TSECFRAGI2	EQU	34h	;RP   .... in 2
TSECFRAGI3	EQU	35h	;RP   .... in 3
TSECFRAGI4	EQU	36h	;RP   .... in 4
TSECFRAGE1	EQU	37h	;RP   Illegal external tone frag. in element 1
TSECFRAGE2	EQU	38h	;RP   .... in 2
TSECFRAGE3	EQU	39h	;RP   .... in 3
TSECFRAGE4	EQU	3Ah	;RP   .... in 4

;REND  (others)
;----------------------------------------------------------------------------
; 12.48	 TONECTRL-message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TONECTRL
;-----------------------------------
TSCTONESTART	EQU	1	;RP   Start tone sending
TSCTONESTOP	EQU	2	;RP   Stop tone sending
TSCTONERDY	EQU	3	;RP   Tone sending stopped
TSCTONEERROR	EQU	4	;RP   Illegal tone ordered
TSCKSCSTART	EQU	5	;RP   Start digit sending
TSCKSCSTOP	EQU	6	;RP   Stop digit sending
TSCKSCRDY	EQU	7	;RP   Digit sending stopped
TSCKSCERROR	EQU	8	;RP   Tllegal DTMF ordered
TSCSXREQUEST	EQU	9	;     Request of tone individual
TSCSXSTART	EQU	10	;     Start/restart tonesending
TSCSXRELEASE	EQU	11	;     Release of tone individual
TSCSXACK	EQU	12	;     Okay
TSCSXNAK	EQU	13	;     Not okay
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.49	 STATEREP-message, subcodes (Note! range of subcodes 61h-7Ah (a-z)
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, STATEREP
;-----------------------------------
SRINFO		EQU	61h	;RP  'a'  Information state for extensions
;-----------------------------------
;REND (subcodes)


 
;----------------------------------------------------------------------------
; 12.50	 TRANSM-message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TRANSM
;-----------------------------------
TRMCONREQ	EQU	02h	;     Transmission connection request
TRMCONSPK	EQU	03h	;     Transmission speech connection
TRMCONNOM	EQU	04h	;     Transmission nominal (no speech)
TRMCONADJ	EQU	05h	;     Transmission adjusted (no speech)

TRMREP		EQU	0Ah	;     Transmission report
TRMREP2		EQU	0Bh	;     Transmission report 2 connected channels

TRMCON		EQU	12h	;RP   Transmission connect
TRMADJ		EQU	13h	;RP   Transmission connect, adjusted levels
TRMNOM		EQU	14h	;RP   Transmission connect

TRMACK		EQU	21h	;RP   Transmission levels okay
TRMNAK		EQU	22h	;RP   Transmission levels not okay

TRMWARNING	EQU	25h	;     Warning in SX
;-----------------------------------
;REND (subcodes)
  PAGE
;----------------------------------------------------------------------------
; 12.51	SYSPAR-message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, SYSPAR
;-----------------------------------
SYPPCMCLAW	EQU	00	;RP   PCM-coding principle
SYPNETW		EQU	01	;RP   Networking date
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.52	VOICEPAGCTRL-message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, VOICEPAGCTRL
;-----------------------------------
VPINIT		EQU	00	;RP  Voice paging init
VPDATA		EQU	01	;RP  Group data
VPTERM		EQU	02	;RP  Terminate voicepaging
;-----------------------------------
;REND (subcodes)


  PAGE
;----------------------------------------------------------------------------
; 12.53	 MEMEX-message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE,  MEMEX
;-----------------------------------
RPM_NAK		EQU	0	;RP  Subcode not implemented
RPMREAD		EQU	1	;RP  Read in RP memory
RPMREAD_ACK	EQU	2	;RP  Answer on RPMREAD
RPMREAD_NAK	EQU	3	;RP  Answer on RPMREAD
RPMWRITE	EQU	4	;RP  Write in RP memory
RPMWRITE_ACK	EQU	5	;RP  Answer on RPMREAD
RPMWRITE_NAK	EQU	6	;RP  Answer on RPMREAD
;-----------------------------------
;REND (subcodes)

;RBEG,OTHERS
;	Other data in MEMEX
;	-------------------
;	FORMAT:

ONE_BYTE	EQU	0	;RP  1 byte		(8 bits)
EIGHT_BYTES	EQU	1	;RP  8 bytes
ONE_WORD	EQU	2	;RP  1 word		(16 bits)
FOUR_WORDS	EQU	3	;RP  4 word
ONE_LWORD	EQU	4	;RP  1 long word 	(32 bits)
TWO_LWORDS	EQU	5	;RP  2 long words


;	WRITE ACK CAUSE:

RPMW_VERIFIED	EQU	0	;RP  written and verified
RPMW_UNVER	EQU	1	;RP  written but not verified
RPMW_ERROR	EQU	2	;RP  Error when verifying


;	WRITE NAK CAUSE:

RPMW_UNSPEC	EQU	0	;RP  Unspec. error
RPMW_FORMAT	EQU	1	;RP  Illegal format
RPMW_ILLEGAL	EQU	2	;RP  Illegal address. 
RPMW_NOT_ALL	EQU	3	;RP  Not allowed to write


;	READ NAK CAUSE:

RPMR_UNSPEC	EQU	0	;RP  Unspec. error
RPMR_FORMAT	EQU	1	;RP  Illegal format
RPMR_ILLEGAL	EQU	2	;RP  Illegal address. 
RPMR_NOT_ALL	EQU	3	;RP  Not allowed to read

;REND  (others)
  PAGE
;----------------------------------------------------------------------------
; 12.54	RPJOB, RPJOBANSW -messages, subcodes and data
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, RPJOB
;RCODE, RPJOBANSW
;-----------------------------------
RPJCSUM		EQU	01h	;RP  Compute PROM checksum
RPJACSUM	EQU	01h	;RP  
RPJACSUM_ERR	EQU	81h	;RP  

RPJLED		EQU	02h	;RP  Control LEDs on board front
RPJALED		EQU	02h	;RP  
RPJALED_ERR	EQU	82h	;RP  

RPJBREV		EQU	03h	;RP  Asks for board revision
RPJABREV	EQU	03h	;RP  
RPJABREV_ERR	EQU	83h	;RP  

RPJPRNO1	EQU	05h	;RP  Asks for product number of PROM1
RPJAPRNO1S	EQU	04h	;RP  
RPJAPRNO1P	EQU	05h	;RP  
RPJAPRNO1_ERR	EQU	85h	;RP  

RPJPRNO2	EQU	07h	;RP  Asks for product number of PROM2
RPJAPRNO2S	EQU	06h	;RP  
RPJAPRNO2P	EQU	07h	;RP  
RPJAPRNO2_ERR	EQU	87h	;RP  

RPJPRNO3	EQU	09h	;RP  Asks for product number of PROM3
RPJAPRNO3S	EQU	08h	;RP  
RPJAPRNO3P	EQU	09h	;RP  
RPJAPRNO3_ERR	EQU	89h	;RP  

RPJCADR		EQU	0Ah	;RP  Asks for card address (from port)
RPJACADR	EQU	0Ah	;RP  
RPJACADR_ERR	EQU	8Ah	;RP  

RPJTRACE	EQU	0Bh	;RP  To control the trace function
RPJATRACE	EQU	0Bh	;RP  
RPJATRACE_ERR	EQU	8Bh	;RP  

RPJUTIL		EQU	0Ch	;RP
RPJUTIL_ERR	EQU	8Ch	;RP

RPJCROF		EQU	0Eh	;RP  Asks for product number of card (ROF...)
RPJACROFS	EQU	0Dh	;RP  
RPJACROFP	EQU	0Eh	;RP  
RPJAROF_ERR	EQU	8Eh	;RP  

RPJPERTEST	EQU	0Fh	;RP  Asks for periodic test
RPJAPERTEST	EQU	0Fh	;RP  
RPJAPERTEST_ERR	EQU	8Fh	;RP  

RPJIPUUTIL	EQU	69h	;RP  Access license and specific board data of IPU
RPJIPUUTIL_ERR	EQU	0E9h	;RP

RPJTELNET	EQU	6Ch	;RP  Telnet
RPJTELNET_ERR	EQU	0ECh	;RP

RPJFEXTWARN	EQU	6Dh	;RP  External Warning Log handling
RPJFEXTWARN_ERR	EQU	0EDh	;RP

RPJFWDLDTS	EQU	6Eh	;RP  FW download DTS
RPJFWDLDTS_ERR	EQU	0EEh	;RP

RPJFTPEFS	EQU	6Fh	;RP  FTP access to peripheral boards
RPJFTPEFS_ERR	EQU	0EFh	;RP      with embedded file system
;-----------------------------------
;REND (subcodes)


;-----------------------------------
;	Data definitions
;RBEG,OTHERS
RJ_RDFL1	EQU	0Eh	;RP  Asks for product number of FLASH1
RJ_RDFL1P	EQU	0Fh	;RP
RJ_RDFL1S	EQU	0Eh	;RP
RJ_RDFL2	EQU	10h	;RP  Asks for product number of FLASH2
RJ_RDFL2P	EQU	11h	;RP
RJ_RDFL2S	EQU	10h	;RP
RJ_RDPR1	EQU	0Ah	;RP  Asks for product number of PROM1
RJ_RDPR1P	EQU	0Bh	;RP
RJ_RDPR1S	EQU	0Ah	;RP
RJ_RDPR2	EQU	0Ch	;RP  Asks for product number of PROM1
RJ_RDPR2P	EQU	0Dh	;RP
RJ_RDPR2S	EQU	0Ch	;RP

;-----------------------------------
;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.55	ADFUNCTION -message, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ADFUNCTION
;-----------------------------------
; Subcodes:					Function:
;----------------------------------------------------------------------------
ADCLEAR		EQU	01h	;RP	CP->RP	Set max/min to current val.
ADSET_THRESHLD	EQU	02h	;RP	CP->RP	Set thresholds for warnings
ADREAD_THRESHLD	EQU	03h	;RP	CP->RP	Read thresholds for warnings

ADREAD_FAC_CUR	EQU	10h	;RP	CP->RP	Read current values
ADREAD_FAC_MAX	EQU	11h	;RP	CP->RP	Read maximum values
ADREAD_FAC_MIN	EQU	12h	;RP	CP->RP	Read minimum values
ADREAD_SUP_CUR	EQU	13h	;RP	CP->RP	Read current values 
ADREAD_SUP_MAX	EQU	14h	;RP	CP->RP	Read maximum values
ADREAD_SUP_MIN	EQU	15h	;RP	CP->RP	Read minimum values

ADANSW_NAK	EQU	80h	;RP	RP->CP	Function not available
ADANSW_ACK	EQU	81h	;RP	RP->CP	Requested function done.
ADLIM_FAC_CUR	EQU	82h	;RP	RP->CP	Out of limits message
ADANSW_THRESHLD	EQU	83h	;RP	RP->CP	Answer upon ADREAD_THRESHLD

ADANSW_FAC_CUR	EQU	90h	;RP	RP->CP	Answer with current values
ADANSW_FAC_MAX	EQU	91h	;RP	RP->CP	Answer with maximum values
ADANSW_FAC_MIN	EQU	92h	;RP	RP->CP	Answer with minimum values
ADANSW_SUP_CUR	EQU	93h	;RP	RP->CP	Answer with current values 
ADANSW_SUP_MAX	EQU	94h	;RP	RP->CP	Answer with maximum values
ADANSW_SUP_MIN	EQU	95h	;RP	RP->CP	Answer with minimum values
;-----------------------------------
;REND (subcodes)

;RBEG,OTHERS

; AD_TYPE				Function 
;-----------------------------------------------------
SUP_5V		EQU	01h	;RP	Addresses supervision probe for + 5V.
SUP_M48V	EQU	02h	;RP	Addresses supervision probe for - 48V.
SUP_M12V	EQU	03h	;RP	Addresses supervision probe for - 12V.
SUP_P12V	EQU	04h	;RP	Addresses supervision probe for + 12V.
SUP_M5V		EQU	05h	;RP	Addresses supervision probe for - 5V.
SUP_M8V		EQU	06h	;RP	Addresses supervision probe for - 8V.
SUP_P8V		EQU	07h	;RP	Addresses supervision probe for + 8V.
SUP_M40V	EQU	08h	;RP	Addresses supervision probe for - 40V.
SUP_TEMP	EQU	09h	;RP	Addresses supervision probe for internal
				;   	temperature probe.
FAC_TEMP1	EQU	0Ah	;RP	Addresses facilty temperature probe 1
FAC_TEMP2	EQU	0Bh	;RP	Addresses facilty temperature probe 2
FAC_TEMP3	EQU	0Ch	;RP	Addresses facilty temperature probe 3
SUP_P3_3V	EQU	0Dh	;RP	Addresses supervision probe for +3.3V
SUP_P2_5V	EQU	0Eh	;RP	Addresses supervision probe for +2.5V

;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.56	 CPICKUPCTRL -message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CPICKUPCTRL
;-----------------------------------
CPICKUPQ	EQU	00h	; Call pickup question
CPICKUPACK	EQU	01h	; Pick up possible
CPICKUPNAK	EQU	02h	; Pick up not possible
;-----------------------------------
;REND (subcodes)



;----------------------------------------------------------------------------
; 12.57	 ELSTATE -message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ELSTATE
;-----------------------------------
ELSLINEBLOCK	EQU	0	;RP
ELSLINEOPEN	EQU	1	;RP
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.58	 TESTTRACE -message, subcodes (TYPE range = 'a' to 'z') 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TESTTRACE
;-----------------------------------
CARDSIM		EQU	61h	;RP  Message to simulated card	
CARDTEST	EQU	62h	;RP  Message from tested card	
CPTEST		EQU	63h	;RP  Message from tested CP-unit	
CPSIM		EQU	64h	;RP  Message to simulated CP-unit
MSGLOG		EQU	65h	;RP  Logged message
MSGLOGMPD	EQU	66h	;RP  Logged message, extended for MPD
MSGLOGREF	EQU	67h	;RP  Logged message, sendeer references
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 12.59	 TEXTEDIT -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TEXTEDIT
;-----------------------------------
TEXTINIT	EQU	01h	; Init of editing
TEXTANSW	EQU	02h	; Text completed
TEXTTO		EQU	03h	; Timeout editing
TEXTSTOP	EQU	04h	; Stop session
TEXTNAK		EQU	05h	; TEXTINIT rejected
TEXTREQ		EQU	06h	; Fetch edited text
TEXTREQANSW	EQU	07h	; Text request answer.
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.60	 ELDTRANSIT -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ELDTRANSIT
;-----------------------------------
ELT_IOSETUP	EQU	0A9h	;RP  External relay control
ELT_CLEARLED	EQU	090h	;RP  Clear a telephone led
ELT_SETLED	EQU	091h	;RP  Turn on a LED
ELT_PESREQ	EQU	0A2h	;RP  Request from Personal Efficiency System
ELT_PESGLOBAL	EQU	0A3h	;RP  Broadcast info for PES
ELT_PESINFO	EQU	0A4h	;RP  Information for PES
ELT_PCOPIREQ	EQU	0A5h	;RP  Request from PC operator
ELT_PCOPIINFO	EQU	0A6h	;RP  Information for PC operator
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------
;	Common Data Descriptions for ELDTRANSIT-message
;

;	REQ_TYPE

ETP_PROTREVQ	EQU	00h	; PES protcol revision
ETP_DIVINFQ	EQU	01h	; Diversion information
ETP_KEYDATAQ	EQU	02h	; Instrument key programming
ETP_ACDGRPPAQ	EQU	03h	; ACD group parameter
ETP_ACDGRPQ	EQU	04h	; Login / logout ACD groups
ETP_ACDAGSTAT	EQU	05h	; Activate / Deactivate ACD agent
ETP_ACDCCODE	EQU	06h	; Call code
ETP_ACDALLAGSQ	EQU	07h	; Status information of all ACD agents
ETP_ACDCLERTIMQ	EQU	08h	; Clerical time of ACD-groups
ETP_ACDCOMPAQ	EQU	09h	; Common ACD parameter
ETP_KEYCODE	EQU	0Ah	; Request for keycode
ETP_DIVUPD	EQU	0Bh	; Request diversion update
ETP_ACTINFTXT	EQU	0Ch	; Activate information text
ETP_SENDMSG	EQU	0Dh	; Send message

;	TYPE_INFO

ETP_PROTREV	EQU	00h	; PES protocol revision
ETP_CALLSTAT	EQU	01h	; Call state to external connected equipement
ETP_NEWNUM	EQU	02h	; New number information
ETP_CLIP	EQU	03h	; Calling line identification (CLIP)
ETP_COLP	EQU	04h	; Connected line identification (COLP)
ETP_DIVINFO	EQU	05h	; Call diversion information
ETP_NAME	EQU	06h	; Name of participated party
ETP_MAIL	EQU	07h	; Change in mail box
ETP_KEYDATA	EQU	08h	; Instrument key programming layout
ETP_ACDCALL	EQU	09h	; An incoming call is indicated
ETP_ACDGRPACK	EQU	0Ah	; Acknowledge to Login/logout ACD groups
ETP_ACDGRPNAK	EQU	0Bh	; Not acknowledge to Login/logout ACD groups
ETP_ACDAGSACK	EQU	0Ch	; Acknowledge to Activate/Deact. ACD agent
ETP_ACDAGSNAK	EQU	0Dh	; Not acknowledge to Activate/Deact. ACD agent
ETP_ACDCCACK	EQU	0Eh	; Acknowledge to Call-code
ETP_ACDCCNAK	EQU	0Fh	; Not acknowledge to Call-code
ETP_ACDALLAGST	EQU	10h	; Status info of all ACD agents
ETP_ACDNONACDCC	EQU	11h	; Request for non-ACD callcode

;	INFO_TYPE for ELT_PCOPIINFO

ETPO_KEYCHRRSP	EQU	00h	; Keypad character
ETPO_KEYCHRUPD	EQU	01h	; Update keypad character
ETPO_SYSPRGACT	EQU	02h	; Entering system programming
ETPO_SYSPRGREL	EQU	03h	; Leaving system programming

;	REQ_TYPE for ELT_PCOPIREQ

ETPO_KEYCHRREQ	EQU	00h	; Keypad character
ETPO_OPSTART	EQU	01h	; Start operation
ETPO_OPEXIT	EQU	02h	; Stop operation

  PAGE
;----------------------------------------------------------------------------
; 12.61	 COST -message, subcodes and other data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, COST
;-----------------------------------
COSTPULSEQ	EQU	00h	; Question of cost of pulses
COSTPULSEACK	EQU	01h	; Positive answer with cost
COSTPULSENAK	EQU	02h	; Negative answer
COSTTIMEQ	EQU	03h	; Question of cost of duration
COSTTIMEACK	EQU	04h	; Positive answer with cost
COSTTIMENAK	EQU	05h	; Negative answer
COSTPREDFSTQ	EQU	06h	; Question for first carrier
COSTPREDNXTQ	EQU	07h	; Question for next carrier
COSTPREDACK	EQU	08h	; Positive answer
COSTPREDNAK	EQU	09h	; Negative answer
COSTPREDEND	EQU	0Ah	; No more carriers
COSTMULTQ	EQU	0Bh	; Question to multiple costs
COSTMULTACK	EQU	0Ch	; Positive answer, including manipulated costs
COSTMULTNAK	EQU	0Dh	; Negative answer
;-----------------------------------
;REND (subcodes)


; Data for 'Destination number group'
;-------------------------------------
NA.UNDEF	EQU	250	; Destination group is not defined


; Failure causes for COSTPULSENAK ,  COSTTIMENAK and COSTPREDNAK
;-------------------------------------------------
COST.ILLCARR	EQU	00	; Illegal carrier number
COST.ILLTEN	EQU	01	; Illegal tennant number
COST.UNDDNG	EQU	02	; Undefined destination number group
COST.MISSDAT	EQU	03	; Data needed was not programmed
COST.GENERAL	EQU	04	; Unspecified type of fault
COST.ILLTARIFF	EQU	05	; Illegal tariff number

  PAGE
;----------------------------------------------------------------------------
; 12.62	 SAVENO -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, SAVENO
;-----------------------------------
SAVE.LNR	EQU	0	; Digits for last dialled number
SAVE.SNR	EQU	1	; Digits for last saved number
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.63	 SERVICE -message, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, SERVICE
;-----------------------------------
SENAK		EQU	 0	;RP  Requested service is not implemented
SEMCIDREQ	EQU	 1	;RP  MCID request
SEMCIDACK	EQU	 2	;RP  MCID accepted
SEMCIDNAK	EQU	 3	;RP  MCID rejected
SEMLTREQ	EQU	 4	;RP  ISDN call waiting  request
SEMLTACK	EQU	 5	;RP  ISDN call waiting  request : accepted
SEMLTNAK	EQU	 6	;RP  ISDN call waiting  request : rejected
SEAOCERES	EQU	 7	;RP  AOC-E charging information (CFPR impact)
SEROUTEDAT      EQU      8	;RP  ROUTE own location code
SERTIME		EQU	 9	;RP  AutoTimeSync request
SERTIMEANSW	EQU	10	;RP  AutoTimeSync answer containing date/time
;-----------------------------------
;REND (subcodes)

; Reason for a NAK
;------------------------------
;RBEG,OTHERS
;			0	;    Zero, not used
SERV.UNDEF	EQU	1	;RP  Undefined reason
SERV.NOSUB	EQU	2	;RP  Service not subscribed
SERV.UNAVAIL	EQU	3	;RP  Service unavailable
SERV.INVSTAT	EQU	4	;RP  Invalid call state in network
SERV.INVCALL	EQU	5	;RP  Invalid call
SERV.NOINTACT	EQU	6	;RP  Interaction not allowed
;-----------------------------------
;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.64	 SISIG -message, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, SISIG
;-----------------------------------
;			0	;    Not used.
SISEIZ		EQU	1	;RP  Outgoing ISDN call to the network.
SISETUP		EQU	2	;RP  Incoming ISDN call from the network.
SISETUPCOMP	EQU	3	;RP  Incoming manual ISDN call
SIPTS		EQU	4	;RP  SETUP accepted in ASB.
SISETUPACK	EQU	5	;RP  SETUP accepted in the network.
SIPROGRESS	EQU	6	;RP  Progress informat. from the network.
SIEOS		EQU	7	;RP  End of selection in ASB.
SIPROCEED	EQU	8	;RP  End of selection from the network.
SIRING		EQU	9	;RP  Ringing started in ASB.
SIALERT		EQU	10	;RP  Ringing started in the network.
SISPEECH	EQU	11	;RP  Answer (speech) in ASB.
SIBANSWER	EQU	12	;RP  Answer (speech) from the network
SIRELEASE	EQU	13	;RP  Disconnection in ASB.
SIDISC		EQU	14	;RP  Disconnection from the network.
SIDIGIT		EQU	15	;RP  Digit(s) to/from the network.
SISEIZACK	EQU	16	;RP  Seizure of trunk accepted.
SISEIZNAK	EQU	17	;RP  Seizure of trunk rejected.
SIFREE		EQU	18	;RP  Ind. trunk is free (after release).

SIUUISEIZ	EQU	30	;RP  Outgoing proprietary CN call
SIADDUUISEIZ	EQU	31	;RP  Additional SEIZ message
				;    for proprietary CN call
SIUUISETUP	EQU	32	;RP  Incoming proprietary CN call
SIADDUUISETUP	EQU	33	;RP  Addidional SETUP message
				;    for proprietary CN call
SIUUIRING	EQU	34	;RP  Ringing started - proprietary CN call
SIADDUUIRING	EQU	35	;RP  Additional proprietary information
SIUUIALERT	EQU	36	;RP  Call is in ringing state -
				;    proprietary CN call
SIADDUUIALERT	EQU	37	;RP  Additional proprietary information
SIUUISPEECH	EQU	38	;RP  Answer (speech) - proprietary CN call
SIUUIBANSWER	EQU	39	;RP  Speech from the line - proprietary CN call
SIUUIOUT	EQU	40	;RP  User-to-user information to net
SIADDUUIOUT	EQU	41	;RP  User-to-user information to net
SIUUIIN		EQU	42	;RP  User-to-user information from net
SIADDUUIIN	EQU	43	;RP  User-to-user information from net
SIUUIRELEASE	EQU	44	;RP  Disconnection/release -
				;    proprietary CN call
SIUUIDISC	EQU	45	;RP  Disconnection from the line -
				;    proprietary CN call
SIUUISERVICE	EQU	46	;RP  Information concerning special services
SICNSEIZ	EQU	47	;RP  Outgoing non-proprietary CN call
SICNSETUP	EQU	48	;RP  Incoming non-proprietary CN call
SICNRING	EQU	49	;RP  Ringing started - non-proprietary CN call
SICNALERT	EQU	50	;RP  Call is in ringing state -
				;    non-proprietary CN call
SICNSPEECH	EQU	51	;RP  Answer (speech) - non-proprietary CN call
SICNBANSWER	EQU	52	;RP  Answer (speech) from the line -
				;    non-proprietary CN call
SICNRELEASE	EQU	53	;RP  Disconnection/release -
				;    non-proprietary CN call
SICNDISC	EQU	54	;RP  Disconnection from the line -
				;    non-proprietary CN call

SIFACILITY	EQU	60	;RP  Additional information

SIFDATA		EQU	69	;RP  Forward information data
SIFDATAEND	EQU	70	;RP  Forward information data ended
SIBDATA		EQU	71	;RP  Backward information data
SIBDATAEND	EQU	72	;RP  Backward information data ended

SIRGSDIGIT	EQU	112	;RP  BTUBIP has received a DTMF message from the
				;    IP network including digit information
SISNUPDATE	EQU	113	;RP  New signal number for messages

SIVIRSETUPACK	EQU	133	;RP  SETUP accepted in the line (virtual call)
SIVIRPROGRESS	EQU	134	;RP  Progress info to0/from the line
				;    (virtual call)
SIVIREOS	EQU	135	;RP  End of selection for virtual calls
SIVIRPROCEED	EQU	136	;RP  End of selection from line for virtual
				;    calls

SIVIRDISC	EQU	142	;RP  Disconnection from the line - virtual call

SIVIRSEIZACK	EQU	144	;RP  Seizure of trunk accepted - virtual call
SIVIRSEIZNAK	EQU	145	;RP  Seizure of trunk rejected - virtual call
SIVIRFREE	EQU	146	;RP  Ind. trunk is free after release of
				;    virtual call

SIVIRUUISEIZ	EQU	158	;RP  Outgoing virtual call
SIVIRADDSEIZ	EQU	159	;RP  Additional SEIZ message for virtual call
SIVIRUUISETUP	EQU	160	;RP  Incoming virtual call
SIVIRADDSETUP	EQU	161	;RP  Additional SETUP-message for virtual call

SIVIRUUIBANSWER	EQU	167	;RP  Speech from line - virtual call

SIVIRUUIIN	EQU	170	;RP  User-to-user information to net -
				;    virtual call
SIVIRADDUUIIN	EQU	171	;RP  Additional user-to-user info. to net -
				;    virtual call
SIVIRUUIRELEASE	EQU	172	;RP  Disconnection/release - virtual calls
SIVIRUUIDISC	EQU	173	;RP  Disconnection from the line - virtual call
SIVIRSERVICE	EQU	174	;RP  Information concerning special services

SIVIRCNSETUP	EQU	176	;RP  Incoming non-proprietary virtual CN call

SIVIRCNBANSWER	EQU	180	;RP  Answer (speech) from the line -
				;    non-proprietary CN call
SIVIRCNRELEASE	EQU	181	;RP  Disconnection from line - 
				;    non-proprietary virtual CN call
SIVIRCNDISC	EQU	182	;RP  Disconnection/release - 
				;    non-proprietary virtual CN call
;			...
SISTCHREQ	EQU	190	;RP  Request state change
SISTCHACK	EQU	191	;RP  State change acknowledge
SISTCHNAK	EQU	192	;RP  State change negative acknowledge
;			...
SITRANSDATA	EQU	200	;RP  Transparent data from IPU
;-----------------------------------
;REND (subcodes)

;-------------------------------
;RBEG,OTHERS
;
				;-----------------------------------------------
				; Type data used in SISIG,SIDISC:
				;
;			0	;    Not used.
SIDISC.MCID	EQU	1	;RP  MCID facility available in the network
SIDISC.INBAND	EQU	2	;RP  Inband information available in the network
SIDISC.MCINBND	EQU	3	;RP  Inband info and MCID facility are avail...
SIDISC.NORMAL	EQU	4	;RP  Network information available
				;    in the network
SIDISC.COMPL	EQU	5	;RP  Disconnection complete, no more info...
SIDISC.CNAOC	EQU	6	;RP  Get final charge information

				;-----------------------------------------------
				; Type of number
				;
				; TON for public numbering plan (E.164) :
NUM.UNKN	EQU	00h	; unknown number
NUM.INT		EQU	01h	; international number
NUM.NAT		EQU	02h	; national number
NUM.NET		EQU	03h	; network specific number
NUM.SUB		EQU	04h	; subscriber number
				;
				; TON for private no. plan (PRIVATE) :
NUM.CNUNKN	EQU	10h	; Unknown number
NUM.RL2		EQU	11h	; Regional number level 2
NUM.RL1		EQU	12h	; Regional number level 1
NUM.CNNET	EQU	13h	; Network specific number
NUM.RL0		EQU	14h	; Local number

				; TON for private no. plan (UNKNOWN) :
NUM.NPUNKN	EQU	20h	; Unknown NP & TON

NUM.UNDEF	EQU	0FFh	; no number defined

				;-----------------------------------------------
				; Headers and data used in SISIG,SIFACILITY:
				;
AOCHEAD		EQU	10h	;   AOC information received
FANAK		EQU	11h	;   Facility not acknowledged
FARERREQ	EQU	12h	;   Call forwarding with partial rerouting request
FARERACK	EQU	13h	;   Call forwarding with partial rerouting acknowledged

FAHOLDREQ	EQU	20h	;   Call Hold request
FARETREQ	EQU	21h	;   Retrieve from Hold request
FACONFREQ	EQU	22h	;   Conference request
FADISPLAY	EQU	23h	;   Feature activation response as display text string 
FASUSPEND	EQU	24h	;RP Call suspend
FARESUME	EQU	25h	;RP Call resume
	
FAHOOKREQ	EQU	30h	;   Hook Flash request
FAHOOKACK	EQU	31h	;   Hook Flash request accepted

FAS0HOLDREQ	EQU	40h	;RP Hold request on SO
FAS0RETREQ 	EQU	41h	;RP Retrieve from Hold request on SO
FAS0ECTREQ	EQU	42h	;RP Transfer request on SO
FAS0ECTEXE	EQU	43h	;RP Transfer execute on SO
FAS0SUSPREQ	EQU	44h	;RP Suspend request on SO
FAS0RESUREQ	EQU	45h	;RP Resume request on SO

FAS0HOLDACK	EQU	50h	;RP Call Hold request acknowledged on SO
FAS0RETACK 	EQU	51h	;RP Retrieve from Hold request acknowledged on SO
FAS0ECTACK	EQU	52h	;RP Transfer request acknowledged on SO
FAS0SUSPACK	EQU	53h	;RP Suspend request acknowledged on SO
FAS0RESUACK	EQU	54h	;RP Resume request acknowledged  on SO

FAS0HOLDIND	EQU	60h	;RP Call Hold indication to SO
FAS0RETIND 	EQU	61h	;RP Retrieve from Hold indication to SO
FAS0ECTIND 	EQU	62h	;RP Transfer indication to SO

;-----------------------------------
;REND (others)
  PAGE
;----------------------------------------------------------------------------
; 12.65	 CONPTYNUM -message, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CONPTYNUM
;-----------------------------------
;			0	;    Not used
CONPTYREQ	EQU	1	;RP  Request of number
CONPTYACK	EQU	2	;RP  accepted
CONPTYNAK	EQU	3	;RP  rejected
CONPIDACK	EQU	4	;    Calling or connected (answering)
				;    number and name information
CONPIDDIV	EQU	5	;    Calling or connected (answering)
				;    number and name information,
				;    diverting number and name information
CONPTFRREQ	EQU	6	;    Request for 'new' calling/connected
				;    identity after call transfer
CONPIDTFR	EQU	7	;    Sending of 'new' calling/connected
				;    number and name after call transfer
CONPIDRER	EQU	8	;    Calling or connected (answering)
				;    number and name information,
				;    rerouting number and name information


;-----------------------------------
;REND (subcodes)

; Reason in CONPTYNUM,CONPTYNAK
;------------------------------
;RBEG,OTHERS
;-----------------------------------
;			0	;    Not used
CONP.UNAVAL	EQU	2	;RP  Unavailable
CONP.RESTR	EQU	4	;RP  Restricted

;-----------------------------------
;REND (others)


  PAGE
;----------------------------------------------------------------------------
; 12.66	 CATREAD -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CATREAD
;-----------------------------------
CRR_ABBCOS	EQU	0	; Request to read ABBCOS
CRA_ABBCOS	EQU	1	; Answer of ABBCOS

;-----------------------------------
;REND (subcodes)


  PAGE
;----------------------------------------------------------------------------
; 12.67	 LCRNUM -message, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, LCRNUM
;-----------------------------------
LCRNUMQ		EQU	0	;    Request number rearranging
LCRNANSW	EQU	1	;    Answer incl. rearr. number
LCRNINFO	EQU	2	;    Send rearranged number to trunk

;-----------------------------------
;REND (subcodes)

; Number component identity
;-----------------------------------
LCRN_BNUM	EQU	0	;    
LCRN_ACCESS	EQU	1	;    
LCRN_AUTHORITY	EQU	2	;    
LCRN_ACCOUNT	EQU	3	;    
LCRN_OWNDIRNO	EQU	4	;    
LCRN_DTMF	EQU	5	;    
LCRN_TONE	EQU	6	;    
LCRN_DELAY	EQU	7	;    
LCRN_ERROR	EQU	8	;    
;-----------------------------------

; Error Codes used for LCRN_ERROR
;-----------------------------------
LCRNUM.ILLCARR	EQU	00	; undefined carrier number
LCRNUM.ILLTEN	EQU	01	; undefined tenant number
LCRNUM.MISSDAT	EQU	02	; no programmed data
LCRNUM.GENERAL	EQU	03	; general failure
;-----------------------------------

  PAGE
;----------------------------------------------------------------------------
; 12.68	 NUMCONVERT -message, subcodes and data
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, NUMCONVERT
;-----------------------------------
NCREQ		EQU	0	;    Request a conversion
NCACK		EQU	1	;    Positive answer
NCNAK		EQU	2	;    Negative answer

;-----------------------------------
;REND (subcodes)

; Reason in NUMCONVERT,NCNAK (failure cause)
;-----------------------------------
NC.NOORIGTAB	EQU	0	;    no original number table exists
NC.NONEWTAB	EQU	1	;    no new number table exists
NC.NOORIGNUM	EQU	2	;    no original destination number exists
NC.NONEWNUM	EQU	3	;    no new destination number exists
;-----------------------------------

  PAGE
;----------------------------------------------------------------------------
; 12.69	 AUTHCODE -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, AUTHCODE
;-----------------------------------
AUTHQRY		EQU	0	; Request to verify authority code
AUTHACK		EQU	1	; positive acknowledge
AUTHNAK		EQU	2	; negative acknowledge
MAILACC		EQU	3	; Verify access to common-mailbox
MAILACCACK	EQU	4	; Positive acknowledge
MAILACCNAK	EQU	5	; Negative acknowledge
AUTHCHG		EQU	6	; Request to change authority code
AUTHCHGACK	EQU	7	; Positive acknowledge
AUTHCHGNAK	EQU	8	; Negative acknowledge

;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.70	 INDDATAANSW -message, data-position
;----------------------------------------------------------------------------
; Bitposition in EXT. PARAMETERS
;-----------------------------------
PWCHKBIT	EQU	0	;Access for internal retrieving of voice

;----------------------------------------------------------------------------
; Byteoffsets for DATA field
;-----------------------------------
INDNAMSTR	EQU	DATA+8
INDNAMSTREND	EQU	INDNAMSTR+DI.NAME.LEN

INDDIVIDENTITY	EQU	DATA+20+DI.NAME.LEN
INDDATAVAIL	EQU	INDDIVIDENTITY+0
INDCNNUMBER	EQU	INDDIVIDENTITY+1
INDCNNAME	EQU	INDDIVIDENTITY+11
INDDDINUM	EQU	INDCNNAME+DI.NAME.LEN+2

  PAGE
;----------------------------------------------------------------------------
; 12.71	 GUEST -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, GUEST
;-----------------------------------
LANGQRY		EQU	0	; Request language for guest
LANGANSW	EQU	1	; language answer

;-----------------------------------
;REND (subcodes)
;-----------------------------------

  PAGE
;----------------------------------------------------------------------------
; 12.72	 DIRCTRL -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, DIRCTRL
;-----------------------------------
DELSER		EQU	1	; Delete a common short number series
CRESER		EQU	2	; Create a common short number series

;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.73	 CTIFUNC -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CTIFUNC
;-----------------------------------
MONVERRQ	EQU	00h	; Query a monitor on an extension
MONVERRSP	EQU	01h	; Positive acknowledge for query
MONSTRTRQ	EQU	02h	; Start a monitor on an extension
MONSTRTRSP	EQU	03h	; Response for start request
MONSTRTACD	EQU	04h	; ACD response for start
MONSTOPRQ	EQU	05h	; Stop a monitor on an extension
MONSTOPRSP	EQU	06h	; Response for stop request
MONSTOPACD	EQU	07h	; ACD response for stop request
MONEND		EQU	08h	; Report a monitor end on an extension
MONSUPPORT	EQU	09h	; Report if monitoring is supported at all
ROUTETIMEOUT	EQU	10h	; Waiting timeout value for reroute dest.
CTKEYCODE       EQU     11h     ; Keycode message from CT-block
CTEVREP		EQU	12h	; Request CTI event reporting

EVSTATUPD	EQU	20h	; Report device state update event
EVDIRNUMCH	EQU	21h	; Report directory number change
EVNAMEUPD	EQU	23h	; Report opposite / divertee name
EVFORWARDUPD	EQU	24h	; Report update of call forwarding
EVACDUPD	EQU	25h	; Report update of ACD-status
EVFEATURE	EQU	26h	; Report activated features
EVREPCALLREC	EQU	27h	; Report call record
EVSLAVEUPD	EQU	28h	; Report slave state update event
EVOPIDATA	EQU	29h	; Report special OPI data
EVOPIQUE	EQU	2Ah	; Report status of OP queue
EVINFOUPD	EQU	2Bh	; Report update of Info status
EVFACUPD	EQU	2Ch	; Report update of facility status
EVACDQUPD	EQU	2Dh	; Report ACD queuestate update
EVVMUPD		EQU	2Eh	; Report voice mail status for a device
EVVMSYSUPD	EQU	2Fh	; Report voice mail system status
EVVMSNAPUPD	EQU	30h	; Report voice mail snapshot

REQMAKECALL	EQU	70h	; Request to start a fresh call
RSPMAKECALL	EQU	71h	; Response to a requested make call
REQFWDSTAT	EQU	72h	; Request to report call forwarding info
REQACDSTAT	EQU	73h	; Request to report ACD agent status
REQCONFCALL	EQU	74h	; Request to start a conference
RSPCONFCALL	EQU	75h	; Response to a requested conference
REQFWME		EQU	76h	; Request a Follow Me on extension
REQPICKUPIND	EQU	77h	; Request to do individual pickup
RSPPICKUPIND	EQU	78h	; Response to a requested individual pickup
REQINFO		EQU	79h	; Request an info on extension
REQMESS		EQU	7Ah	; Request a message on extension
REQDND		EQU	7Bh	; Request Do not desturb
RSPDND		EQU	7Ch	; Response to a requested Do not desturb
REQPCROUT	EQU	7Dh	; Request reporting of incoming calls
RSPPCROUT	EQU	7Eh	; Response to a request PC controlled routing
REQNEWDEST	EQU	7Fh	; Request reroute to new destination
RSPNEWDEST	EQU	80h	; Response to a request new destination
REQTRANSFER	EQU	81h	; Request transfer of a call
RSPTRANSFER	EQU	82h	; Response to a requested transfer
REQFORWARD	EQU	83h	; Request to initiate call forward
RSPFORWARD	EQU	84h	; Response to a requested call forward
REQANSWER	EQU	85h	; Request to answer a call
REQCAMPON	EQU	86h	; Request to do a camp on
REQPICKUPGRP	EQU	87h	; Request to pickup call from group
RSPPICKUPGRP	EQU	88h	; Response to a request group pickup
REQSNAPDEV	EQU	89h	; Request snapshot device
RSPSNAPDEV	EQU	8Ah	; Response to a request snapshot device
REQCB		EQU	8Bh	; Request to initiate call back
REQBI		EQU	8Ch	; Request to initiate break in
REQHOLD		EQU	8Dh	; Request to put a call on hold
REQSNAPACD	EQU	8Eh	; Request snapshot ACD
RSPSNAPACD	EQU	8Fh	; Response snapshot ACD
REQDEFLECTCALL	EQU	90h	; Request deflection of an incoming call
RSPDEFLECTCALL	EQU	91h	; Response deflection of an incoming call
REQINFOSTAT	EQU	92h	; Request Info states/Info texts
RSPINFOTXT	EQU	93h	; Response Info texts
REQVOICEPG	EQU	94h	; Request a voipe paging action
RSPVOICEPG	EQU	95h	; Response to voice page command
REQKEYLAYOUT	EQU	96h	; Request instrument key programming layout
RSPKEYLAYOUT	EQU	97h	; Response instrument key programming layout
REQOPIFUNC	EQU	98h	; Request special function of operator instr.
REQSETTINGS	EQU	99h	; Request change of device settings
RSPSETTINGS	EQU	9Ah	; Response to change of device settings
REQLINKPOS	EQU	9Bh	; Request linking position
RSPLINKPOS	EQU	9Ch	; Response linking position
REQVMCTRL	EQU	9Dh	; Request to control a voice mail session
RSPVMCTRL	EQU	9Eh	; Response to control a voice mail session
REQVMSYSCTRL    EQU	9Fh	; Request to control the voice mail system
RSPVMSYSCTRL    EQU	0A0h	; Response to control the voice mail system
REQNAMESUPPORT	EQU	0A1h	; Request if external nameserver is available
RSPNAMESUPPORT	EQU	0A2h	; Response to external nameserver availability
REQNAME		EQU	0A3h	; Request name from externam nameserver
RSPNAME		EQU	0A4h	; Response to namerequest from external nameserver

;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
;	Bit position symbols for information bits
;----------------------------------------------------------------------------
USEASOPI	EQU	0	; Extension used as operator instrument
REQTOSLAVE	EQU	1	; Message directed to slave
VMSTREAMING	EQU	2	; Start streaming session with VM


  PAGE
;----------------------------------------------------------------------------
; 12.74	 PESGLOBAL -message, subcodes 
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, PESGLOBAL
;-----------------------------------
PESACDQUELEN	EQU	01h	; Present queue length of every ACD group
PESACDAGSTAT	EQU	02h	; Status of an ACD agent monitored by
				; ACD supervisor
PESACDGRPINFO	EQU	03h	; Parameter of all ACD groups
PESACDCLERTIM	EQU	04h	; Clerical time of all ACD-groups
PESACDCOMINFO	EQU	05h	; Common ACD parameter
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.75	 TISIG -message, subcodes
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TISIG
;-----------------------------------
;			0	;    Not used.
TISEIZ		EQU	1	;RP  Call to CORDLESS.
TIRELEASE	EQU	2	;RP  Disconnection in ASB.
TICLIP		EQU	3	;RP  RP Call update to cordless
TIMWI		EQU	4	;RP  Turn on message waiting indication
TIIDLE		EQU	5	;RP  Send idle display information
TIINCALL	EQU	6	;RP  Send incall display information
TICONN		EQU	7	;RP  Send connected information
TIREDIR		EQU	8	;RP  Send redirected information

TIDISC		EQU	32	;RP  Disconnection from the CORDLESS.
TISEIZACK	EQU	33	;RP  Seizure of CORDLESS accepted.
TISEIZNAK	EQU	34	;RP  Seizure of CORDLESS rejected.
TIALERT		EQU	35	;RP  RP Cordless has started ringing

;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.76	 TFRQ -message, data
;----------------------------------------------------------------------------
;
;	transfer information

TQB_ACDLOG	EQU	0	; Log order for transferred ACD-call

;----------------------------------------------------------------------------
; 12.77   DISPLAYCTRL -message, subcodes
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, DISPLAYCTRL
;-----------------------------------
DISPREQ	EQU	1
DISPREL	EQU	2
;-----------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.78   TRSTATUS -mesasge, subcodes
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, TRSTATUS
;----------------------------------------------------------------------------
TRIDLE	EQU	01h	; Trunk status IDLE
TRBUSY	EQU	02h	; Trunk status BUSY
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.79   BLOCKINFO-message, subcodes, data fields
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, BLOCKINFO
;----------------------------------------------------------------------------
BIOPTIME	EQU	01h	; Time and temperature value
BIPROTREQ	EQU	02h	; Request info about protection level
BIPROTUPD	EQU	03h	; Inform about change in protection level
BIRESCHKREQ	EQU	04h	; Request for a resource check
BIRESCHKINIT	EQU	05h	; Initiate a resource check
BIRESCHKRDY	EQU	06h	; Resource check has been finished
BIKEYPADREQ	EQU	07h	; Request of ASCII characters programmed
				; on the dedicated digit key
BIKEYPADRSP	EQU	08h	; Response of ASCII characters programmed
				; on the dedicated digit key
BIKEYPADUPD	EQU	09h	; ASCII characters programmed
				; on the dedicated digit key
				; during preprogramming
BIEXTMAIL	EQU	0Ah	; Broadcasts external voice mail address
				; to operator
BIDAYNIGHT	EQU	0Bh	; Information about the status of the system
				; day/night switch.
BIDDICHGREQ	EQU	0Ch	; request notification messages about
				; DDI table changes
BIDDICHGUPD	EQU	0Dh	; receive notification messages with the
				; DDI table changes
BIMOBEXNREQ	EQU	0Eh	; request the external number of a
				; Mobile Extension
BILICENSEREQ	EQU	0Fh	; Request for licensing information, related
				; to a particular feature
BILICENSEUPD	EQU	10H	; Licensing information, related to a
				; particular functionality

;----------------------------------------------------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
;	Offsets for BLOCKINFO,BIPRODUPD message
;----------------------------------------------------------------------------
PROTECTION1	EQU	DATA+1
PROTECTION2	EQU	DATA+2
PROTECTION3	EQU	DATA+3
PROTECTION4     EQU     DATA+4

;----------------------------------------------------------------------------
;	Bit position symbols for protection field 1
;----------------------------------------------------------------------------
PRTCTIV21	EQU	0	; Version 2.1 functionality of CTI
PRTMONOP	EQU	1	; Monitorign of operator instrument + queue
PRTACCOUNTV24	EQU	2	; Enhanced CIL functionality
PRTTANDEMCTI	EQU	3	; Tandem configuration with CTI
PRTNWQSIG	EQU	4	; Networking with QSIG
PRTNWFULL	EQU	5	; Full networking
PRTNWSMALL	EQU	6	; Small scale networking
PRTISDNCLIST	EQU	7	; ISDN caller list

;----------------------------------------------------------------------------
;	Bit position symbols for protection field 2
;----------------------------------------------------------------------------
PRTIAD		EQU	0	; Enhanced individual abbreviated dialling
PRTINFO		EQU	1	; Enhanced information system
PRTGAPPROT	EQU	2	; GAP protocol
PRTACDCCODES	EQU	3	; ACD multiple call codes
PRTSWAPBOARD	EQU	4	; Swapping of boards during operation
PRTUPGRADESW	EQU	5	; Remote upgrading of central software
PRTOMCORDL	EQU	6	; Cordless remote O&M
;		EQU	7	; not used

;----------------------------------------------------------------------------
;	Bit position symbols for protection field 3
;----------------------------------------------------------------------------
PRTISDNPMP	EQU	0	; ISDN point to multipoint
PRTMULTINC	EQU	0	; Multiple incoming call presentation
PRTDDITRANS	EQU	0	; ECE DDI number translation
PRTTARIFF	EQU	0	; Austrian call metering tariff
PRTPGREET	EQU	0	; VMU-HD individual greeting
PRTMOHIND	EQU	0	; Integrated MOH
PRTFNENH	EQU	0	; Fictive numbers extended/improved
PRTCTIGRP816	EQU	0	; CTI groups 8/16
PRTNUMREST	EQU	0	; Override number restriction in ISDN (Austria)
PRTX25X31       EQU     0       ; X.25 protocol and X.31 services (packet mode terminals)
PRTUUIGPF       EQU     0       ; UUS in MSI of GPF
PRTCOPACT	EQU	1	; CN/operator services active
PRTNW4		EQU	2	; Very small networking (4 interfaces)
;		EQU	3	; not used
;		EQU	4	; not used
;		EQU	5	; not used
PRTALTROUT	EQU	6	; Alternative routing on no line available
PRTCNNUMPLAN	EQU	6	; Adaption for CN numbering plan feature
PRTUUIT		EQU	7	; UUI Italy

;----------------------------------------------------------------------------
;	Bit position symbols for protection field 4
;----------------------------------------------------------------------------
PRTCONVREC    EQU     0         ; Conversation recording
PRTIED        EQU     0         ; Diversion individual to external destination
PRTGAP20      EQU     0         ; Integrated Cordless - GAP 2.0 protocol
PRTMULTMOH    EQU     0         ; Music on hold (1 integrated and 7 external sources or 8 external sources)
PRTUPGRADEFW  EQU     0         ; O&M - Remote FW upgrading
PRTNW2        EQU     1         ; Very small networking (2 interfaces)

PRTSUMTIMISDN EQU     4         ; Automatic summer / winter time change from ISDN
PRTACCCODEVFY EQU     4         ; Verified Account Codes
PRT3PARTYCONF EQU     4         ; 3-Party conference on ISDN
PRTPARTREROUT EQU     4         ; Call forwarding with partial re-routing
PRTCENTREX    EQU     4         ; Centrex Hook Flash over ISDN
PRTOUTCALL    EQU     4         ; Outcall notification
PRTDDISTEP3   EQU     4         ; Number translation
PRTLEAVEACD   EQU     4         ; Leave ACD queue via exit position
PRTMULTREDIAL EQU     4         ; Multi number redial
PRTIPEXT      EQU     4         ; IP Extensions proprietary, IP Extensions H.323
PRTVOIPGW     EQU     5         ; BusinessPhone VoIP Gateway

PRTCCOLLECT   EQU     7         ; Call Collect Blocking

;----------------------------------------------------------------------------
;	List of protected features
;----------------------------------------------------------------------------
;RBEG,OTHERS
;                               ;   ASB 150 02, R9/R10
PRTIDCTIV21	EQU	00h	;   Version 2.1 functionality of CTI
PRTIDMONOP	EQU	01h	;   Monitorign of operator instrument + queue
PRTIDACCOUNTV24	EQU	02h	;   Enhanced CIL functionality
PRTIDTANDEMCTI	EQU	03h	;   Tandem configuration with CTI
PRTIDNWQSIG	EQU	04h	;   Networking with QSIG
PRTIDNWFULL	EQU	05h	;   Full networking
PRTIDNWSMALL	EQU	06h	;   Small scale networking
PRTIDISDNCLIST	EQU	07h	;   ISDN caller list
PRTIDIAD	EQU	08h	;   Enhanced individual abbreviated dialling
PRTIDINFO	EQU	09h	;   Enhanced information system
PRTIDGAPPROT	EQU	0Ah	;   GAP protocol
PRTIDACDCCODES	EQU	0Bh	;   ACD multiple call codes
PRTIDSWAPBOARD	EQU	0Ch	;   Swapping of boards during operation
PRTIDUPGRADESW	EQU	0Dh	;RP Remote upgrading of central software
PRTIDOMCORDL	EQU	0Eh	;   Cordless remote O&M
;		EQU	0Fh	;   not used
;                               ;   ASB 150 02, R11
PRTIDUUIT	EQU	10h	;   UUI Italy
PRTIDCNNUMPLAN	EQU	11h	;   Adaption for CN numbering plan feature
PRTIDALTROUT	EQU	12h	;   Alternative routing on no line available
PRTIDNUMREST	EQU	13h	;   Override number restriction in ISDN (Austria)
PRTIDISDNPMP	EQU	14h	;   ISDN point to multipoint
PRTIDMULTINC	EQU	15h	;   Multiple incoming call presentation
PRTIDDDITRANS	EQU	16h	;   ECE DDI number translation
PRTIDTARIFF	EQU	17h	;   Austrian call metering tariff
PRTIDPGREET	EQU	18h	;   VMU-HD individual greeting
PRTIDMOHIND	EQU	19h	;   Integrated MOH
PRTIDFNENH	EQU	1Ah	;   Fictive numbers extended/improved
PRTIDCOPACT	EQU	1Bh	;   CN/operator services active
PRTIDCTIGRP816	EQU	1Ch	;   CTI groups 8/16
PRTIDNW4        EQU     1Dh     ;   Very small networking (4 interfaces)
PRTIDX25X31     EQU     1Eh     ;   X.25 protocol and X.31 services (packet mode terminals)
PRTIDUUIGPF     EQU     1Fh     ;   UUS in MSI of GPF
;                               ;   ASB 150 02, R12
PRTIDCONVREC    EQU     20h     ;   Conversation recording
PRTIDIED        EQU     21h     ;   Diversion individual to external destination
PRTIDGAP20      EQU     22h     ;   Integrated Cordless - GAP 2.0 protocol
PRTIDMULTMOH    EQU     23h     ;   Music on hold (1 integrated and 7 external sources or 8 external sources)
PRTIDUPGRADEFW  EQU     24h     ;   O&M - Remote FW upgrading
PRTIDNW2        EQU     25h     ;   Very small networking (2 interfaces)
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;		EQU	26h	;   not used
;                               ;   ASB 150 02, R13
PRTIDSUMTIMISDN	EQU     30h	;   Automatic summer / winter time change from ISDN
PRTIDACCCODEVFY	EQU     31h	;   Verified Account Codes
PRTID3PARTYCONF	EQU     32h	;   3-Party conference on ISDN
PRTIDPARTREROUT EQU     33h     ;   Call forwarding with partial re-routing
PRTIDCENTREX    EQU     34h     ;   Centrex Hook Flash over ISDN
PRTIDOUTCALL    EQU     35h     ;   Outcall notification
PRTIDDDISTEP3   EQU     36h     ;   Number translation
PRTIDLEAVEACD   EQU     37h     ;   Leave ACD queue via exit position
PRTIDMULTREDIAL EQU	38h	;   Multi number redial
PRTIDIPEXT      EQU     39h     ;   IP Extensions proprietary, IP Extensions H.323
PRTIDVOIPGW     EQU     3Ah     ;   BusinessPhone VoIP Gateway
PRTIDMOBEXT	EQU	3Bh	;   Mobile Extension

PRTIDCCOLLECT   EQU     40h     ;   Call Collect Blocking

;REND (others)

;----------------------------------------------------------------------------
;	List of licensed features in the new licensing concept
;----------------------------------------------------------------------------
;RBEG,OTHERS
;				;   ASB 150 02, R14
LICR14BASIC	EQU	0001h	;   R14 Basic
LICMOBEXT	EQU	0002h	;   Mobile Extension
LICUNIMSG	EQU	0003h	;   Unified Messaging
LICCTI		EQU	0004h	;   CTI
LICNETWORKING	EQU	0005h	;   Networking
LICVOIPGATEWAY	EQU	0006h	;   VoIP Gateway

LICDEFAULT	EQU	0000h	;   Feature has to use default license count
LICTEMPORARY	EQU	0FFFFh	;   Feature is fully open, temporary license

;REND (others)

  PAGE
;----------------------------------------------------------------------------
; 12.80   CICTRL
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, CICTRL
;----------------------------------------------------------------------------
CISTORE		EQU	00h	; store calling party number
CILIST		EQU	01h	; dirno amount of calling party numbers
				; in list
CIACK		EQU	02h	; attempt to connect calling party number
				; was answered
CINAK		EQU	03h	; attempt to connect calling party number
				; was not answered
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.81   MUCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,  SUBCODES
;RCODE, MUCTRL
;----------------------------------------------------------------------------
MUIDLECHN	EQU	00h	; background music PCM channel
MUHOLDCHN	EQU	01h	; music on hold PCM channel
MUACK		EQU	02h	; answer msg for subcodes MUIDLECHN and MUHOLDCHN
MUNAK		EQU	03h	; answer msg for subcodes MUIDLECHN and MUHOLDCHN
MUANNOLOADED	EQU	04h	; inform that announcements are loaded
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.82    UPDIND-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, UPDIND
;----------------------------------------------------------------------------
DELIND		EQU	50h	; Delete individuals directory number
DELINDRDY	EQU	51h	; Clearing of directory number ready
UPDROP		EQU	52h	; Request for handover IP call
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.83    PNRINFO-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, PNRINFO
;----------------------------------------------------------------------------
PNRI.REQ	EQU	00h	; Request TON programmed for given PNR number
PNRI.ANSW	EQU	01h	; Send TON programmed for given PNR number
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.84    OMPCCOM-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, OMPCCOM
;----------------------------------------------------------------------------
CMPRCSMDATA	EQU	0B1ACh	; Exchange data with Cordless System Manager
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.85    ALARMCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ALARMCTRL
;----------------------------------------------------------------------------
ALARMACT	EQU	00h	; Activate alarm for extension with incl. dirno
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.86    GROUPCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, GROUPCTRL
;----------------------------------------------------------------------------
GRPC.SEIZ	EQU	01h	; Group ringing request to a member 
				; of a PBX group
GRPC.ACK	EQU	02h	; Receiver accepts request and invokes ringing
GRPC.NAK	EQU	03h	; Receiver rejects request
GRPC.REL	EQU	04h	; Group ringing released.
				; Receiver returns to idle.
GRPC.QUERY	EQU	05h	; Sender requests data of actual call
GRPC.DATA	EQU	06h	; Response to GRPC.QUERY
GRPC.MEMBCHK	EQU	07h	; Sender queries if member of a particular
				; PBX group
GRPC.MEMBACK	EQU	08h	; Member of desired PBX group
GRPC.MEMBNAK	EQU	09h	; Not a member of desired PBX group
GRPC.GRPLOGIN	EQU	0Ah	; All traffic from desired PBX group enabled
GRPC.GRPLOGOUT	EQU	0Bh	; All traffic from desired PBX group disabled
GRPC.ALLLOGOUT	EQU	0Ch	; All traffic from all PBX groups disabled
GRPC.ALLLOGIN	EQU	0Dh	; All traffic from all PBX groups enabled
GRPC.RENO	EQU	0Eh	; Member Re-notification: The member is free again
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.87    IPDATA-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, IPDATA
;----------------------------------------------------------------------------
IPBASWR		EQU	01h	;RP  Write basic IP data record
IPRECWR		EQU	02h	;RP  Write extended IP data record (linked record)
IPWRACK		EQU	03h	;RP  Positive write acknowledgment
IPWRNAK		EQU	04h	;RP  Negative write acknowledgment
IPRDREQ		EQU	05h	;RP  Request for read of dynamic data
IPRDANSW	EQU	06h	;RP  Answer to read request for dynamic data
IPDATARDY	EQU	07h	;RP  Write IP data ready
IPEXREGPAR	EQU	08h	;RP  Write extension registration parameter
IPLOCREQ	EQU	09h	;RP  Location request
IPLOCRESP	EQU	0Ah	;RP  Location response
IPSYS1WR	EQU	0Bh	;RP  Write IPU related system data (record 1)
IPSYS2WR	EQU	0Ch	;RP  Write IPU related system data (record 2)
IPLOCTERM	EQU	0Dh	;RP  Location terminated
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.88    UPGRAD-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, UPGRAD
;----------------------------------------------------------------------------
UPGRDREQ	EQU	01h	;RP  Upgrade start request 
UPGRDREQREJ	EQU	02h	;RP  Upgrade request rejected 
UPGRDSTART	EQU	03h	;RP  Upgrade start command
UPGRDCONT	EQU	04h	;RP  Upgrade procedure continues
UPGRDCOMPL	EQU	05h	;RP  Upgrade procedure successfully performed
UPMEMWR		EQU	11h	;RP  Upgrade memory write request
UPMEMCLEAR	EQU	12h	;RP  Upgrade memory storage clear request
UPMEMCLEARACK	EQU	13h	;RP  Upgrade memory clear acknoledgement
UPMEMCLEARNAK	EQU	14h	;RP  Upgrade memory clear error indication
UPMEMCHK	EQU	15h	;RP  Upgrade memory check request
UPMEMCHKACK	EQU	16h	;RP  Upgrade memory check acknoledgement
UPMEMCHKNAK	EQU	17h	;RP  Upgrade memory check error indication
UPLLISTREQ	EQU	20h	;RP  Upload request list of images 
UPLLISTRES	EQU	21h	;RP  Upload request list of images response
UPLIMAGEREQ	EQU	22h	;RP  Upload request image 
UPLIMAGERES	EQU	23h	;RP  Upload request image response
UPLLINEREQ	EQU	24h	;RP  Upload request line
UPLLINERES	EQU	25h	;RP  Upload request line response
UPLIMAGEENDREQ	EQU	26h	;RP  Upload end image request
UPLIMAGEENDRES	EQU	27h	;RP  Upload end image request response
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.89    ACCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ACCTRL
;----------------------------------------------------------------------------
ACACK		EQU	00h	;    Positive response - account code valid
ACNAK		EQU	01h	;    Negative response - account code iunvalid
ACCODE		EQU	02h	;    Check validity of account code
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.90    IPSIG-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, IPSIG
;----------------------------------------------------------------------------
IPSETUP		EQU	01h	;RP  Setup to/from H.323 client
IPSETUPACK	EQU	02h	;RP  Setup Acknowledge to/from H.323 client
IPPROCEED	EQU	03h	;RP  Call proceeding to H.323 client
IPALERTING	EQU	04h	;RP  Alerting to/from H.323 client
IPCONNECT	EQU	05h	;RP  Connect to/from H.323 client
IPRELEASE	EQU	06h	;RP  Release to/from H.323 client
IPCONP		EQU	07h	;RP  Connected party info to H.323 client
IPCWAIT		EQU	08h	;RP  Call waiting indication
IPCLIP		EQU 	09h	;RP  Calling party display info
IPINQUIRY	EQU	0Ah	;RP  Inquiry from H.323 client
IPMWI		EQU	0Bh	;RP  Message waiting indication
IPIDLE		EQU	0Ch	;RP  Idle display update for D4-IP
IPFUNCSETUP	EQU     0Dh     ;RP  Programmable key pressed

;			0Dh-20h ;    spare

IPREGISTER	EQU	21h	;RP  H.323 client has registered
IPUNREGISTER	EQU	22h	;RP  H.323 client has unregistered

;			23h-0BDh ;   spare

IPSTCHREQ	EQU	0BEh	;RP  Request a state change
IPSTCHACK	EQU	0BFh	;RP  State change acknowledge
IPSTCHNAK	EQU	0C0h	;RP  State change negative acknowledge

;			0C1h-0C7h ;  spare

IPTRANSDATA	EQU	0C8h	;RP  Transparent data from IPU
	
;			0C9h-0FFh ;  spare
;----------------------------------------------------------------------------
;REND (subcodes)

  PAGE
;----------------------------------------------------------------------------
; 12.91    TRANSP-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TRANSP
;----------------------------------------------------------------------------
TRANSP_CONN	EQU	01h	;RP  Establish conn. CSM and ICCU2
TRANSP_CONN_ACK	EQU	02h	;RP  Positive ack upon connection request
TRANSP_CONN_NAK	EQU	03h	;RP  Negative ack upon connection request
TRANSP_INFO	EQU	04h	;RP  Transparent data exchange between
				;    periph. board and central SW block
TRANSP_DISC	EQU	05h	;RP  Terminate conn. between CSM and ICCU
;----------------------------------------------------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.92   ARCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, ARCTRL
;-----------------------------------
AR.ACTIVATE	EQU	00h	; Request Automatic Redialling
AR.RSPACTIVATE	EQU	01h	; Response to Automatic Redial request
AR.CANCEL	EQU	02h	; Cancel Automatic Redialling
AR.RSPCANCEL	EQU	03h	; Response to Automatic Redial cancelling
AR.SUSPEND	EQU	04h	; Pause Automatic Redialling
AR.RSPSUSPEND	EQU	05h	; Response to Automatic Redial pausing
AR.RESUME	EQU	06h	; End pausing of Automatic Redialling
AR.RSPRESUME	EQU	07h	; Response to Automatic Redial end pausing
AR.READY	EQU	08h	; EX/OP idle indication
AR.RESERVE	EQU	09h	; Reserve EX/OP instrument when AR is started
AR.RSPRESERVE	EQU	0Ah	; Response to EX/OP instrument reserving
AR.INVOKE	EQU	0Bh	; Make EX/OP to start call back ringing and
				; to display 'Auto Redial Call'
AR.SEIZBOOK	EQU	0Ch	; Make EX/OP to reroute own connection to AR 
				; to external party
AR.RELEASE	EQU	0Dh	; Release EX/OP connections to AR
AR.KEYINFO	EQU	0Eh	; Send programmable AR key data to AR
AR.NUMBER	EQU	0Fh	; Send number to be redialled to EX/OP
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.93   BREAKINCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, BREAKINCTRL
;-----------------------------------
;			...
BREAKINCONG	EQU	03h	; Congestion during breakin attempt
;		EQU	...
;BREAKINQ	EQU	05h	; Break-in question
;BREAKINNAK	EQU	06h	; Break-in non acknowledgement
;BREAKINACK	EQU	07h	; Break-in acknowledgement
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.94   CONFCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, CONFCTRL
;-----------------------------------
;			...
CONFCONG	EQU	03h	; Congestion during conference attempt
;			...
;CONFACK	EQU	2Dh	; Conference acknowledgement
;CONFNAK	EQU	2Eh	; Conference non acknowledgement
;CONFQ		EQU	2Fh	; Ask if conference is accepted
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.95   TFRCTRL-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, TFRCTRL
;-----------------------------------
;			...
TFRCONG		EQU	03h	; Congestion during transfer attempt
;			...
;TFRACK		EQU	28h	; Transfer acknowledgement
;TFRNAK		EQU	29h	; Transfer non acknowledgement
;TFRQ		EQU	2Ah	; Transfer question
;-----------------------------------
;REND (subcodes)

;----------------------------------------------------------------------------
; 12.96   LICFUNC-message, subcodes.
;----------------------------------------------------------------------------
;RBEG,SUBCODES
;RCODE, LICFUNC
;-----------------------------------
;			...
LICSUPPORT	EQU	01h	;RP RP->CP(OM) tells CSW that this card supports license messages
LICAVAIL	EQU	02h	;RP RP<-CP(OM) request available licenses
LICAVAILACK	EQU	03h	;RP RP->CP(OM) requested licenses available
LICAVAILNACK	EQU	04h	;RP RP->CP(OM) requested licenses not available
LICINSTALL	EQU	05h	;RP RP<-CP(OM) install new license file
LICERASE	EQU	06h	;RP RP<-CP(OM) erase license file
LICREADY	EQU	07h	;RP RP->CP(OM) license handler ready
LICSYSID	EQU	08h	;RP RP<-CP(OM),
;				    RP(CPU)<-CP(OM)
;				    RP(CPU)->CP(OM) system ID
LICSTORID	EQU	09h	;RP RP->CP(OM)
;				    RP<-CP(OM) storage ID
;			0Ah	;   not used, defined internally within OM
LICCHECK	EQU	0Bh	;RP RP<-CP(OM) license status request
LICCHECKACK	EQU	0Ch	;RP RP->CP(OM) license status response
;			0Dh	;   not used
;			0Eh	;   not used
;			0Fh	;   not used
LICAPPREQ	EQU	10h	;RP RP<-CP(OM) Request information about external licenses
LICAPPRESP	EQU	11h	;RP RP->CP(OM) Response of external license information in encrypted format
LICCHKEXT	EQU	12h	;RP RP<-CP(OM) Request information about external licenses for displaying purpose (BMS)
LICCHKEXTACK	EQU	13h	;RP RP->CP(OM) Response of external license information in readable format
LICCTIREP	EQU	14h	;RP RP->CP(CT) External applciation license information in encrypted format to CT block.
;-----------------------------------
;REND (subcodes)


;----------------------------------------------------------------------------
; 13.	MOREOVER
;----------------------------------------------------------------------------
;	Data definitions without own headline in this document.
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; 13.1	Data for OS.BUFFER OS.TIMER and OU.CHANNEL CHECK calls
;
;       Input data to routine OS.BUFFER  CHECK
;                             OS.TIMER   CHECK
;                             OU.CHANNEL CHECK
;
;       Used to specify additional functions besides the check of the
;       lock up of the common resources (the resource watchdog).
;---------------------------------------------------------------------------
CHK.INT   EQU   00000001B  ; To do an internal variable check (if any)
CHK.HIL   EQU   00000010B  ; To use the high level for the resource check
CHK.WRN   EQU   00000100B  ; To execute an os.warning on failured resources
CHK.IDL   EQU   00001000B  ; To initiate the 'idle busy' variable 
CHK.UPD   EQU   00010000B  ; To update the 'low busy' variable

;---------------------------------------------------------------------------
; 13.2	SUFFIX-FUNCTIONS (answer codes from OU.CALL PA.SUFFIX)
;	Value 0-9 are allowed for general use here,
;	Value A-E are used internally in EX,
;	Value F   is used internally in PA as 'vacant' (no suffix function)
;--------------------------------------------------------------------------
SUF.CWAIT	EQU	4	; Call waiting
SUF.CBACK	EQU	5	; Call back
SUF.CPU 	EQU	6	; Call pickup
SUF.PAG 	EQU	7	; Radio paging
SUF.BRKIN	EQU	8	; Executive intrusion
SUF.MESS	EQU	9	; Message
;--------------------------------------------------------------------------
  PAGE
;----------------------------------------------------------------------------
; 13.3	Internal character set.
;
;	Used for text in LCD and for printing.
;----------------------------------------------------------------------------
; 13.3.1	The ASB 150 'ASCII' set
;
;		Range 00 - FFh	Only here declared vaues are allowed to use,
;				for other values see CHAR.INVALID in 13.3.2
;----------------------------------------------------------------------------
			;   Control codes.            (In V3 standard)
;RBEG,CHARACTERS
;---------------
			;   --------------            ----------------
EOT     EQU     004h	;RP String terminator.        (End of transmission).
NEWPAGE EQU     00Ch	;   New page.                 (Form feed)
NEWLINE EQU     00Dh	;   New line.                 (Carriage return)
BOLD    EQU     01Ch	;   Start bold face printing.
ULINE   EQU     01Dh	;   Start underline printing.
ELONG   EQU     01Eh	;   Start elongated printing.
NORM    EQU     01Fh	;   Normal printing.
                        
			;   Character codes
			;   --------------            
SPACE1  EQU     020h	;RP One blank position  (see SPACES below)
DQUOTE	EQU	'^"'	;   double quote
SQUOTE	EQU	'^''	;   singel quote
UARROW	EQU	'^^'	;   double quote
;			;
;		020h	;   Norml US-ASCII in the range 20h - 7Dh
;		...	;   are also allowed to use with the normal
;		07Dh	;   assembler syntax ASCII 'abcd...' or  BYTE 'x'
;			;
RARROW  EQU     07Eh	;   Rigth arrow
LARROW  EQU     07Fh	;   Left arrow

NOCHAR  EQU     080h	;RP No character, do not move character-position
SPACES  EQU     080h	;RP Abbreviated spaces, SPACES+1 to SPACES+80

SMLAA   EQU     0D1h	;RP Small Swedish aa
BIGAA   EQU     0D2h	;RP Big   Swedish AA
SMLAE   EQU     0E1h	;RP Small Swedish ae
BIGAE   EQU     0D3h	;RP Big   Swedish AE
SMLOE   EQU     0DCh	;RP Small Swedish oe
BIGOE   EQU     0EFh	;RP Big   Swedish OE
SMLDAE  EQU     0DAh	;RP Small Danish  ae
BIGDAE  EQU     0FCh	;RP Big   Danish  AE
SMLDOE  EQU     0D9h	;RP Small Danish  oe
BIGDOE  EQU     0EDh	;RP Big   Danish  OE
SMLGU   EQU     0F5h	;RP Small German  u
BIGGU   EQU     0D4h	;RP Big   German  U
SMLEE   EQU     0D5h	;   Small   e'    ee
BIGEE   EQU     0D6h	;   Big     E'    EE
SMLSN   EQU     0EEh	;   Small Spanish n
FDELIM  EQU     0D8h	;RP Field delimiter for operator instrument
ESQUARE EQU     0DBh	;   Empty  square
FSQUARE EQU     0FFh	;   Filled square
DEGREE	EQU	0DFh	;RP The degree symbol
SQRT	EQU	0E8h   	;RP 'Square root' used only to indicate an invalid
			;    character (see CHAR.INVALID below)
BIGHAE	EQU	0D1h	;   Big Hungarian A'
BIGHEE	EQU	0D2h	;   Big Hungarian E'
BIGHOO	EQU	0D3h	;   Big Hungarian O'
BIGHGUE	EQU	0D4h	;   Big Hungarian U/\
BIGHOE	EQU	0DAh	;   Big Hungarian O~
BIGHUE	EQU	0FCh	;   Big Hungarian UE
BIGHUU	EQU	0D9h	;   Big Hungarian U'

SMLPEE	EQU	0D1h	;   Small Polish e_
SMLPCC	EQU	0D2h	;   Small Polish c'
SMLPNN	EQU	0D3h	;   Small Polish n'
SMLPLL	EQU	0D4h	;   Small Polish l/
SMLPSS	EQU	0DAh	;   Small Polish s'
SMLPOO	EQU	0FCh	;   Small Polish o'
SMLPZZ	EQU	0D9h	;   Small Polish z.

BIGSCC	EQU	0D1h	;   Big Slovenian C\/
BIGSSS	EQU	0D2h	;   Big Slovenian S\/
BIGSZZ	EQU	0D3h	;   Big Slovenian Z\/

SMSFES	EQU	0D1h	;   Small Swiss e'
SMSFEB	EQU	0D2h	;   Small Swiss e`
SMLSFS	EQU	0D3h	;   Swiss single quote
BGSFES	EQU	0D4h	;   Big Swiss E'
BGSFII	EQU	0DAh	;   Big Swiss I/\
BGSFUE	EQU	0FCh	;   Big Swiss U/\
BGSFAA	EQU	0D9h	;   Big Swiss A`

SMLIFS	EQU	0D1h	;   Italian single quote

SMLEOE	EQU	0D1h	;   Small Estonian oe

BIGCSC	EQU	0D1h	;   Big Slovakian C\/
BIGCSS	EQU	0D2h	;   Big Slovakian S\/
BIGCSZ	EQU	0D3h	;   Big Slovakian Z\/
BIGCSO	EQU	0D4h	;   Big Slovakian O/
BIGCSOO	EQU	0DAh	;   Big Slovakian O/\
BIGCSU	EQU	0FCh	;   Big Slovakian U/

SMLLAA	EQU	0D1h	;   Small Lithuanian a,
SMLLEE	EQU	0D2h	;   Small Lithuanian e'
SMLLII	EQU	0D3h	;   Small Lithuanian i,
SMLLSS	EQU	0D4h	;   Small Lithuanian s\/
SMLLZZ	EQU	0DAh	;   Small Lithuanian z\/
SMLLUE	EQU	0FCh	;   Small Lithuanian u-
SMLLCC	EQU	0D9h	;   Small Lithuanian c\/

RDEGREE	EQU	06h	;RP The cyrillic degree symbol
RDELIM	EQU	07h	;RP Cyrillic field delimiter for operator instrument

BIGRJO	EQU	0A1h	;   Big cyrillic JO
BIGRDJ	EQU	0A2h	;   Big cyrillic DJ
BIGRGA	EQU	0A3h	;   Big cyrillic G'
BIGRJE	EQU	0A4h	;   Big cyrillic JE
BIGRDZ	EQU	0A5h	;   Big cyrillic (macedonian)DZ
BIGRUI	EQU	0A6h	;   Big cyrillic (ukranian) I
BIGRUJ	EQU	0A7h	;   Big cyrillic (ukranian) J
BIGRSJ	EQU	0A8h	;   Big cyrillic (serbian) J
BIGRLJ	EQU	0A9h	;   Big cyrillic (serbian) LJ
BIGRNJ	EQU	0AAh	;   Big cyrillic (serbian) NJ
BIGRCA	EQU	0ABh	;   Big cyrillic (serbian) C/\
BIGRMK	EQU	0ACh	;   Big cyrillic (macedoian) K'
;spare	EQU	0ADh	;   
BIGRWU	EQU	0AEh	;   Big cyrillic (white russian) U
BIGRMD	EQU	0AFh	;   Big cyrillic (macedonian) DZ
BIGRAA	EQU	0B0h	;   Big cyrillic A
BIGRBB	EQU	0B1h	;   Big cyrillic B
BIGRVV	EQU	0B2h	;   Big cyrillic V
BIGRGG	EQU	0B3h	;   Big cyrillic G
BIGRDD	EQU	0B4h	;   Big cyrillic D
BIGREE	EQU	0B5h	;   Big cyrillic E
BIGRZH	EQU	0B6h	;   Big cyrillic ZH (SCH)
BIGRZZ	EQU	0B7h	;   Big cyrillic Z
BIGRII	EQU	0B8h	;   Big cyrillic I
BIGRJJ	EQU	0B9h	;   Big cyrillic J
BIGRKK	EQU	0BAh	;   Big cyrillic K
BIGRLL	EQU	0BBh	;   Big cyrillic L
BIGRMM	EQU	0BCh	;   Big cyrillic M
BIGRNN	EQU	0BDh	;   Big cyrillic N
BIGROO	EQU	0BEh	;   Big cyrillic O
BIGRPP	EQU	0BFh	;   Big cyrillic P
BIGRRR	EQU	0C0h	;   Big cyrillic R
BIGRSS	EQU	0C1h	;   Big cyrillic S
BIGRTT	EQU	0C2h	;   Big cyrillic T
BIGRUU	EQU	0C3h	;   Big cyrillic U
BIGRFF	EQU	0C4h	;   Big cyrillic F
BIGRCH	EQU	0C5h	;   Big cyrillic CH
BIGRCC	EQU	0C6h	;   Big cyrillic C (TS)
BIGRCT	EQU	0C7h	;   Big cyrillic C/\(CH)
BIGRSH	EQU	0C8h	;   Big cyrillic S/\(SH)
BIGRSC	EQU	0C9h	;   Big cyrillic S/\C/\ (SHCH)
BIGRSM	EQU	0CAh	;   Big cyrillic smart
BIGRYY	EQU	0CBh	;   Big cyrillic Y
BIGRHA	EQU	0CCh	;   Big cyrillic hard
BIGREP	EQU	0CDh	;   Big cyrillic E.
BIGRJU	EQU	0CEh	;   Big cyrillic YU (JU)
BIGRJA	EQU	0CFh	;   Big cyrillic YA (JA)

SMLRAA	EQU	0D0h	;   Small cyrillic a
SMLRBB	EQU	0D1h	;   Small cyrillic b
SMLRVV	EQU	0D2h	;   Small cyrillic v
SMLRGG	EQU	0D3h	;   Small cyrillic g
SMLRDD	EQU	0D4h	;   Small cyrillic d
SMLREE	EQU	0D5h	;   Small cyrillic e
SMLRZH	EQU	0D6h	;   Small cyrillic zh (SCH)
SMLRZZ	EQU	0D7h	;   Small cyrillic z
SMLRII	EQU	0D8h	;   Small cyrillic i
SMLRJJ	EQU	0D9h	;   Small cyrillic j
SMLRKK	EQU	0DAh	;   Small cyrillic k
SMLRLL	EQU	0DBh	;   Small cyrillic l
SMLRMM	EQU	0DCh	;   Small cyrillic m
SMLRNN	EQU	0DDh	;   Small cyrillic n
SMLROO	EQU	0DEh	;   Small cyrillic o
SMLRPP	EQU	0DFh	;   Small cyrillic p
SMLRRR	EQU	0E0h	;   Small cyrillic r
SMLRSS	EQU	0E1h	;   Small cyrillic s
SMLRTT	EQU	0E2h	;   Small cyrillic t
SMLRUU	EQU	0E3h	;   Small cyrillic u
SMLRFF	EQU	0E4h	;   Small cyrillic f
SMLRCH	EQU	0E5h	;   Small cyrillic ch
SMLRCC	EQU	0E6h	;   Small cyrillic c (TS)
SMLRCT	EQU	0E7h	;   Small cyrillic c/\ (CH)
SMLRSH	EQU	0E8h	;   Small cyrillic s/\ (SH)
SMLRSC	EQU	0E9h	;   Small cyrillic s/\c/\ (SHCH)
SMLRSM	EQU	0EAh	;   Small cyrillic smart
SMLRYY	EQU	0EBh	;   Small cyrillic y
SMLRHA	EQU	0ECh	;   Small cyrillic hard
SMLREP	EQU	0EDh	;   Small cyrillic e.
SMLRJU	EQU	0EEh	;   Small cyrillic yu (JU)
SMLRJA	EQU	0EFh	;   Small cyrillic ya (JA)
;spare	EQU	0F0h	;    
SMLRJO	EQU	0F1h	;   Small cyrillic jo
SMLRDJ	EQU	0F2h	;   Small cyrillic dj
SMLRGA	EQU	0F3h	;   Small cyrillic g'
SMLRJE	EQU	0F4h	;   Small cyrillic je
SMLRDZ	EQU	0F5h	;   Small cyrillic (macedonian) dz
SMLRUI	EQU	0F6h	;   Small cyrillic (ukrainian) i
SMLRUJ	EQU	0F7h	;   Small cyrillic (ukrainian) j
SMLRSJ	EQU	0F8h	;   Small cyrillic (serbian) j
SMLRLJ	EQU	0F9h	;   Small cyrillic (serbian) lj
SMLRNJ	EQU	0FAh	;   Small cyrillic (serbian) nj
SMLRCA	EQU	0FBh	;   Small cyrillic (serbian) c/\
SMLRMK	EQU	0FCh	;   Small cyrillic (macedonian) k'
;spare	EQU	0FDh	;
SMLRWU	EQU	0FEh	;   Small cyrillic (white russian) u
SMLRMD	EQU	0FFh	;   Small cyrillic (macedonian) dz


  PAGE
;----------------------------------------------------------------------------
; 13.3.2	Characters for special use or indication
;		
;----------------------------------------------------------------------------
;				;--------------------------------------------
CHAR.UNDEF  	EQU	'?'	; Character for representation of undefined
;				; values according to current presentation 
;				; format. 
;				; Example when a value = 255 that shall be
;				; displayed in a two digit field the display
;				; may show '??' (two CHAR.UNDEF)
;				;--------------------------------------------
CHAR.INVALID	EQU	SQRT	; This character is used to indicate an 
;				; invalid character in a text received from
;				; any external or internal unit before the
;				; text is displayed.
;				; Example when a national character that not
;				; is defined in our internal character set 
;				; is received from an external unit, the 
;				; character shall be replaced with the
;				; CHAR.INVALID
;				;--------------------------------------------
;REND (characters)
  PAGE
;----------------------------------------------------------------------------
; 13.4	 Floating point declarations
;----------------------------------------------------------------------------
				;--------------------------------------------
FS.SIZE		EQU	3	; Size of a single precicion floating point
				; number is 3 bytes
				;--------------------------------------------
FD.SIZE		EQU	5	; Size of a double precicion floating point
				; number is 5 bytes
				;--------------------------------------------
FB.SIZE		EQU	15	; Size of a floating point number as a BCD-
				; string is 15 bytes
				;--------------------------------------------
  PAGE
;----------------------------------------------------------------------------
; 13.5	Equations for predigits
;----------------------------------------------------------------------------
				;--------------------------------------------
PRE.NONUM	EQU	0FFFFH	; default number for predigits
				;--------------------------------------------
  PAGE
;---------------------------------------------------------------------------
; 13.6	Definitions for utility call OU.CALL PA.PUBLICNO
;--------------------------------------------------------------------------

;-----------------------------------------
;	Input data  / type of combination
;-----------------------------------------

NUM.ADD		EQU	00h	; internal directory number should be added
				; to the public directory number
NUM.REPL	EQU	01h	; last digits in the public directory number
				; should be replaced by the internal directory
				; number (specially for MFE)

;------------------------------------
;	Output data / type of number
;------------------------------------

;	see SISIG-message
  PAGE
;---------------------------------------------------------------------------
; 13.7	Systemtype definitions for utility call OU.CALL PA.SYSTEMTYPE
;--------------------------------------------------------------------------

SYS.STD		EQU	0	; standars system
SYS.MLTRES	EQU	1	; MLT residential system
SYS.MLTBUS	EQU	2	; MLT business system

  PAGE
;---------------------------------------------------------------------------
; 13.8	Definitions for OS.BATT calls / Battery RAM Handler
;--------------------------------------------------------------------------
; 13.8.1	Internal Definitions
;--------------------------------------------------------------------------

							; Map Header
BRBEG			EQU	6000h
BRSMAXBLK		EQU	6008h
BRFREELIST		EQU	600Ah
BREND			EQU	7FFFh

BRCHK1			EQU	0h			; 6000h - 6001h
BRCHK2			EQU	2h			; 6002h - 6003h
BRPRMMOD		EQU	4h			; 6004h
BRPREVMAP		EQU	5h			; 6005h
BRNEXTMAP		EQU	6h			; 6006h
BRSTATUS		EQU	7h			; 6007h

BRHSIZE			EQU	12
BRDAT			EQU	BRBEG+BRHSIZE
BRMAPSIZE		EQU	E1MAPSIZE-BRHSIZE

							; Pool Table
BRNOPOOLS		EQU	0
BRCPOOLID		EQU	1
BRCFIRSTMAP		EQU	2
BRCNOMAPS		EQU	3

							; ------------------------------------
							; The BRAM version characterizes the
							; data layout / memory management model
							; inside the BRAM handler.
							;
							; the MSB in the BRPRMMOD variable of
							; the 1st BRAM map (BRAM system map)
							; is used to distinguish between
							; BR.VERSION.0 (MSB=0) or higher (MSB=1).
							;
BRVERSIONMASK		EQU	80h			; BRAM Handler Version Mask
							;
							; another variable BRVERSION exists in
							; the BRAM system map and specifies
							; the BRAM handler version.
							;
							; --------------
							; BRAM versions
							; --------------
							;
BR.VERSION.0		EQU	0			; BRAM Handler Version 0
							; R10,R11
							;
							; values for BRAM Handler version 0
BR0POOL_TABLE		EQU	6005h			; 6005h - 61FFh                   0
BR0POOL_USER_TABLE	EQU	6200h			; 6200h - 6FFFh                   0
BR0POSS_USER_TABLE	EQU	7000h			; 7000h - 7FFFh                   0
BR0POOLUSERLST		EQU	BR0POSS_USER_TABLE-2	; 6FFEh - 6FFFh                   0
BR0POSSPOOLUSERLST	EQU	BR0FREE_SPACE-2		; 7FFEh - 7FFFh                   0
BR0FREE_SPACE		EQU	8000h			;
							;
							;
BR.VERSION.1		EQU	1			; BRAM Handler Version 1
							; R12, BRAM BasePointer invented
							;
							; values for BRAM Handler version 1
BRVERSION		EQU	5h			; 6005h                           1
BR.POOL_TABLE		EQU	6006h			; 6006h - 6068h                   1
BR.POOL_USER_TABLE	EQU	6069h			; 6069h - 67FFh                   1
BR.POSS_USER_TABLE	EQU	6800h			; 6800h - 6FFFh                   1
BR.FREE_SPACE		EQU	7000h			; 7000h - 7CFEh                   1
BR.MAPLASTOSBAT		EQU	7CFFh			; 7CFFh
BR.BASEPTR_TAB		EQU	7D00h			; 7D00h - ...                     1
BR.BASEPTR_TABEND	EQU	7FFFh			;   ... - 7FFFh                   1
BRPOOLUSERLST		EQU	BR.POSS_USER_TABLE-2	; 67FEh - 67FFh                   1
BRPOSSPOOLUSERLST	EQU	BR.FREE_SPACE-2		; 6FFEh - 6FFFh                   1
							;
							;
BR.VERSION.LATEST	EQU	BR.VERSION.1		; current BRAM version
							;

;--------------------------------------------------------------------------
; 13.8.2	General Common Definitions
;--------------------------------------------------------------------------

BR.POOL.ID		EQU	0
BR.LAST.MAP		EQU	1
BR.NR.MAPS		EQU	2
BR.PTE.SIZE		EQU	3

BR.NR.OF.MAPS		EQU	MAPLASTE1BAT-MAPFIRSTE1BAT

BR.FREE			EQU	0
BR.BUSY			EQU	1
BR.NULL			EQU	0FFh
BR.NULL.ADDR		EQU	0FFFFh

BR.RADDR		EQU	0
BR.RMAP			EQU	2
BR.RSIZE		EQU	3
BR.RDATA		EQU	5
BR.RHSIZE		EQU	5

BR.FBADDR		EQU	0
BR.FBSIZE		EQU	2
BR.FBNEXT		EQU	4
BR.FBHSIZE		EQU	6

;--------------------------------------------------------------------------
; 13.8.3	Error Numbers
;--------------------------------------------------------------------------

BRINVPOOLID		EQU	1
BRMEMORYLOW		EQU	2
BRSIZETOOLARGE		EQU	3
BRNOTUSER		EQU	4
BRINVMAP		EQU	5
BRRECNOTFOUND		EQU	6
BRMEMLOWFLIST		EQU	7
BRNOTPOSSUSER		EQU	8
BRBATINTERROR		EQU	9
BRLLNOTFOUND		EQU	10
BREOL			EQU	11
BRINVOFF		EQU	12
BRBADMAP		EQU	13
BRMAPUSAGE		EQU	14
BRINVADDR		EQU	15
BRRECALREADYLNK		EQU	16
BRRECNOTLINKED		EQU	17
BRNOMATCH		EQU	18
BRBOL			EQU	19
BRNOUSERDATA		EQU	20
BRPOOLALREADYEXI	EQU	21
BRCOMMPOOL		EQU	22
BRNOTOWNER		EQU	23
BRRESLESS		EQU	24
BRINVALIDST		EQU	25

;--------------------------------------------------------------------------
; 13.8.4	Pool IDs
;--------------------------------------------------------------------------

BR.POOL.COMM		EQU	1
BR.POOL.CI		EQU	2
BR.POOL.GL		EQU	3
BR.POOL.MG		EQU	4
BR.DYN.LOW		EQU	64



  PAGE
;---------------------------------------------------------------------------
; 13.9	Common definitions for messages
;--------------------------------------------------------------------------

;--------------
; Data format :
;--------------

; bit  0 :	CN-call back allowed
;---------
; bits 2-3 :	CN-status of destination
;-----------
CNSODFREE	EQU	0	; Free
CNSODBUSY	EQU	1	; Busy
CNSODUNDEF	EQU	0Fh	; Undefined

; bits 4-7 :	CN-service request answer
;-----------
CNACK		EQU	0	; Acknowledge, service accepted
CNTMPREJ	EQU	1	; Temporary rejection, service not available
				; in the moment
CNDEFREJ	EQU	2	; Definite rejection,
				; service not possible/allowed
CNUNDEF		EQU	0Fh	; No request answer

  PAGE
;----------------------------------------------------------------------------
; 13.10	Card types
;----------------------------------------------------------------------------
;	Symbols for card type, used in CARDREP,CTYPEANSW-message.
;

;     CARD TYPE VALUES:
;RBEG,CARDTYPES
				;
CTYPE.UNKNOWN	EQU	00h	;RP Unknown type
CTYPE.ELUD	EQU	01h	;RP Digital extension board
CTYPE.REG	EQU	02h	;RP Register board
CTYPE.VMU	EQU	03h	;RP Voice memory board
CTYPE.BTUDC	EQU	04h	;RP Digital trunk board, CAS
CTYPE.BTUDP	EQU	05h	;RP Digital trunk board, ISDN primary rate access
CTYPE.BTUB	EQU	06h	;RP Digital trunk board, ISDN basic access
CTYPE.MFU	EQU	07h	;RP Multi Function board
CTYPE.CPUD	EQU	08h	;RP Central Processor board
CTYPE.IPU	EQU	09h	;RP Internet protocol board
CTYPE.ICCU2	EQU	0Ah	;RP Integrated Cordless Control Unit 2
CTYPE.IAS	EQU	0Bh	;RP Integrated Application Server

				;   virtual cardtypes :
				;
CTYPE.VMOB	EQU	41h	;   Mobile Extension

				;   other cardtypes :
				;
CTYPE.NONE	EQU	0FFh	;RP Type not specified

;REND (cardtypes)

  PAGE
;----------------------------------------------------------------------------
; 13.11	Purposes of Restart
;----------------------------------------------------------------------------
;	Used in Warning 10h, D3, as explanation for intentional Restart.
;
					;
RSTPURP.NONE		EQU	0	; Purpose of Restart not specified
RSTPURP.UPGRDFW		EQU	1	; FW  remote upgrading,           SU
RSTPURP.UPGRDCSW	EQU	2	; CSW remote upgrading,           SU
RSTPURP.E2CONVERSION	EQU	3	; E2 Conversion,                  CE
RSTPURP.STOPWARNING	EQU	4	; Warning categ. STOP,            OM
RSTPURP.OMPCCOM		EQU	5	; Restart with OM Tool,           OM
RSTPURP.SYSTEMINSTR	EQU	6	; Restart with System Instrument, OM
RSTPURP.RAMERROR	EQU	7	; Error in non-mapped RAM,        OS
RSTPURP.SINGLEBOARD	EQU	8	; Restart of a single Board       OM

  PAGE
;----------------------------------------------------------------------------
; 13.12	Reason for Online-Coredump
;
;	Used to identify the reason for the Online-Coredump
;
;	values :	0	no valid dump
;			1-15	used by SP
;			>=16	used by CP
;
;----------------------------------------------------------------------------
;RBEG,OTHERS

ONDU.NODUMP		EQU	00h	;RP No valid dump

;					;----------
;					;RP values
;					;----------
;			EQU	01h   	;RP reserved for SP
;			...        	;RP reserved for SP
;			EQU	0Fh	;RP reserved for SP
;REND (others)
;
;					;----------
;					;CP values
;					;----------
ONDU.EXTSUPERVFAIL	EQU	10h	;   Extended supervision failure

ONDU.MEMWATCH		EQU	11h	;RP Memory Watch

  PAGE
;----------------------------------------------------------------------------
; 13.13	 OS Base Array Layout
;----------------------------------------------------------------------------
;

OSINTBASE_VERSION	EQU	1	; Version of BasePointerArray Layout
;OSINTBASE_SIZE		EQU	4	; OSINT BasePointerArray Size

;OSINTBASE_LEN		EQU	0	; (1) Length of BasePointer Array
;OSINTBASE_DEBMAP	EQU	1	; (1) Pointer Debug Functions (Map)
;OSINTBASE_DEBADDR	EQU	2	; (2) Pointer Debug Functions (Addr)

  PAGE
;----------------------------------------------------------------------------
; 13.14	 OS Debug Functions
;----------------------------------------------------------------------------
;

OSDEB_WATCHQNT		EQU	01h	; Number of Watches

;OSDEBSTAT_SIZE		EQU	OSDEB_WATCHQNT*4

OSDEB_CMDNAKMASK	EQU	80h	; Mask for Command NAK
OSDEB_WNRMASK		EQU	0Fh	; Mask for Watch Number


					; Commands (OSLDEBCMD)
					;
OSDEBCMD_INPUTMODE	EQU	00h	; Input Mode
					;
OSDEBCMD_SET		EQU	10h	; Set Watch
OSDEBCMD_CLR		EQU	20h	; Clear Watch
OSDEBCMD_ON		EQU	30h	; Watch On
OSDEBCMD_OFF		EQU	40h	; Watch Off

OSDEBCMD_ALLOFF		EQU	70h	; All Watches Off
OSDEBCMD_ALLON		EQU	71h	; All Watches On
OSDEBCMD_CLRALL		EQU	72h	; Clear All Watches

OSDEBCMD_ACTSTATUS	EQU	80h	; Active Status Display On


					; Sub Commands (OSLDEBPAR)
					;
OSDEBCMD_BUFTAB		EQU	01h	; Watch Buffer Tables
OSDEBCMD_BUFHEAD	EQU	02h	; Watch Buffer Tables


					; Command Value Ranges
					;					
OSDEBCMD_SETLOW		EQU	OSDEBCMD_SET
OSDEBCMD_SETHIGH	EQU	OSDEBCMD_SETLOW + OSDEB_WATCHQNT
OSDEBCMD_CLRLOW		EQU	OSDEBCMD_CLR
OSDEBCMD_CLRHIGH	EQU	OSDEBCMD_CLRLOW + OSDEB_WATCHQNT
OSDEBCMD_ONLOW		EQU	OSDEBCMD_ON
OSDEBCMD_ONHIGH		EQU	OSDEBCMD_ONLOW + OSDEB_WATCHQNT
OSDEBCMD_OFFLOW		EQU	OSDEBCMD_OFF
OSDEBCMD_OFFHIGH	EQU	OSDEBCMD_OFFLOW + OSDEB_WATCHQNT
OSDEBCMD_HIGH		EQU	80h

					; etc
					;
OSDEB_MAGIC		EQU	69h	; Magic Number used to override
					; OS.BATT READ,ST

;----------------------------------------------------------------------------
; 13.15	 Warning data for W.OSMERRD
;----------------------------------------------------------------------------

W_OSMERRD_DATA		EQU	1h	; Datamap
W_OSMERRD_E1E2		EQU	2h	; E1/E2/RTC-Map


	STITLE	'                    '
;;
	LIST
;	END OF	SYSTEM.DAT
;;--------------------------------------------------------------------------
