Google
 

Trailing-Edge - PDP-10 Archives - decuslib10-01 - 43,50035/ecmser.opr
There are no other files named ecmser.opr in the archive.
	HOW TO BUILD THE MUNICH REAL-TIME DATA ACQUISITION MONITOR


	THERE ARE FIVE MONITOR ROUTINES WHICH HAVE BEEN CHANGED
TO ACCOMODATE THE PDP-8 FEATURES (COMMON, UUOCON, CLKCSS, CLOCK1,
AND DLSINT).  THE CHANGES ARE NOTED BELOW.

	THE NUMBER OF PDP-8'S ON THE SYSTEM MUST BE DEFINED AT
MONGEN TIME.  THE SYMBOL TO BE DEFINED IS "ECMN".  IF NOT DEFINED THE
VALUE "2" IS ASSUMED.

	ALL MONITOR ROUTINES ARE ASSEMBLED NORMALLY AND THE SYSTEM
IS BUILT USING THE STANDARD LOADING PROCEEDURES.



	FILE MUNICH.REL CONTAINS THE BINARY FILES OF EACH SPECIAL
ROUTINE (COMMON, ECMSER, CLOCK1, CLKCSS, UUOCON, AND DLSINT).
THUS TO BUILD A MONITOR THE FOLLOWING COMMANDS ARE GIVEN:

^C

.R LOADER
*/S
*DTA1:MUNICH.REL
*DTA2:SYS40N.REL/L
*DTA3:MAP_/A/M/P/G

023102 IS THE PROGRAM BREAK

LOADER 16K CORE

EXIT
^C

.SAVE DTA3 MONITR
JOB SAVED
^C

.
	********** COMMON **********

FILE 1)	TITLE COMMON - MONITOR COMMON DATA AREA AND CONFIGURATION DEFINITION - V437
FILE 2)	TITLE COMMON - MONITOR COMMON DATA AREA AND CONFIGURATION DEFINITION - V437

1)2		IFNDEF ECMN,<ECMN==2>	;DEFAULT VALUE = 2
1)		INTERN LPTSIZ			;SIZE OF LPT BUFFER(NO. OF DATA WORDS+2)
****
2)2		INTERN LPTSIZ			;SIZE OF LPT BUFFER(NO. OF DATA WORDS+2)
***************
1)6	IFN	ECMN,<			;IF PDP-8'S ARE ATTACHED TO THE SYSTEM
1)	INTERN TIMSKP,TRPFLG,UUOTRA,IRQUE,IRQU1,IRQU2
1)	TIMSKP:	EXP 0
1)	TRPFLG:	EXP 0
1)	UUOTRA:	EXP 0
1)	IRQUE:	EXP 0
1)	IRQU1:	EXP 0
1)	IRQU2:	BLOCK ECMN
1)	>
1)7	;STORAGE FOR VARIOUS CORE ALLOCATION FUNCTIONS
****
2)7	;STORAGE FOR VARIOUS CORE ALLOCATION FUNCTIONS
***************
1)13	IFN ECMN,<BLOCK ECMN>
1)		TPYTAB==.-1		;ADDRESS OF LAST ENTRY
****
2)13		TPYTAB==.-1		;ADDRESS OF LAST ENTRY
***************
1)18	IFG ECMN,<
1)	DEFINE DA25DEF(DEV,PI)
1)	<
1)		EXTERN DEV'INT
1)		IFG PI, <
1)			IFE <PI-.CH>,<.CHAS==1		;CHANNEL PI IN USE>
1)			DEV'CHN==PI		;DEFINE DEVICE CHANNEL NUMBER
1)			INTERN DEV'CHN		;DECLARE INTERNAL - ONLY IF DEVICE WANTED
1)			USED'PI==1		;SET FLAG SO THAT A CHANNEL SAVE
1)						; ROUTINE WILL BE GENERATED FOR
1)						; THIS PI CHANNEL
1)		IFDEF SAV'PI, <		;WAIT TILL CHANNEL SAVE ROUTINES
1)						; ARE DEFINED BELOW (IN PASS 2)
1)			DEV'SAV==SAV'PI		;CHANNEL AC SAVE ROUTINE LOCATION
1)			DEV'RET==RET'PI		;CHANNEL AC RESTORE ROUTINE LOCATION
1)						; (USUALLY POPJ USED)
1)			DEV'CHL==CH'PI		;LOCATION WHERE INTERRUPT PC IS STORED
1)			DEV'SAC==SAVAC'PI	;STARTING CHANNEL SAVE LOCATION FOR AC'S
1)			INTERN DEV'SAV, DEV'RET, DEV'CHL, DEV'SAC
1)		>>
1)		XWD 1000+PI,DEV'INT		;INTERRUPT ROUTINE FOR DEVICE
1)		XWD 0,0			;NO DDB FOR THIS DEVICE
1)	>>
1)19	;MACRO'S TO ALLOW GENERATION OF MULTIPLE INTTAB ENTRIES FOR MULTIPLE
****
2)18	;MACRO'S TO ALLOW GENERATION OF MULTIPLE INTTAB ENTRIES FOR MULTIPLE
***************
1)20		ASGSAV ECM,0
1)	.CHAS==0
FILE 1)	TITLE COMMON - MONITOR COMMON DATA AREA AND CONFIGURATION DEFINITION - V437
FILE 2)	TITLE COMMON - MONITOR COMMON DATA AREA AND CONFIGURATION DEFINITION - V437

