.TITLE GETNAM .IDENT "V1.0" .NLIST BEX,ME,CND .ENABL LC ; This subroutine returns our current user name, ; and UIC in ASCII ; Arguments are : ; ; 2(R5) -- Buffer to store the ASCII user name ; 4(R5) -- 9-byte buffer to store the ASCII UIC GETNM:: CALL $SAVAL ; SAVE MY REGISTERS MOV .CRTSK,R0 ; GET ATL ADDRESS AND SAVE IN R0 CALL .UJNAD ; GET UJN ADDRESS IN R0 MOV #6,R1 ; PUT INDEX IN R1 (#OF CHAR ) MOV 2(R5),R2 ; SET OUR BUFFER POINTER MOV J.TA(R0),R3 ; GET UTN ADDRESS IN R3 ADD #I.UN,R3 ; SET POINTER TO USER NAME 10$: MOV (R3)+,(R2)+ ; GET OUR USER NAME SOB R1,10$ ; LOOP UNTIL THRU MOV R0,R3 ; Save our UJN pointer MOVB J.GC(R0),R1 ; Get the group code MOV 4(R5),R0 ; Point to where it's going MOVB #'[,(R0)+ ; Move the [ into position CLR R2 ; Zero suppress CALL $CBOMG ; Convert it to ASCII MOVB #54,(R0)+ ; Add a comma MOVB J.PC(R3),R1 ; Get the programmer code CALL $CBOMG ; And convert it to ASCII MOVB #'],(R0)+ ; And add the end bracket RETURN .END