Title
Left ArrowCheats HomeRight ArrowCheats Misc ListCheats Number ListCheats A ListCheats B ListCheats C ListCheats D ListCheats E ListCheats F ListCheats G ListCheats H ListCheats I ListCheats J ListCheats K ListCheats L ListCheats M ListCheats N ListCheats O ListCheats P ListCheats Q ListCheats R ListCheats S ListCheats T ListCheats U ListCheats V ListCheats W ListCheats X ListCheats Y ListCheats Z List

Home Page

Projects...
PC Controller Box
Joystick Switch Box
c128D Refurb

Programs...
Byte Simulator
Cheat 'O Matic
GEOS

Collections...
3D Models
Book Collection

Information...
My BASIC Notes
Web Links

eMail Me

Note: You must add uk to the end of the address, it's to help prevent spam.

My BASIC Notes

Basic2 Commands
Disk Drives
ASCII and CHR$ Codes
PEEK's and POKE's
RAM Memory Map
ROM Memory Map
Screen Display
Sprite

STATUS
Abbreviation: ST

STATUS

TYPE: Integer Function
FORMAT: STATUS

Action: Returns a completion STATUS for the last input/output operation which was performed on an open file. The STATUS can be read from any peripheral device. The STATUS (or simply ST) keyword is a system defined variable-name into which the KERNAL puts the STATUS of I/O operations. A table of STATUS code values for tape, printer, disk and RS-232 file operations is shown below:

ST Bit Position ST Numeric Value Cassette Read Serial Bus R/W Tape Verify + Load
0 1   time out write  
1 2   time out read  
2 4 short block   short block
3 8 long block   long block
4 16 unrecoverable read error   any mismatch
5 32 checksum error   checksum error
6 64 end of file EOI  
7 -128 end of tape device not present end of tape

EXAMPLES of STATUS Function:

10 OPEN 1,4:OPEN 2,8,4,"MASTER FILE,SEQ,W"
20 GOSUB 100:REM CHECK STATUS
30 INPUT#2,A$,B,C
40 IF STATUS AND 64 THEN 80:REM HANDLE END-OF-FILE
50 GOSUB 100:REM CHECK STATUS
60 PRINT#1,A$,B;C
70 GOTO 20
80 CLOSE1:CLOSE2
90 GOSUB 100:END
100 IF ST > 0 THEN 9000:REM HANDLE FILE I/O ERROR
110 RETURN


Commodore Cheetah made by Allen Monks, started in the year 2000.