File SAMPLE.PA (PAL assembler source file)

Directory of image this file is from
This file as a plain text file

/ QUALITY CONTROL SAMPLE SCHEDULER		18-MAY-90

/
/
/EDIT HISTORY:
/
/22-NOV-78	(LHN)
/	1)  ADDED TEST FOR NEXT ROLL DATA AT EOR	[N1]
/
/26-APR-90	(LHN)
/	1)  CHANGED SAMPLING METHOD FROM EITHER A FIXED
/	    DISTANCE PATTERN OR A RANDOM PATTERN TO A
/	    AFTER "EVERY N BOX" PATTERN.
/


/
/%R	TAKE IN ROLL SAMPLES AT INTERVAL PATCON
/	SELECT REJECT IF IT OCCURS WITHIN
/	SMPCON CHOPS OF PATTERN SAMPLE CHOP.
/
/
/
/
/
/  NOTE:	MOST OF THIS TASK IS EXECUTED WITH
/		THE DATA FIELD SET TO 10, TO ACCESS
/		PRODUCT DATA IN THE DEFECT MEMORY
/		TABLE.
/










	TASK=	SAMPLE
	CUR=	SAMPLFLD
	INIWT=	0
	VERS=	3







	FIELD SAMPLFLD%10
	*SAMPLLOC

