Topic : The ATARI Compendium
Author : Scott Sanders / JAY Software
Version : 1.25 (20/6/2003)
Subject : Documentation
Nodes : 1117
Index Size : 32614
HCP-Version : 6
Compiled on : Atari
@charset : UTF-8
@lang : en
@default :
@help : %About
@options : +g -i -t4 +y +z
@width : 100
View Ref-FileBconout()Cauxos()Cconos()Cprnos()Bcostat() BIOSSyntaxLONG Bcostat( dev )
WORD dev;
Function Bcostat() determines if the specified device is prepared to
receive a character.
Opcode 8 (0x08)
Availability All TOSversions.
Parameters dev specifies the device to poll as listed under Bconout().
Binding move.w dev,-(sp)
move.w #$08,-(sp)
trap #13
addq.l #4,sp
Return Value Bcostat() returns 0 if the device is not ready to receive
characters or -1 otherwise.
Caveats A bug in TOS 1.0 existed that caused the IKBD and MIDI device numbers to become swapped when being handled by the
Bcostat() call, subsequently returning data for the wrong
device. To allow previously written programs to continue
operating correctly, this bug has been maintained on purpose
in all current versions of TOS. You should therefore specify
a value of 3 for the IKBD and 4 for MIDI for this call only.
See Also Bconout(), Cauxos(), Cconos(), Cprnos()