CH12PR3.LST:

100 REM MULTIPLE INPUTS
110 PRINT "MONITORING SENSORS"
120 PRINT :PRINT " PRESS X TO EXIT"
130 REM SET DATA DIRECTION REGISTER FOR OUTPUT
140 POKE 54018,48
150 POKE 54016,7
160 POKE 54018,52
170 REM CYCLE THROUGH OUTPUT COMBINATION
180 FOR I=0 TO 7
190 POKE 54016,1
195 FOR J=1 TO 10:NEXT J
200 IF (STRIG(0)=0) THEN PRINT "SENSOR ";I
210 REM CHECK IF X KEY PRESSED
220 IF PEEK(764)=22 THEN 250
230 NEXT I
235 GOTO 180
240 REM CLEAR LAST KEYSTROKE
250 POKE 764,255
260 REM RESET DATA LINES FOR INPUT
270 POKE 54018,48
280 POKE 54016,0
290 POKE 54018,52

Back to previous page