****
2)19	.CHAS==0
***************
1)21		DA25DEF(DVB,\.CH)
1)	NEXTCQ
****
2)20	NEXTCQ
***************
1)21		DA25DEF(DVA,\.CH)
1)	NEXTCQ
****
2)20	NEXTCQ
***************
1)38	IFG ECMN,<
1)	DEFINE GENETYTAB (ECMN)<
1)		REPEAT ECMN,<XWD 20000,0>>
1)	ETYTAB:	GENETYTAB (ECMN)
1)		EXTERN ECMSER
1)		INTERNAL ECONLN,ETYTAB,ECMN
1)	ECONLN=TCONLN-ECMN>
1)39	;MAGTAPE ENTRY POINT AND BIT DEFINITIONS
****
2)38	;MAGTAPE ENTRY POINT AND BIT DEFINITIONS
***************

	********** UUOCON **********

FILE 1)	TITLE	UUOCON - UUO HANDLER AND UUO+IO ROUTINES - V434
FILE 2)	TITLE	UUOCON - UUO HANDLER AND UUO+IO ROUTINES - V434

1)1		IFNDEF FTPDP8,<FTPDP8==1>
1)		ENTRY UUOCON	;ALWAYS LOAD UUOCON(IF LIB SEARCH)
****
2)1		ENTRY UUOCON	;ALWAYS LOAD UUOCON(IF LIB SEARCH)
***************
1)3		JRST USRXIT		;NO SKIP RETURN TO USER
1)	USRXT1:	IFN FTPDP8,<		;IF PDP-8'S IN THE SYSTEM
1)		MOVE TAC,(PDP)		;GET USER'S PC
1)		TLNE TAC,200		;IS BIT 10 SET ?
1)		JRST USRXT3		;YES, MUST NOT INCREMENT IT
1)	>	AOS (PDP)		;SKIP RETURN TO USER
1)	USRXIT:	MOVE ITEM,JOB		;CURRENT JOB NUMBER
****
2)3		JRST .+2		;NO SKIP RETURN TO USER
2)	USRXT1:	AOS (PDP)		;SKIP RETURN TO USER
2)	USRXIT:	MOVE ITEM,JOB		;CURRENT JOB NUMBER
***************
1)3	IFN FTPDP8,< EXTERN UUOTRA
1)		SKIPE UUOTRA		;IS RAPID RESCHEDULING REQUIRED ?
1)		JRST USRXT2		;YES, GO DO SO
1)	>
1)		TLNN TAC,STOPIO		;TRYING TO STOP IO?
1)		SKIPE TIMEF		;NO. HAS CLOCK TICKED WHILE IN MONITOR?
****
2)3		TLNN TAC,STOPIO	;TRYING TO STOP IO?
2)		SKIPE TIMEF		;NO. HAS CLOCK TICKED WHILE IN MONITOR?
***************
1)3	IFN FTPDP8,<  EXTERN AOSPC
1)	USRXT3:	MOVE ITEM,JOB		;GET CURRENT JOB NUMBER
1)		MOVSI TAC,AOSPC		;SET SKIP RETURN STATUS BIT
1)		IORM TAC,JBTSTS(ITEM)	;IN JOB STATUS WORD
1)		JRST USRXIT+1		;ALREADY HAVE JOB NUMBER
1)	>
1)	NOCHAN:NOCHAN:	CAMN PROG,17		;UUO FROM USER?
1)					;IF FROM EXEC, PROBABLY SAVEGET WHICH SETS USRCHN NEG. IN LH
****
2)3	NOCHAN:	CAMN PROG,17		;UUO FROM USER?
2)					;IF FROM EXEC, PROBABLY SAVEGET WHICH SETS USRCHN NEG. IN LH
***************

	********** CLKCSS **********

