[comp.sys.ibm.pc] AT Interrupts + Disk access

dr@skivs.UUCP (David Robins) (02/22/89)

I have a data acquisition problem, where I need to acquire large
amounts of 12-bit data at 200 Hz, and store to hard disk.

I have seen examples of double-buffering using DMA, and writing one
buffer to disk while the other buffer is filling.  The problem is, the
incoming data is not easily available, without keeping track of the
DMA data pointer, and the software may not cycle around in time and
may miss a point.  DMA does not interfere with disk access.
(There was an article in Personal Engineering & Instrumentation News a
couple years back where Richard Quinn of Quinn-Curtis wrote a Pascal
double-buffering example for the "Turbo Tools" column.  This is part
of the Metrabyte Turbo Tools package he sells for the Metrabyte A-D
boards.)

I want to do the same thing, using interrupt-driven acquisition.
Either each sample causes an interrupt, or, if I want a group of
samples in a block (several channels, almost simultaneously) I can use
DMA to a small buffer with an interrupt at the end of the block.  The
interrupt service routine would give me the data, and store in a
buffer, too. The foreground task would test for buffer full, and write
the buffer to disk.

The main question-->>  do hardware interrupts interfere with disk access?
(by screwing up timing?)  If it could, I would assume that DOS would
disable interrupts during disk access, causing gaps in my data, and
preventing my use of interrupt sampling.  Can I safely use interrupts
and write to disk (foreground task) at the same time?

Please email, or post replies to this newsgroup.
-- 
David Robins, M.D.  (ophthalmologist / electronics engineer)
The Smith-Kettlewell Institute of Visual Science,  ***  net:  uunet!skivs!dr
2232 Webster St, San Francisco CA 94115            ***  415/561-1705 (voice) 
The opinions expressed herein do not reflect the opinion of the Institute!