.TITLE ST2NM ;============================================================== ; ST2NM - STRING TO ARRAY CONVERSION ROUTINE ; ; WILL CONVERT A 64 CHARACTER STRING TO A 64 WORD AREA ; USUALLY SET UP AS A 64 ITEM INTEGER ARRAY, ESSENTIALLY ; DOING A CHANGE BASIC CALL ; ;============================================================== ; ; This software is furnished under a license and may ; be used and copied only in accordance with the ; terms of such license and with the inclusion of ; the above copyright notice. This software or any ; other copies thereof may not be provided or other- ; wise made available to any other person. No title ; to and ownership of the software is hereby trans- ; ferred. No SOURCE code can be copied. ; ; The information in this software is subject to ; change without notice and should not be construed ; as a commitment by the author. ; ;============================================================== .PSECT ST2NM,I,RO .IDENT /PJH016/ ; ST2NM:: MOV 2(R5),R1 ;ADDR OF INPUT STRING MOV 4(R5),R2 ;ADDR OF OUTPUT ARRAY ADD #2.,R2 ;SKIP THE ZERO POSTION OF ARRAY MOV #64.,R0 ;NUMBER OF BYTES TO MOVE ; MLOOP: CLR R3 ;MAKE SURE WORK ARRAY IS CLEAR MOVB (R1)+,R3 ;MOVE THE BYTE OF DATA MOV R3,(R2)+ ;AND PUT IN ITS PLACE AS A WORD SOB R0,MLOOP ;DO AGAIN ; RTS PC ;WE FINISHED ; ;----------------------------------------------------------------- ; .PSECT NM2ST,I,RO .IDENT /PJH016/ ; ;CONVERT ARRAY TO STRING ; NM2ST:: MOV 2(R5),R1 ;ADDR OF OUTPUT STRING MOV 4(R5),R2 ;ADDR OF INPUT ARRAY ADD #2.,R2 ;SKIP THE ZERO POSTION OF ARRAY MOV #64.,R0 ;NUMBER OF BYTES TO MOVE ; CLOOP: MOV (R2)+,R3 ;GET THE DATA MOVB R3,(R1)+ ;PUT IT BACK SOB R0,CLOOP ;DO AGAIN ; RTS PC ;WE FINISHED ; .END