Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ulowell!cbmvax!jesup From: jesup@cbmvax.UUCP (Randell Jesup) Newsgroups: comp.sys.amiga.tech Subject: Re: Amigix (Re: alarm() function) Message-ID: <6363@cbmvax.UUCP> Date: 21 Mar 89 19:13:36 GMT References: <70@snll-arpagw.UUCP> Reply-To: jesup@cbmvax.UUCP (Randell Jesup) Organization: Commodore Technology, West Chester, PA Lines: 25 In article shadow@pawl.rpi.edu (Deven Thomas Corzine) writes: >In article <70@snll-arpagw.UUCP> paolucci@snll-arpagw.UUCP (Sam Paolucci) writes: > >Has anybody written a Unix compatible alarm() function on the amiga. For > >those not familiar, and to be more specific, its definition is ... >This same system task would also coordinate the alarm() function by >sending requests to the timer device, and only acting on the one most >recently defined by an alarm() call. (and AbortIO on any others, if >the timer.device supports it; otherwise simply deallocate and ignore >the IO request when it finally returns.) NO! NEVER deallocate or reuse an IO request until it has been returned by the device (and yes timer supports abortio, all devices must "support" it, though not all devices will actually try to stop the io in mid-stream.) Normal abort is AbortIO();WaitIO(). > >Also, the function should return the number of seconds remaining from a > >previous alarm request. > >CheckIO() should work for that, I think. CheckIO only tells you whether the request hs finished. -- Randell Jesup, Commodore Engineering {uunet|rutgers|allegra}!cbmvax!jesup