[Simh] Speaking of cards

Timothe Litt litt at ieee.org
Mon May 27 11:24:43 EDT 2013


Well, TOPS-10 uses this, and our customers were happy.  Of course, 029 
was much more common in the PDP-10 era.

;THE CHARACTER TRANSLATION TABLES:
	$HIGH
CRCVPT::XWD	350700+T2,CRCVTB
	XWD	260700+T2,CRCVTB
	XWD	170700+T2,CRCVTB
	XWD	100700+T2,CRCVTB

;CODE CONVERSION FOR THE 029 KEYPUNCH
;THE FOLLOWING EQUIVALENCES ARE ARTIFICIALLY DEFINED

;029 KEYTOP	;ASCII 35	;ASCII 37
;CENT		[		[
;0-8-2		]		]
;VERT BAR	^		HAT = L.C. VERT BAR
;UNDERBAR	_		UNDERBAR
;NEGATION	\		TILDE = L.C. NEGATION

	;CHARACTERS	;ZONE/DIGITS
CRCVTB:	ASCII	/ 123/		;N/N-3
	ASCII	.0/ST.		;0/N-3
	ASCII	/-JKL/		;11/N-3
	ASCII	/HI[./		;12,8/N-3
	ASCII	/&ABC/		;12/N-3
	ASCII	/QR]$/		;11,8/N-3
	ASCII	/YZ\,/		;0,8/N-3
	ASCII	/89:#/		;8/N-3
	ASCII	/4567/		;N/4-7
	ASCII	/UVWX/		;0/4-7
	ASCII	/MNOP/		;11/4-7
	ASCII	/<(+!/		;12,8/4-7
	ASCII	/DEFG/		;12/4-7
	ASCII	/*);^/		;11,8/4-7
	ASCII	/%_>?/		;0,8/4-7
	ASCII	/@'="/		;8/4-7

;CODE FOR THE 026 KEYPUNCH A LA H HYMAN

	ASCII	/ 123/		;N/N-3
	ASCII	.0/ST.		;0/N-3
	ASCII	/-JKL/		;11/N-3
	ASCII	/HI?./		;12,8/N-3
	ASCII	/+ABC/		;12/N-3
	ASCII	/QR:$/		;11,8/N-3
	ASCII	/YZ;,/		;0,8/N-3
	ASCII	/89_=/		;8/N-3
	ASCII	/4567/		;N/4-7
	ASCII	/UVWX/		;0/4-7
	ASCII	/MNOP/		;11/4-7
	ASCII	/)]<!/		;12,8/4-7
	ASCII	/DEFG/		;12/4-7
	ASCII	/*[>&/		;11,8/4-7
	ASCII	/("#%/		;0,8/4-7
	ASCII	/@^'\/		;8/4-7


;HERE IF DATA IS IN ASCII OR BINARY MODE
NOTIMG:	ILDB	U,T3		;GET COLUMN 1
	MOVE	T1,U		;SAVE HERE
	TRZ	U,770000	;JUST COLUMN DATA
	CAIE	U,CODEOF+NEWEOF	;IS IT AN EOF CARD?
	CAIN	U,CODEOF	;OR THIS TYPE?
	  PJRST	EOFCRD		;YES--SET FLAGS
	CAIN	U,NEWEOF	;IS IT NEW TYPE EOF?
	  PJRST	EOFCRD		;YES--SET FLAGS
	TRNE	S,14		;BINARY MODE?
	  PJRST	CDRBIN		;YES--GO PROCESS IT

;HERE TO PROCESS AN ASCII CARD
	CAIN	U,COD026	;026 CARD?
	  PJRST	SET026		;YES--SET MODE
	CAIN	U,COD029	;029 CARD?
	  PJRST	SET029		;YES--SET MODE
	SKIPA	U,T1		;RESTORE COLUMN 1 AND SKIP NEXT
ASCLOP:	ILDB	U,T3		;GET NEXT COLUMN
	TRNE	U,100000	;MULTI-PUNCHED COLUMN?
	JRST	[MOVEI U,"\"	;YES--GET INVALID CHARACTER
		 JRST ASCLO1]	; AND STORE THAT
	SETZB	T1,T2
	CAIN	U,5000		;CONVERT "["
	MOVEI	U,24202		; TO INTERNAL FORM
	CAIN	U,3000		;CONVERT "]"
	MOVEI	U,22202		; TO INTERNAL FORM
	LDB	T2,[POINT 3,U,26] ;GET ZONES PLUS LOW ENCODED BIT
	TRNE	U,3		;AN 8 OR 9 PUNCH?
	TRC	T2,7		;YES--ENCODE THAT
	TRZE	U,40000		;COPY THIS BIT
	TRO	T2,10		; TO HERE
	TRNE	U,1		;THIS BIT ON
	TRO	U,10000		; MEANS THIS BIT SHOULD BE ON
	LSH	U,-^D12		;POSITION REMAINING CODE BITS
	TLNE	S,CR026		;026 MODE?
	TRO	T2,20		;YES--BUMP T2 TO 026 TABLE
	LDB	U,CRCVPT##(U)	;PICK UP ASCII CHAR FROM TABLE
ASCLO1:	IDPB	U,DEVPTR(F)	;PUT INTO USER BUFFER
	SOJG	T4,ASCLOP	;LOOP THRU CARD
	MOVEI	T1,15		;INSERT <CR>
	IDPB	T1,DEVPTR(F)
	MOVEI	T1,12		;INSERT <LF>
	IDPB	T1,DEVPTR(F)
	PJRST	CDRDON		;FINISH UP



This communication may not represent my employer's views,
if any, on the matters discussed.

On 27-May-13 10:58, Tom Morris wrote:
> p.s.  Love this quote from the card format documentation page
>
>
> On Mon, May 27, 2013 at 10:14 AM, Timothe Litt <litt at ieee.org 
> <mailto:litt at ieee.org>> wrote:
>
>
>     http://homepage.cs.uiowa.edu/~jones/cards/codes.html
>     <http://homepage.cs.uiowa.edu/%7Ejones/cards/codes.html>
>     <http://homepage.cs.uiowa.edu/%7Ejones/cards/codes.html> has a
>     fair bit of documentation on card formats, including what simh uses.
>
>
>
> "The DEC 026 code is a workable mapping of the IBM 026 FORTRAN 
> character set to ASCII. Unfortunately, it appears to have nothing in 
> common with other extensions of the same character set. Given the 
> frequency of typos in DEC's handbooks, it is possible that the problem 
> is with the handbook from which this material was derived."

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.trailing-edge.com/pipermail/simh/attachments/20130527/98762507/attachment-0002.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5159 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mailman.trailing-edge.com/pipermail/simh/attachments/20130527/98762507/attachment-0002.bin>


More information about the Simh mailing list