/ / / SHEET TYPE CODE BITS / / / THE CODE BITS USED BY MAST FOR MARKING THE TYPE / OF SHEET ARE THE FOLLOWING: / / / DATA MEANING / BIT / / 0 TRAY EJECT CONTROL / 1 SPLICE SAMPLE / 2 IN-ROLL SPLICE SAMPLE / / 3 MANUAL REJECT / 4 AUTOMATIC REJECT / 5 BOX SAMPLE / / 6 START ROLL SAMPLE / 7 END ROLL SAMPLE / 8 SPLICE ON THIS SHEET / / 9 DEFECT FROM CHANNEL 1 / 10 DEFECT FROM CHANNEL 2 / 11 DEFECT FROM CHANNEL 3 / /
/ START, CLB CAL SUSPND /GO TO SLEEP 'TIL NEEDED CLB CDF 10 TAD I (SROFLG) /ARE WE IN STACKER RUN OUT OR TAD I (CTHOLD) /COUNT/HOLD ? SZA CLA JMP PATXIT /YES, JUST EXIT. TAD STROLL /FLAG SET TO FORCE START OF ROLL SZA CLA / SAMPLING. JMS SORSET /YES, TO DO IT. TAD SORSFG /IS THE START OF ROLL SAMPLING FLAG SZA CLA / SET ? JMS SORSMP /DO START OF ROLL SAMPLING TAD ENROLL /END OF ROLL SAMPLING FLAG SET ? SZA CLA JMS EORSMP /YES, GO DO IT. CLB IAC TAD PTRCH3 /POINTS AT CHANNEL 3 PLUS 1 SHEET TAD I (MEMPTR) /CURRENT POSITION IN TABLE AND (0377) /KEEP WITHIN THE TABLE TAD (MEMTBL) DCA PATGA /FOR INDIRECT TAD I PATGA /HAVE MEMORY WORD FROM CHANNEL 3 AND (0010) /IS IT A SPLICE? SZA CLA JMS SPLCSM /SET UP FOR SPLICE SAMPLING
/ IFNDEF EPLTEST < DBRI52 /HAS THE UNWIND SWITCHED OVER ? AND (1000) > IFDEF EPLTEST < DBRI50 AND (0100) > CIA TAD UNWDBF SNA CLA JMP PAT1 /NO, RETURN. IFNDEF EPLTEST < DBRI52 /YES, RESET THE UNWIND SWITCHOVER AND (1000) /FLAG FROM THE INPUT REGISTER. > IFDEF EPLTEST < DBRI50 AND (0100) > DCA UNWDBF JMS EORSET /GO FIRE UP END OF ROLL SAMPLES
/ / / CHECK IF ITS TIME FOR BOX SAMPLES / / PAT1, CLB CMA TAD I (MEMPTR) /RESET THE POINTER TO THE NEXT SHEET AND (0377) TAD (MEMTBL) DCA PATGA / TO BE CHOPPED. CDF CUR TAD I (NEWBOX) /IS THIS THE LAST SHEET IN THE CDF 10 / BOX ? SNA CLA JMP PAT2 /NO, GO ON ISZ PATINT /IS IT TIME FOR A BOX SAMPLE ? JMP PATXIT /NO, GO ON ISZ SMPINT /YES, SET BOX SAMPLE FLAG TAD PATCON /RESET THE BOXES BETWEEN SAMPLES CIA / COUNTER DCA PATINT PAT2, TAD SMPINT /ARE WE LOOKING FOR A SAMPLE ? SNA CLA JMP PATXIT /NO, EXIT TAD I PATGA /CHOP CONTROL WORD AS IS AND (3617) /LOOK AT VARIOUS REJECT BITS SZA CLA /SKIP IF MARKED AS A GOOD SHEET JMP PATXIT /SOME SORT OF A REJECT, RETURN JMS F2MPTR /GO MARK THE SHEET AS BOX SAMPLE. 100 /BOX SAMPLE BITS DCA SMPINT /CLEAR SO WE WON'T TAKE ANOTHER PATXIT, CLB CDF CUR JMP START /AND RETURN
/ / /%R MARK A SHEET AS A SAMPLE OR REJECT / / F2MPTR, 0 TAD PATGA AND (0377) TAD (MEMTBL) DCA PATGA CDF CUR TAD I F2MPTR /GET THE BITS WE WANT TO SET. ISZ F2MPTR MQL CDF 10 TAD I PATGA /"OR" IT INTO THE DEFECT MQA /MEMORY TABLE. DCA I PATGA JMP I F2MPTR PAGE
/ / /%R SET FLAGS AND PARAMETERS FOR START OF ROLL SAMPLING / / SORSET, CLB TAD SORSPF /START OF ROLL SPLICE FOUND ALREADY? SZA CLA /JUST ANOTHER SPLICE IF NON-ZERO JMP I SORSET /DON'T NEED TO REINITIALIZE ISZ SORSPF /SET START OF ROLL SPLICE FLAG TAD MEORRJ /SET UP COUNTER FOR START OF ROLL DCA CNTREJ / REJECTS TAD MEORSM /SET UP COUNTER FOR START OF ROLL DCA CNTSAM / SAMPLES TAD STROLL /IS THE FORCE START ROLL FLAG SET ? SZA CLA JMP SORX1 CLB IAC /FIRE THE END OF ROLL SUMMARY DCA EORSFG / FLAG. SORX1, DCA STROLL /CLEAR FORCED START ROLL / SAMPLING FLAG. CLB IAC DCA SORSFG /MAKE SURE THE START ROLL / SAMPLING FLAG IS SET. DCA EORTRP /[N1] MAKE SURE EOR DATA TRAP FLAG / IS NOW CLEAR. DCA ENROLL /CLEAR END OF ROLL SAMPLING FLAG JMP I SORSET
/ / /%R TAKE START OF ROLL SAMPLES / / SORSMP, 0 CLB CMA TAD I (MEMPTR) /CURRENT SHEET AND (0377) /TRAP WITHIN TABLE TAD (MEMTBL) DCA PATGA /LOCAL INDIRECT CELL TAD SORSPF /HAVE WE SEEN A SPLICE ? SZA CLA JMP SOR1 /YES, GO ON TAD I PATGA /LOOK FOR THE SPLICE AND (0010) SZA CLA JMS SORSET /SHOW SPLICE FOUND JMP I SORSMP /NOT YET, TRY THE NEXT SHEET SOR1, TAD CNTREJ /WANT ANOTHER REJECT SHEET ? SMA CLA JMP SOR2 /NO, GO ON. JMS F2MPTR /YES, GO MARK IT. 200 /AUTOMATIC REJECT BIT ISZ CNTREJ NOP /WE NEED THIS ONE !!!! JMP I SORSMP SOR2, JMS F2MPTR /GO MARK ANOTHER SAMPLE SHEET 40 /START ROLL SAMPLE BIT ISZ CNTSAM JMP I SORSMP DCA SORSFG /KILL START OF ROLL FLAG DCA SORSPF /START OF ROLL SPLICE FLAG CLEARED TAD PATCON /RESET THE BOXES BETWEEN SAMPLES CIA / COUNTER DCA PATINT JMP I SORSMP
/ / / SET FLAGS AND PARAMETERS FOR END OF ROLL SAMPLING / / EORSET, 0 ISZ ENROLL /SET END OF ROLL SAMPLING FLAG TAD MEORLN /SET UP COUNTER TO DELAY UNTIL DCA CNTREJ / TIME FOR EOR SAMPLES TAD MEORSM /SET UP COUNTER FOR END OF ROLL DCA CNTSAM / SAMPLES DCA SORSPF /CLEAR START ROLL SAMPLE FLAG ISZ SORSFG /SET TO DO START OF ROLL CLB IAC /FORCE A VISIT TO "EORNID" JMS EORSMP /GO MARK LOOK AT FIRST SHEET JMP I EORSET / / /%R TAKE END OF ROLL SAMPLES / / EORSMP, 0 TAD EORTRP /IS THE NEXT ROLL DATA TRAP SET ? SZA CLA JMS EORNID /[N1] CHECK FOR NEW ROLL DATA CLB CMA /RESET POINTER TO THE NEXT SHEET TAD I (MEMPTR) / TO BE CHOPPED AND (0377) TAD (MEMTBL) DCA PATGA TAD CNTREJ /STILL WAITING FOR FIRST SAMPLE? SMA CLA JMP EORS1 /NO, GO ON ISZ CNTREJ /YES, COUNT THIS SHEET NOP /THIS IS NEEDED ! JMP I EORSMP /RETURN FOR NOW EORS1, TAD CNTSAM /TAKE A SAMPLE? SMA CLA JMP EORS2 /NO, ALL DONE, DO REJECTS JMS F2MPTR /MARK SHEET AS END OF ROLL SAMPLE 20 ISZ CNTSAM /COUNT THE SHEET NOP /THIS IS NEEDED !! JMP I EORSMP /EXIT FOR NOW EORS2, JMS F2MPTR /REJECT THE REST OF THE ROLL 200 JMP I EORSMP /OUR JOB IS DONE PAGE
/ / / IN ROLL SPLICE SAMPLING / / SPLCSM, 0 CLB TAD ENROLL /ARE WE IN EOR SAMPLING ? SNA CLA JMP SPLC3 /NO, GO ON CDF 30 TAD I (NCHOPC) /YES, SEE IF A NEW CHOP LENGTH CIA / WAS ENTERED, OR IF IT MATCHED SZA / THE CURRENT CHOP LENGTH. TAD I (CHOPC) SZA CLA JMP SPLC1 /NEW CHOP LENGTH, GO ON. TAD I (NSLITC) /NOW CHECK FOR A NEW SLIT CIA /WIDTH. SNA JMP SPLC2 /NO NEW SLIT WIDTH, GO ON. TAD I (SLITC) SNA CLA JMP SPLC2 /SAVE WIDTH AS BEFORE,GO ON. SPLC1, TAD (200) /NO, STOP WITH THE SPLICE DBSO54 /IN THE INSPECTOR SPLC2, CLB CDF 10 JMP I SPLCSM /RETURN NOW.
/ SPLC3, TAD PATGA /SAVE THE ADDRESS OF THE SPLICE DCA SPLCB TAD MINRRJ /SET UP LOOP COUNTER TO MARK DCA SPLCA / LEADING SPLICE REJECTS SPLC4, CLA IAC JMS F2MPTR /INCREMENT, BUT WITHIN MEMTBL 200 /AUTOMATIC REJECT BIT ISZ SPLCA /DONE ? JMP SPLC4 /NO, TAKE ANOTHER TAD MINRSM /SET UP LOOP COUNTER TO MARK DCA SPLCA / LEADING SPLICE SAMPLES SPLC5, CLA IAC /TAKE NEXT SAMPLE JMS F2MPTR /ADJUST FOR MEMTBL LIMITS 1000 /IN-ROLL SPLICE SAMPLE BIT ISZ SPLCA /DONE? JMP SPLC5 /NO. TAKE ANOTHER REJECT TAD SPLCB /RESET POINTER TO THE SPLICE DCA PATGA JMS F2MPTR /CHOP AT CHANNEL 3 + 2 CHOPS 2000 /THIS IS THE IN-ROLL SPLICE TAD MINRRJ /SET UP LOOP COUNTER TO MARK THE DCA SPLCA / TRAILING SPLICE REJECTS SPLC6, CLB CMA JMS F2MPTR 200 /AUTOMATIC REJECT BIT ISZ SPLCA /DONE ? JMP SPLC6 /NO, DO ANOTHER TAD MINRSM /NOW A LOOP COUNTER TO MARK THE DCA SPLCA / TRAILING SPLICE SAMPLES SPLC7, CLB CMA JMS F2MPTR 1000 /IN-ROLL SPLICE SAMPLE BIT ISZ SPLCA /DONE ? JMP SPLC7 /NO, DO ANOTHER CLB IAC /SET THE FLAG TO SWAP DCA I (SWPREJ) /THE REJECT TRAYS JMP I SPLCSM /ALL DONE, RETURN SPLCA, 0 SPLCB, 0
/ / /[N1] CHECK FOR NEXT ROLL DATA AT EOR / / EORNID, 0 CLB CDF 30 TAD I (NEWRNF) /HAS THE NEXT ROLL NUMBER BEEN SZA CLA / ENTERED ? JMP EORN1 /YES, CLEAN UP AND EXIT. CAL /NO, FIRST STOP THIS THING.. SEND INLOCK NIDMG1 CAL /THEN TELL THE OPERATOR WHAT WE SEND / NEED. CRTMSG NIDMG2 CLB IAC /SET (OR) EORN1, DCA EORTRP /CLEAR THE EOR DATA TRAP FLAG. CDF 10 /(EVERYONE ELSE LOOKS AT FIELD 1.) JMP I EORNID /RETURN. NIDMG1, ZBLOCK 3 /OPEN "MAST INTERLOCK". 2000 NIDMG2, ZBLOCK 3 /DISPLAY "ENTER ROLL DATA" MOPM08 PAGE NOPUNCH XLIST 1



Feel free to contact me, David Gesswein djg@pdp8online.com with any questions, comments on the web site, or if you have related equipment, documentation, software etc. you are willing to part with.  I am interested in anything PDP-8 related, computers, peripherals used with them, DEC or third party, or documentation. 

PDP-8 Home Page   PDP-8 Site Map   PDP-8 Site Search