FILE 1)	TITLE	CLKCSS - SCHEDULING ALGORITHM FOR NON-SWAPPING SYSTEMS
FILE 2)	TITLE	CLKCSS - SCHEDULING ALGORITHM FOR NON-SWAPPING SYSTEMS

1)1	IFNDEF	FTPDP8,<FTPDP8==1>	;NORMALLY PDP-8'S ATTACHED TO SYSTEM
1)	INTERNAL NXTINI
****
2)1	INTERNAL NXTINI
***************
1)1	IFN FTPDP8,<
1)		EXTERN IRQUE,IRQU1,IRQU2,AOSPC
1)		SETZM IRQUE	;INITIALIZE HIGH PRIORITY REQUEST QUEUE
1)	>
1)		POPJ PDP,		;MAY CHOOSE TO SET REQUEST TO MORE
****
2)1		POPJ PDP,		;MAY CHOOSE TO SET REQUEST TO MORE
***************
1)2	IFN FTPDP8,<
1)		SKIPE IRQUE	;ANY HIGH PRIORITY REQUESTS TO PROCESS ?
1)		JRST HP0	;YES, GO AND TRY TO FIND A RUNNABLE ONE
1)	NXT9:
1)	>
1)		MOVEI Q,MAXQ		;HIGHEST PRIORITY QUEUE SCANNED FIRST
****
2)2		MOVEI Q,MAXQ		;HIGHEST PRIORITY QUEUE SCANNED FIRST
***************
1)2		TRZ T,RUNMSK+CMWB+AOSPC	;MASK OUT JOB STATUS BITS WHICH DO NOT MATTER
1)		CAIN T,RUNABLE(Q1)	;ADD IN QUEUE NO. IN PROPER POSITION
****
2)2		TRZ T,RUNMSK+CMWB	;MASK OUT JOB STATUS BITS WHICH DO NOT MATTER
2)		CAIN T,RUNABLE(Q1)	;ADD IN QUEUE NO. IN PROPER POSITION
***************
1)3	IFN FTPDP8,<
1)	EXTERN PION,PIOFF,CPOPJ1,TIMSKP,TRPFLG
1)	HP0:	SETZ Q,			;H. P. REQUEST QUEUE INDEX
1)	HP1:	SKIPN ITEM,IRQU1(Q)	;ANY MORE REQUESTS?
1)		JRST NXT9		;NO, SCHEDULE NORMALLY
1)		HLRZ T,JBTSTS(ITEM)	;YES, GET JOB STATUS FOR THIS REQUEST
1)		TRZ T,RUNMSK!CMWB+AOSPC	;CLEAR BITS THAT DON'T MATTER
1)		CAIE T,RUNABLE		;IS JOB RUNNABLE ?
1)		AOJA Q,HP1		;NO, CONTINUE HP REQUEST SCAN
1)	HP2:	SKIPE T,IRQU2(Q)	;YES,ANY REQ.S TO BE MOVED UP IN QUEUE ?
1)		JRST HP4		;YES, THIS ONE MUST BE MOVED UP
1)		CONO PI,PIOFF		;NO, TRY AGAIN AT TOP LEVEL
1)		SKIPE T,IRQU2(Q)	;STILL NO MORE ?
1)		JRST HP3		;ANOTHER ONE ARRIVED
1)		SOS IRQUE		;OK, DECREMENT POINTER
1)		CONO PI, PION		;RETURN TO SCHEDULER LEVEL
1)		HLRZM ITEM,TRPFLG	;SET UP TRAP REQUEST
1)		HRRZS ITEM		;CLEAR ALL BUT JOB NUMBER
1)		MOVEM ITEM,TIMSKP	;SET TO IGNORE ONE CLOCK TICK
1)		JRST CPOPJ1		;SKIP RETURN TO CLOCK
1)	HP3:	CONO PI,PION		;DON'T PRECLUDE INTERRUPTS TOO LONG
1)	HP4:	MOVEM T,IRQU1(Q)	;MOVE REQUEST UP ONE STEP
1)		SETZM IRQU2(Q)		;CLEAR IT'S OLD POSITION
1)		AOJA Q,HP2		;CONTINUE PUSHING UP QUEUE
FILE 1)	TITLE	CLKCSS - SCHEDULING ALGORITHM FOR NON-SWAPPING SYSTEMS
FILE 2)	TITLE	CLKCSS - SCHEDULING ALGORITHM FOR NON-SWAPPING SYSTEMS

