From owner-freebsd-questions Mon Aug 26 12:10:01 1996 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id MAA05967 for questions-outgoing; Mon, 26 Aug 1996 12:10:01 -0700 (PDT) Received: from cicese.cicese.mx (cicese.cicese.mx [158.97.1.33]) by freefall.freebsd.org (8.7.5/8.7.3) with SMTP id MAA05938 for ; Mon, 26 Aug 1996 12:09:57 -0700 (PDT) Received: from knuth (knuth.cicese.mx) by cicese.cicese.mx (4.1/SMI-4.1) id AA15514; Mon, 26 Aug 96 12:09:23 PDT Message-Id: <3221F638.417C@cicese.mx> Date: Mon, 26 Aug 1996 12:08:40 -0700 From: Raymundo Vega Aguilar Organization: CICESE X-Mailer: Mozilla 3.0 (X11; I; SunOS 5.4 sun4c) Mime-Version: 1.0 To: KUMAR@BOGPO1.CO.unisys.com Cc: questions@FreeBSD.ORG Subject: Re: Help! References: <199608260328.XAA29753@james.freenet.hamilton.on.ca> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-questions@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > In Email, "Kumar, Rao CO" wrote: > > Thanks in advance for your time. I saw your mail id on the Internet. So I am > sending you this mail > and would highly appreciate your help. > I have written a TSR (that runs on MS DOS 6.2) that intercepts the interrupt > 1C (timer interrupt). What I am > trying to do in this interrupt handler is some file i/o (using fopen, fread > and fclose of Microsoft C). Because MS-DOS is a NOT reentrant pseudo-operating system, is very difficult to use file i/o from a TSR program, the solution is somewhat complex (and outside the scope of this list) so if you really want to contnue the proyect, then you have to read: Title: Extending TurboC profesional. Author: Al Stevens ed: Sams Book. (not sure) This is the only one that i have read and has a chapter on the subject. > At times the system hangs. I thought it was due to some conflict in > simultaneous handling of interrupt 21h by the file i/o calls inside my > routine and the foreground application. So I tried to do a check for the > InDOS > flag before proceeding with my interrupt handling routine, but this flag is > always 1 when my interrupt > routine is invoked (even when there is no front end application). > > Probably because the InDOS flag is not being set by the front-end > application, but by your interrupt handling routine. You have to replace the disk I/O interrupt as well. > > 2. Is there any other way to know if MS DOS is executing a 21h interrput ? Yes, but dont remember which one is it. Saludos Raymundo.