Article View: net.micro.atari8
Article #128Anyone have a good method to detect the presence of Ramdisks?
From: paul van de graaf{}
Date: Thu, 10 Apr 1986 15:14
Date: Thu, 10 Apr 1986 15:14
25 lines
1789 bytes
1789 bytes
I have an application that needs to detect the presence of Ramdisks, and the particular drive number each resides. It's fairly easy to detect whether a machine has 130XE compatible memory expansion, but hard to cleanly figure out whether the it's used as a Ramdisk, and if so which drive number. Not to mention the Ramdisks which aren't XE compatible! So far, All I've come up with is this: I go through all of the disk drives, and attempt to read each drive's directory. If there's an error, I assume there's no drive present, otherwise I time how long it takes to read the directory. If it's under a second or so, I assume it's a Ramdisk. This works OK, but it's rather slow. Especially because of the long time-outs on a failed open of a directory. I tried using the Get Status Command of the CIO routine which is conciderably faster, but it fails to detect Ramdisks, because they obviously can't reply to serial bus commands. Anybody have a better solution? I've considered using a configuration file, but I'd like to automate the proceedure so the user needn't bother with such stuff. Thanks in advance, Paul van de Graaf Usenet: sdcsvax!sdcc12!wa60 @ U. C. San Diego Arpanet: wa60%sdcc12@ucsd.arpa
Technical Details
Message-ID:
<574@sdcc12.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!ittatc!dcdwest!sdcsvax!sdcc6!sdcc12!wa60Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!ittatc!dcdwest!sdcsvax!sdcc6!sdcc12!wa60
From: wa60@sdcc12.UUCP (paul van de graaf{})
Newsgroups: net.micro.atari8
Subject: Anyone have a good method to detect the presence of Ramdisks?
Message-ID: <574@sdcc12.UUCP>
Date: Thu, 10-Apr-86 10:14:53 EST
Article-I.D.: sdcc12.574
Posted: Thu Apr 10 10:14:53 1986
Date-Received: Sat, 12-Apr-86 22:48:19 EST
Organization: U.C. San Diego, Academic Computer Center
Lines: 25