1)	>
1)	NXT8:
****
2)3	NXT8:
***************

	********** CLOCK1 **********

FILE 1)	TITLE	CLOCK1 - CLOCK, CONTEXT SWITCHING, AND JOB STARTUP AND STOP ROUTINES - V412
FILE 2)	TITLE	CLOCK1 - CLOCK, CONTEXT SWITCHING, AND JOB STARTUP AND STOP ROUTINES - V412

1)1	IFNDEF FTPDP8,<FTPDP8==1>	;NORMALLY PDP-8'S ATTACHED TO SYSTEM
1)	INTERNAL FTCHECK,FTMONP
****
2)1	INTERNAL FTCHECK,FTMONP
***************
1)9	IFN FTPDP8,<
1)	EXTERN TIMSKP,TRPFLG,UUOTRA,DEVIPC,DEVTRP
1)		SKIPN SCHEDF		;NEVER OVERRIDE FORCED RESCHEDULE
1)		SKIPN ITEM,TIMSKP	;DON'T SCHED THIS CLOCK-TICK,FORCE CURRENT JOB
1)	>
1)	CIP6:	PUSHJ PDP,NXTJOB	;CALL SCHEDULER
1)	IFN FTPDP8,<
1)		SETZM TIMSKP	;SCHEDULER SKIPS THIS INSTRUCTION ON HIGH PRIORITY RETURN
1)		SETZM UUOTRA	;ALWAYS CLEAR UUO EXIT RESCHEDULE FLAG
1)	>
1)		SETZM CLKFLG		;CLEAR CLK INTERRUPT FLAG
****
2)9	CIP6:	PUSHJ PDP,NXTJOB	;CALL SCHEDULER
2)		SETZM CLKFLG		;CLEAR CLK INTERRUPT FLAG
***************
1)11	IFN FTPDP8,<
1)		SKIPN DEVDAT,TRPFLG	;DOES JOB NEED TO BE TRAPPED
1)		JRST CIP9		;NO, CONTINUE
1)		MOVE T,USRPC		;YES, GET IT'S CURRENT PC
1)		MOVE T1,DEVTRP(DEVDAT)	;ALSO GET TRAP PC
1)		TLNN T,USRMOD		;IS JOB GOING BACK INTO USER MODE ?
1)		SKIPA T,JOBPD1(JA)	;NO, GET IT'S USER MODE PC
1)		MOVEM T1,USRPC		;YES, TRAP IMMEDIATELY
1)		MOVEM T1,JOBPD1(JA)	;TRAP LATER UPON RETURN FROM SYSTEM
1)			;IF PREVIOUS INSTRUCTION EXECUTED, THIS ONE DOESN'T MATTER
1)		MOVEM T,DEVIPC(DEVDAT)	;SAVE USER'S INTERRUPT PC IN DATA BLOCK
1)		SETZM TRPFLG		;CLEAR TRAP REQUEST FLAG
1)	CIP9:
1)	>
1)		MOVSI 17,JOBDAC(JA)	;RESTORE DUMP ACS
****
2)11		MOVSI 17,JOBDAC(JA)	;RESTORE DUMP ACS
***************

	********** DLSINT **********

FILE 1)	TITLE	DLSINT - INT. SERV. FOR DLS (DATA LINE SCANNER DC10)
FILE 2)	TITLE	DLSINT - INT. SERV. FOR DLS (DATA LINE SCANNER DC10)

1)4	IFNDEF FTPDP8,<FTPDP8==1>	;NORMALLY PDP-8'S ATTACHED TO SYSTEM
1)	SCNTYP:
1)	DLSTYP:
1)	IFN FTPDP8,<	EXTERNAL ECMTYP,ECONLN
1)		CAIL	LINE,ECONLN	;IS THIS AN EIGHT TTY
1)		JRST	ECMTYP		;YES>
1)		HRL	CHREC,LINE	;SET UP LINE NUMBER IN CHREC
1)		TLO	CHREC,USDRLN		;USE THAT AS DIRECTED LINE#
****
2)4	SCNTYP:
2)	DLSTYP:	HRL	CHREC,LINE	;SET UP LINE NUMBER IN CHREC
2)		TLO	CHREC,USDRLN		;USE THAT AS DIRECTED LINE#
***************