Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!van-bc!ubc-cs!undergrad.cs.ubc.ca!apang From: apang@undergrad.cs.ubc.ca (Anthon 'Amiga' Pang) Newsgroups: comp.sys.amiga.tech Subject: Re: Help - Asynchronous I/O to/from files Message-ID: <1990Feb28.023511.4806@undergrad.cs.ubc.ca> Date: 28 Feb 90 02:35:11 GMT References: <99009@linus.UUCP> <9830@cbmvax.commodore.com> Sender: root@undergrad.cs.ubc.ca Reply-To: apang@b0 (JVNIc7B7ktKDA) Organization: Computer Science UBC Lines: 23 In article <9830@cbmvax.commodore.com> mks@cbmvax.commodore.com (Michael Sinz - CATS) writes: >In article <99009@linus.UUCP> duncant@mbunix.mitre.org (Thomson) writes: >> >>Can anyone tell me how to do asynchronous I/O to/from AmigaDOS files? >> >>That is,I want to issue a Read() or Write() request and not block, but >>be notified with a signal later when the I/O completes. I know that >>it's possible to send I/O request packets asynchonoushly to any device >>driver, but I don't want to deal with device drivers, I want to deal with >>the file system. Isn't there a way to do this? I can't find it in my RKMs. >>Any help would be appreciated? > >Yes, you send packets to AmigaDos directly. These are documented in the >AmigaDos manual (BANTAM Books, ISBN 0-553-34294-0) The packets are >actually sent to the FileSystem and this all works wonderfully. I guess you'll miss all that BCPL stuff in 1.4 :) Personally, I would have spawned a couple of tasks, which only used the upper level AmigaDOS routines--Open, Close, Read, Write, Lock, etc. Then, throw in a few message ports to handle the I/O request "packets". (In fact I did this for one of my courses last term, to demonstrate double buffered i/o--BTW, I wrote it in Modula-2.)