AP%( PEEK( DEVNAM% + OFFSET% ) ) ) & !for synonymns, the value is not the number of devices, but & !the location of the original name & !I don't understand why the -2% should be necessary 6000 ! & !check number of units & ! 6010 NUM.UNITS% = PEEK( DEVCNT% + OFFSET% ) 6020 IF NUM.UNITS% = -1% & THEN PRINT BELL$;"There is no such device." \ & GOTO 2000 6030 IF UNIT% > NUM.UNITS% & THEN PRINT BELL$;"There are not that many units." \ & GOTO 2000 7000 ! & !find the DDB and print some data & ! 7010 DEVTBL% = PEEK( DEVPTR% + OFFSET% ) 7020 DDB% = PEEK( DEVTBL% + 2% * UNIT% ) 7030 GOSUB 11000 8000 ! & !go back for more & ! 8010 GOTO 2000 9000 ! & !normal exit & ! 9990 GOTO 32767 10000 ! & ! & ! SUBROUTINE: Addresses from monitor tables & ! & ! & !Monitor tables part one & ! 10010 T$ = SYS( CHR$(6%) + CHR$(-3%) ) 10020 CHANGE T$ TO T% 10030 DEVCNT% = T%(5%) + SWAP%(T%(6%)) 10040 DEVPTR% = T%(7%) + SWAP%(T%(8%)) 10100 ! & !Monitor tables part two & ! 10110 T$ = SYS( CHR$(6%) + CHR$(-12%) ) 10120 CHANGE T$ TO T% 10130 DEVNAM% = T%( 5%) + SWAP%(T%( 6%)) 10140 DEVOKB% = T%( 9%) + SWAP%(T%(10%)) 10150 DEVSYN% = T%(23%) + SWAP%(T%(24%)) 10900 ! & !return & ! 10990 RETURN 11000 ! & ! & ! SUBROUTINE: data from DDB & ! & ! & !job number & ! 11010 JOB% = PEEK( DDB% + 2% ) AND 255% 11020 IF JOB% / 2% * 2% <> JOB% & THEN PRINT "Device is disabled." \ & GOTO 11100 11030 JOB% = JOB% / 2% \ & JOB$ = NUM1$(JOB%) 11040 IF JOB% = 0% & THEN PRINT "Device is free." \ & GOTO 11100 11050 DDCNT.FLAGS% = PEEK( DDB% + 6% ) 11060 IF DDCNT.FLAGS% < 0% & THEN PRINT "Device was assigned by job number "; JOB$; \ & PRINT " at "; TIME$( PEEK( DDB% + 4% ) ) \ & GOTO 11100 11070 IF DDCNT.FLAGS% AND 8192% & AND TYPE$ = "KB" & THEN PRINT "Device is console terminal for job number "; JOB$ \ & GOTO 11100 11080 PRINT "Device is being used by job number "; JOB$ 11100 ! & !ownership privilege and read/write privileges & ! 11110 DDSTS.FLAGS% = PEEK( DDB% ) 11120 IF DDSTS.FLAGS% AND 256% & THEN PRINT "Ownership of device requires privilege." 11130 IF DDSTS.FLAGS% AND 512% & THEN PRINT "Read privileges are never given out." 11140 IF DDSTS.FLAGS% AND 1024% & THEN PRINT "Write privileges are never given out." 11200 ! & !for KB's only & ! 11210 IF TYPE$ <> "KB" & THEN GOTO 11300 11220 TTCHAR% = PEEK( DDB% + 28% ) 11230 IF TTCHAR% AND 32% & THEN PRINT "This keyboard is a scope terminal." & ELSE PRINT "This keyboard is not a scope terminal." 11300 ! & !this is only here as the target of a GOTO & ! 11900 ! & !return & ! 11990 RETURN 19000 ! & ! & ! Error Routine & ! & ! 19100 ! & !^C error & ! 19200 ! & !Expected errors (by line number) & ! 19210 IF ERL = 2060 THEN RESUME 2070 & !illegal number for unit 19600 ! & !Expected errors (by type) & ! 19900 ! & !Unexpected errors & ! 19910 Z$ = SYS(CHR$(6%)+CHR$(9%)+CHR$(ERR)) 19920 ERROR$ = RIGHT(Z$,3%) 19930 PRINT " ***** Whoops! *****" \ & PRINT " "; ERROR$; " at line";ERL 19990 GOTO 32767 32767 END DDB BAS[.050021]DDB .BAS[.050021]    X14|H [4;Ik(&'( k ߫H&P` \RrPP2PPzPP{PPPPP2P~\$\\TD 0D \~ hi) +\ ^( n ^( np\^txY\^ˀ\!kVk<\F˰<˴ˬ\VVkˤ1`@lP ABCDEFGHIJKLMNOPQRSTUVWXYZ$.?0123456789<@<SЬTЬ UQS>?\\\\\\\\\`:#@'="\abcdefghi\\\\\\\jklmnopqr\\\\\\\~stuvwxyz\\\\\\\\\\\\\\\\\\\\\\{ABCDEFGHI\\\\\\}JKLMNOPQR\\\\\\\\STUVWXYZ\\\\\\0123456789\\\\\  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~@ggh<i|o<m<4p<p<k|Zn<l fr rwx<x<x<x޺<w@]@@fjnr]Ze@@|> | |v<H|  |  |xz|  |zt f r   < &^ @&@'*/V,"?Lh:hmBmz|z{x`y~|fN|@@|@͂|@ ݃ƃ<ns<|Ŏ |️|ep|u|-@率|<ᄇ2ֻr||ZRM | ntB|xyvZw|J=|R>|J? nnaa|bddf