Trailing-Edge
-
PDP-10 Archives
-
decuslib10-12
-
43,50547/pltlib/v12a/unimpl/pltcal.mac
There is 1 other file named pltcal.mac in the archive. Click here to see a list.
SUBTTL CAL driver -- CALCOMP expanded output, DEC compatible
; This is the routine which DEC supplies with FORLIB. It outputs
; one 6-bit byte per increment. CSM has rejected this routine because
; of the size of the output file, which often exceeded the user's
; FCFS disk quota under MPB (back in the days of RP02s).
;
; The bits match the 6 signals on the XY10.
;
; -X
;Y.NEG== 1 ;Move carriage right (supply roller)
;Y.POS== 2 ;Move carriage left
;X.POS== 4 ;Roll drum forward < +Y carriage -Y >
;X.NEG== 10 ;Roll drum back
;PEN.DN==20 ;Lower the pen (takeup roller)
;PEN.UP==40 ;Raise the pen -X
PRINTX %PLOT - PLTCAL not fully implemented
PPDATA (CAL) ;Expand data area
CALNAM: DEC 10 ;XY-10
ASCII /XY10/
ASCII /XY-10/
ASCII /CALCO/ ;Calcomp plotter
ASCII /DEC/ ;DEC standard software
ASCII /EXPAN/ ;Expanded spooler format
;** This code copied from the DEC supplied FORPLT module
HELLO (PLOT) ;ENTRY TO PLOT
MOVEM 17,SV17
MOVEI 17,ARGS-1
PUSH 17,@0(Q) ;SVX
PUSH 17,@1(Q) ;SVY
PUSH 17,@2(Q) ;SVPEN
MOVEI 17,SV0
BLT 17,SV0+16 ;SAVE AC'S
MOVE P,PPDP ;PLOT PUSHDOWN POINTER
PUSHJ P,PLOT. ;DO WORK
MOVSI 17,SV0
BLT 17,17
GOODBY (3) ;RETURN TO CALLER
;**; [555] CHANGE @ PLT1 CLRH 14-JUN-76
PLT2: PUSH P,1 ;[555] GET REGISTER
MOVE 1,PCHN ;[555] GET CHANNEL NUMBER
TLO 1,(OUTPUT) ;[555] MAKE OUTPUT UUO
XCT 1 ;[555] DO OUTPUT
POP P,1 ;[555] RESTORE REGISTER
PLT1: SOSGE POB+2 ;[555] ROOM IN BUFFER ?
JRST PLT2 ;[555] NO, SO OUTPUT IT
IDPB DAT,POB+1
POPJ P,0
ENTRY PLOT.
PLOT.:
PENCK: MOVM TX,SVPEN
CAIG TX,1
JRST PENOK
SUBI TX,3
CAMN TX,PEN
JRST PENOK
MOVEI DAT,PENUP
SKIPGE TX
MOVEI DAT,PENDWN
PUSHJ P,PLT1
MOVEM TX,PEN
PENOK: MOVE TX,SVX
FMPR TX,STPSIZ
FADR TX,[DEC 0.5]
SKIPGE SVX
FSBR TX,[DEC 1.0]
FUNCT INT.,<TX> ; [516]
MOVEM 0,ISX
MOVE TX,0
MOVE TY,SVY
FMPR TY,STPSIZ
FADR TY,[DEC 0.5]
SKIPGE SVY
FSBR TY,[DEC 1.0]
FUNCT INT.,<TY> ; [516]
MOVEM 0,ISY
MOVE TY,0
SUB TX,IX
MOVEI TDX,MVLFT
SKIPL TX
MOVEI TDX,MVRT
SUB TY,IY
MOVEI TDY,MVDWN
SKIPL TY
MOVEI TDY,MVUP
MOVMS TX
MOVMS TY
CAMG TY,TX
JRST NOSWAP
EXCH TX,TY
EXCH TDX,TDY
NOSWAP: JUMPE TX,ENDOU1 ;NO MOTION
JUMPE TY,NORM
MOVEI SC,0
NY: TLNE TY,200000
JRST NX
LSH TY,1
TRO TY,1
AOJA SC,NY
NX: SUBI SC,^D34
MKSC: IDIV TY,TX
MOVNS SC
LSH TY,0(SC)
NORM: MOVEM TY,STEP
MOVEI TY,0
IOR TDY,TDX
INLOOP: ADD TY,STEP
MOVE DAT,TDX
TLZE TY,200000
MOVE DAT,TDY
PUSHJ P,PLT1
SOJG TX,INLOOP
MOVE TY,ISX
MOVEM TY,IX
MOVE TY,SVX
MOVEM TY,X
MOVE TY,ISY
MOVEM TY,IY
MOVE TY,SVY
MOVEM TY,Y
ENDOU1: SKIPL SVPEN
JRST ENDOUT
;**; [555] CHANGE @ ENDOU1 + 2 CLRH 14-JUN-76
PUSH P,1 ;[555] SAVE 1
MOVE 1,PCHN ;[555] GET CHANNEL
TLO 1,(OUTPUT) ;[555] MAKE OUTPUT
XCT 1 ;[555] DO OUTPUT
POP P,1 ;[555] RESTORE 1
SETZM X
SETZM Y
SETZM IX
SETZM IY
ENDOUT: SETZM SVPEN
POPJ P,0
LITCAL: LIT ;End of PLTCAL.MAC