Path: utzoo!utgpu!watserv1!watdragon!lion!ccplumb From: ccplumb@lion.waterloo.edu (Colin Plumb) Newsgroups: comp.sys.amiga.tech Subject: Re: A couple of AmigaDOS questions... Message-ID: <20642@watdragon.waterloo.edu> Date: 7 Feb 90 19:48:26 GMT References: Sender: daemon@watdragon.waterloo.edu Reply-To: ccplumb@lion.waterloo.edu (Colin Plumb) Organization: U. of Waterloo, Ontario Lines: 22 In article tw0i+@andrew.cmu.edu (Todd Andrew Williamson) writes: >1) Is there a way to do non-blocking reads from an AmigaDOS > FileHandle? Yes. All the DOS functions do is send a packet to the apropriate handler and wait for it to return. If you dive into the grungy bits yourself, use DeviceProc() to find the address of the handler and fill in packets, in all their BPTR-laden glory yourself, you can wait for them to come back to any message port you like. I believe some code to do this is in Matt Dillon's suplib. CMU has FTP, so have a look on ucbvax.berkeley.edu pub/dillon/... >2) Is there a way to get a signal when I/O is available on > a FileHandle? Well, an asynchronous read of one byte will work well. I can't think of a way, other than character-by-character, to get "whatever's currently available;" maybe someone else who's read the manual in the last moth has an idea? -- -Colin