.TITLE CIO Console I/O routines .IDENT /121982/ ;5-9-81 DJ Travis ; .MCALL .TTINR,.TTYOUT ; ;Routine to see if there is a char ready on the console. If the ; char is ready, return true. If the char is not ready, return false. ; CINS:: .TTINR ;Input char ready? BCS 2$ ;Not ready MOVB R0,CHAR ;Inputted char to here MOV #1,R0 ;Set true 1$: RETURN 2$: CLR R0 ;Set false RETURN ; ;Routine to get the byte from the console. ; CIND:: MOV CHAR,R0 ;Get the char RETURN ; ;Routine to output a byte to the console. ; PUTCHAR:: ;This is the PUTCHAR should be done! COUT:: .TTYOUT 2(SP) ;Output the char to the console RETURN ; ;Routine to set the console to special, single char mode. ; CSSP:: BIS #50100,@#44 ;Set tt lower case, special, & FB no-wait RETURN ; ;Routine to unset the console special mode. ; CUSP:: BIC #10100,@#44 ;Unset tt special mode RETURN ; CHAR: 0 ; .LIST TTM ;So symbol table lists in 80 col. .END