Info-IBMPC@B.ISI.EDU (Info-IBMPC Digest) (09/26/86)
Info-IBMPC Digest Thursday, September 25, 1986 Volume 5 : Issue 87 This Week's Editor: Richard Gillmann Today's Topics: Loadable Device Drivers New Library Files New Version of REFORMAT Ratfor RF77 Re: Multi-Language Word Processing Re: SCSI Interface Setting the DOS Environment Re: Displaywriter III DOS 3.2 and ugly Ctrl-U (and Esc) behaviour MS Mouse 6.0 & MS Word 3.1 Today's Queries: How many I/O Wait States? MS-DOS Tech Ref Encyclopedia Query Microsoft C V4.0 Upgrade Query Paradise Autoswitch EGA Query Video Recorder Interface Query Query: Head-settle time patch for DOS 3.10? Xenix Graphics Screen driver wanted Chemistry Program Wanted Query: Mixing MS C & Fortran PGA/EGA/CGA Card Wanted WPSplus and DECNet-DOS Query Graphics Screen Dump Query Satellite tracking program wanted ---------------------------------------------------------------------- Date: 16 Sep 86 10:12 EST From: DIXON WALTER V <DIXON@ge-crd.arpa> Subject: Loadable Device Drivers To: info-ibmpc@b.isi.edu A while back a query and some responses were posted to the net concerning device drivers which load after DOS is booted. There was some speculation that there was a documented way to do this because some RAM disks are installed after DOS is booted. I don't believe that these RAM disks are a good model. All of the RAM disks that I have seen which load after DOS is booted are not true device drivers. They rely on DOS creating the necessary data structures and then plugg into INT 13. One of the replies suggested inserting the new driver code in the device driver chain and provided a technique for determining the listhead of this structure. This technique will indeed work for most character devices. Installing block devices on the fly is slightly more complicated, but it is possible. I'll explain what needs to be done and provide a sample ram disk driver written in Microsoft C, but first a word of caution. I have hacked on DOS for a couple of hours and unraveled some of the IO subsystem. I did not spend a great deal of time on this task and have made some educated guesses. I want to stress the word GUESSES. I have deciphered enough of what DOS is doing to implement a true self-loading device driver. I believe that the driver is fully functional, but I make no guarantees. I also make no claims about the absolute accuracy of the information which I gathered in the process. If anyone notices any inaccuracies in this description, please let me know. I'll summarize the replies and post them to the net. It is virtually certain that this technique will break with future DOS releases. All drivers are linked together using the NUL device as a list- head. DOS creates some auxiliary data structures for block devices. The current clock and console are treated slightly different than other character devices. The key to the IO system in DOS is the so-called list of lists. The address of this data structure is returned in ES:BX by the undocumented bios interrupt (21H) with AH=52H. The format of this table is summarized below. Offset Use 0 far pointer to list of block devices and their characteristics (BLKINF) 4 ??? 8 far pointer to prologue of current clock device 12 far pointer to current console device 16 ??? 18 far pointer to list of cached disk blocks(?) 22 far pointer to array of volume context information. The distinction between what goes here and what goes in the list with listhead at offset 0 is unclear. (DSKCTX) 26 ??? 30 ??? 32 current number of block devices 33 maximum number of block devices (lastdrive in config.sys) 34 header for NUL device driver DOS list of lists The block device information is kept in a linked list. The format of this list is summarized below. Offset Use 0 Absolute drive number (A=0,B=1, etc.) 1 Relative disk number. A block device driver can deal with more than one drive (In fact there is one device driver for both floppy and hard disks on the IBMPC). This number identifies the particular unit. 2 Sector size (bytes) 4 Cluster size (power of 2) 5 ??? 6 Block number of first sector of FAT 8 Number of FATs 9 Root directory size (entries) 11 Block number of first sector following root directory 13 Number of blocks on disk + 1 15 Fat size (clusters) 16 Block number of first sector of root directory 18 FAR pointer to driver prologue (header) 22 Media code 23 Media changed flag (=-1 if media has changed?) 24 Far pointer to next block device information structure 28 ??? Block Device Information The volume information block is summarized below. The volume information for all drives is organized as an array of lastdrive elements. Offset Use 0 Current drive and directory string (eg E:\RAMDISK) 64 ??? 67 flag 0x4000 seems to be a magic number which insures that the information is valid. 69 ??? VOLUME context information These data structures are build as DOS boots up. The space for the Volume context information is preallocated (based on lastdrive), and cannot expand dynamically. The block device information is a linked list and is dynamic. It appears that when a device is loaded, all unused memory is available to the driver. The break address passed back to DOS from the INIT request tells DOS how much memory can be released. DOS inserts the driver into the linked list of devices (always immediately after the NUL device). If the device is either a console or clock driver, its header is stored in the list of lists. If the device is a block device the number of block devices is incremented and checked against the maximum number of block devices. A block device information block is allocated and inserted at the end of the list of block devices. The volume context information is filled in and marked valid?. Some initial calculations are performed based on the information returned in the table of bios parameter blocks. DOS figures out where the FAT, root directory, and mapped (by FAT) sections of the disk start. Block devices can be located by indexing into the array of volume context information, and character devices are located by traversing the linked list of devices until the device name is matched. Dynamically loading a character device involves locating the NUL device (either by doing a FCB style open as perviously suggested, or by using the list of lists). The address of the driver prologue is inserted after the null device. If the driver is for a the console or clock, the list of lists must be updated. If the device is block device, the drive count must be updated, the volume context information must be filled in and validated, and the block device information must be filled in and inserted at the tail of the list of block devices. What follows is a RAM disk driver written in Microsoft C with a short assembly language interface to DOS and a utility program to locate device drivers and display device information. This latter program was thrown together very quickly (read poorly designed), but it does the job. I have found it helpful in debugging device drivers. [RAMDISK.C has been added to the Info-IBMPC library. -rag] ------------------------------ Date: 23 Sep 1986 11:48:42 PDT Subject: New Library Files From: Info-IBMPC Digest <Info-IBMPC@B.ISI.EDU> To: Info-IBMPC@B.ISI.EDU Two new files have been added to the library. ASCII.C is an Ascii file dump routine submitted by Ya'akov_Miles. ARC.FORMAT is a technical description of the ARC file format submitted by Keith Petersen. ------------------------------ Date: Thu, 18 Sep 86 12:18:57 MET To: INFO-IBMPC-REQUEST@USC-ISIB.ARPA From: U001222%HNYKUN11.BITNET@WISCVM.WISC.EDU Subject: New Version of REFORMAT I am submitting a new version of the REFORMAT program which is in the IBMPC library. The major change in the program is that now the FATs for big disks (DOS 3.X) are handled properly. A number of potentially dangerous spots have been corrected. Large parts of the code have been rewritten, and a number of routines to handle word size integers have been added. Please replace the version in the library with tis new one.. This version has been tested during the last two months on a number of PC's and disks, with DOS versions from 2.0 thru 3.1. The program now checks the DOS version, and, since I did not have access to a copy of DOS 3.2, it will not run under that DOS version. The source contains directions for patching the test, as to include also DOS 3.2. Doeg, Jos Wennmacker <U001222@HNYKUN11> Universitair Rekencentrum Geert Grooteplein Zuid 41 NL-6525 GA Nijmegen The Netherlands. [REFORMAT.PAS and REFORMAT.DOC have been updated. Note that REFORMAT.PAS is a collection of files. -rag] ------------------------------ Date: Sun, 21 Sep 1986 23:12 PDT From: "Jeffrey Sicherman" <JAJZ801%CALSTATE.BITNET@WISCVM.WISC.EDU> Subject: Ratfor RF77 To: <INFO-IBMPC@B.ISI.EDU> I recently received somw marketing propoganda about a product called RF77 which proports to be a PC-based, enhanced implementation of the RATFOR translator as described in Software Tools by Kernighan and Plauger. Adds WHILE, FOR, REPEAT-UNTIL, BREAK, NEXT, #DEFINE (like parameters) and #INCLUDE to preprocessor. Supposedly generates either Fortran-77 code that is compatible with PC versions (IBM, MS, RM) or for old FORTRAN-IV that may be uploaded to minis and mainframes. I have two questions with respect to this: 1. Does anybody have any experience with this particular product (they claim to be releasing a new version) 2. Is there any other implementations of the same, public domain or otherwise and what are their quality (and where might one get them) ? The name of the manufacturer/distributor, if anyone is interested (or braver than I am at this point) is: Logical Developments P.O. Box 55798 Houston, Texas 77255 Orders (24 hr): 1-800-835-2246, ext. 41 Price: $65.00 + 3.98 tax for Texas residents ------------------------------ From: jack!man!wolf!rgale@sdcsvax.ucsd.edu To: INFO-IBMPC@b.isi.edu, STANKULI%cs.umass.edu@RELAY.CS.NET Subject: Re: Multi-Language Word Processing Date: Sun Sep 21 19:35:35 1986 oliveb!tslu.uucp writes: > The most popular CHINESE CHARACTER PACKAGE so far is the KCCDS > system. You can mix English with Chinese characters, and it > supports lots popular software packages: LOTUS 1-2-3, DBASE III, > .....etc, We looked at KCCDS. While a nice enough package, it has drawbacks. What killed it for us was its size -- since it takes about 280K to run, there wasn't enough memory left over to run our application under it. While it does indeed allow you to run Lotus 1-2-3 (for instance), don't plan on having a spreadsheet of any reasonable size. So we bought DALT instead (the full name is "Digital Analytical Language Translation System"). While KCCDS may be the 'most popular', DALT is the most widely-used -- over 40,000 installations (in China, Korea, Japan, and U.S. academic and government). It requires a Hercules graphics card, and at $965 it's not cheap, but... To begin with, it handles 11 languages (Chinese, simplified Chinese, Japanese [both Kana and Katakana], Korean, Thai, Russian, Greek, English, Arabic, Hebrew) -- and actually does translation (both transliteration and grammatical processing), rather than merely 'word processing'. Additionally, it disambiguates input: if you enter "He looked at the girl with a telescope", it will ask (in whichever language was used for the input) who has the telescope -- the girl or the observer? DALT was originally designed for the intelligence community. When a field operative writes "I see a tank", is he looking at a storage container or an armored vehicle? If the latter, what size/shape? Of course, we didn't buy this front end :-) Next, it's hardware-based (comes with a 1/2-card), so it's not only faster but doesn't eat RAM. In fact, it'll run on a 256K machine, not that you'd want to do so. Rather than using stored bit-maps, characters are generated algorithmically -- 50,000 Chinese characters {ccupy only 70K RAM, leaving *lots* more space to run your applications (dBase, 1-2-3, word processing, etc.). Disclaimer: I don't read any of the languages it supports, and so can't personally vouch for any of this. The folks here who are using it, however, are impressed. DALT Systems 9921 Carmel Mountain Road Suite 196 San Diego, CA 92129 -- Ryan Gale UUCP: {ihnp4,sdcsvax,gould9,hplabs!hp-sdd} !crash!pnet01!rgale ARPA: {sdcsvax,noscvax} !crash!pnet01!rgale@nosc ------------------------------ Date: Mon, 22 Sep 86 17:18 PDT From: GEORGEBURKITT.ES@Xerox.COM Subject: Re: SCSI Interface To: INFO-IBMPC@B.ISI.EDU >I have a cheap SCSI disk sitting around and have been looking for a host >interface for an XT for some time. Does anyone know of a cheap source >for such a beast? Or has the low cost of ST506 controllers driven them >out of the market?? I can't swear as to 'cheap', but Advanced Storage Concepts, Inc. Houston, Tx, (800)423-9175 has run an ad for their SCSI-MANAGER, for the PC, @ $149.00 in onesies, "includes board w/SCSIBIOS". That compares with the Emulex IB02 at $445, Adaptec ACB4520 at $500 and NCR ADP-31A for $300; and probably some I haven't seen advertised. Once a company called Media Distributing (800)824-7386, sold a Z-80 adapter to SCSI; I don't know if they have ever offered a PC type. Disclaimers apply; I have used the Z-80 adapter and found it handy but sensitive to noise; I haven't got the others to run yet. ------------------------------ Date: Tue, 16 Sep 86 16:35:44 PDT From: Jim Carter <jimc@LOCUS.UCLA.EDU> To: info-ibmpc@b.isi.edu Subject: Setting the DOS Environment The enclosed program "setenv.c", when executed in a batch file, will read standard input (the keyboard) and will set an environment variable to that value. Thus batch files can ask questions of the user. The program was developed and tested on PC-DOS v3.2 and compiled with IBM "C" v1.0 by Microsoft. There is a good chance that it will work with other PC-DOS versions and with MS-DOS. DOS keeps a master copy of the environment, and makes a copy of it for each program. Thus if the program sets a variable in its copy, it vanishes on exit. (This is also true in batch files run by a forked command.com.) "setenv.c" changes the master copy, not the local copy, using a rather nasty kludge. Warning: Set the path BEFORE running the first stay-resident program (presumably in autoexec.bat), or "setenv.c" will fail to recognize when the environment overflows and could clobber something in that eventuality. Does anybody know where DOS keeps the pointer to and length of the environment? I searched exhaustively but couldn't find either one. James F. Carter (213) 206-1306 UCLA-SEASnet; 2567 Boelter Hall; 405 Hilgard Ave.; Los Angeles, CA 90024 UUCP:...!{ihnp4,ucbvax,{hao!cepu}}!ucla-cs!jimc ARPA:jimc@locus.UCLA.EDU [SETENV.C has been added to the Info-IBMPC Library. -rag] ------------------------------ Date: Mon, 22 Sep 86 22:59:47 EDT From: wb8foz <@CSNET-RELAY.ARPA,@CASE.CSNET:wb8foz@ncoast.uucp> Subject: Re: Displaywriter III >From: Carl Bower USAISMA AV277-5291 <cbower@apg-3.ARPA> >The IBM Displaywriter III uses 8" floppy drives. How can I transfer >files from the 8" floppies to a 5.25" floppy on an IBM-PCXT. The >Displaywriter doesn't appear to have a serial port or a way of loading >a communications program to do a modem to modem transfer. Any help >would be appreciated. cbower@apg-3 You need a "Displaywriter/Personal Computer Attachment Convenience Kit" from Big Blue Brother. This consists of s/w for both a PC and the DW, some special cable, and documentation. You will need a serial port on the PC, and I suspect it will NOT work with a clone. The DW becomes a terminal to work the PC. You can then move the files to the PC. BUT!!! they will be in DCA (ie Display Write II)format, which means EBCDIC. (ugh). Both Multimate and Wordstar offer utilities to make DCA files into ASCII. The kit costs $500.00 and the # of the press release on it is 184-055. Of course nowhere on it did IBEAM put the number of the *product*. Good Luck. David Lesher decvax!cwruecmp!ncoast!wb8foz ------------------------------ Date: Wed, 24 Sep 86 10:34:50 PDT From: Ya'akov_Miles%UBC.MAILNET@MIT-MULTICS.ARPA To: info-ibmpc@USC-ISIB.ARPA Subject: DOS 3.2 and ugly Ctrl-U (and Esc) behaviour Does anyone know of a way to patch PC-DOS ver 3.2 so that Ctrl-U works the same way it did under PC-DOS 3.1 ? (ie, delete the input buffer) I have found that typing Ctrl-U just prints ^U under dos 3.2, instead of accomplishing anything useful, and have been so annoyed by this bad manners that I have refused to buy PC-DOS ver 3.2 It also would be nice if ESC also deleted the input buffer, the way it does in BASIC.COM It would also be nice if IBM provided a mechanism (maybe Up-Arrow and Down-Arrow) so that the user could scroll up and down among lines previously entered. The PC-DOS recall feature F3 is pathetic. There is no way to edit the middle of a long command line other than to delete all the characters after the one you want to edit ------------------------------ Date: Wed, 24 Sep 86 23:04:29 EDT From: "James H. Coombs" <JAZBO%BROWNVM.BITNET@WISCVM.WISC.EDU> Subject: MS Mouse 6.0 & MS Word 3.1 To: info-ibmpc@USC-ISIB.ARPA MicroSoft has announced version 6.0 of their mouse. There are a number of software enhancements and apparently some hardware changes as well. They have not started shipping yet. Mouse buyers will probably want to wait for this new version. MicroSoft is expected to new versions of Word. One is for networks. The other is an update of 3.0 and will probably include a thesaurus. Potential Word buyers may want to wait a bit. --Jim ------------------------------ Date: Thu 25 Sep 86 10:35:29-EDT From: Gern <GUBBINS@RADC-TOPS20.ARPA> Subject: How many I/O Wait States? To: INFO-IBMPC@B.ISI.EDU I am looking for information as to how many I/O Wait States are PROVIDED (if any) in an IBM-PC, IBM-AT (at 6 and 8MHz), and clones such as the Z-248. I know that some machines provide wait states for memory (IBM-AT) and others don't (Z-248), but I am interested in I/O (IN/OUT, INP/OUT instructions) wait states during port read/writes. I know that some I/O W.S. must be provided for the CRTC and other I/O in the IBM-PC, but is it provided for individually (each I/O port provides its own) or is blanketed for all I/O? Any help will be appreciated. Thanx, Gern ------------------------------ Date: Mon, 22 Sep 86 11:21:35 PDT From: Jim Anderson <bilbo.jta@LOCUS.UCLA.EDU> To: info-ibmpc@b.isi.edu Subject: MS-DOS Tech Ref Encyclopedia Query Would anyone who has spent some time with the $135 "MS-DOS Technical Reference Encyclopedia" care to comment on it? Does it reveal any deep dark secrets of MS-DOS? Would it be worth the price to someone who was building a network redirector? The person I spoke to at Op-Amp technical books said the book had been recalled due to some serious errors. Anyone spot any of these errors? ------------------------------ To: info-ibmpc@isib Subject: Microsoft C V4.0 Upgrade Query Date: Mon, 22 Sep 86 18:47:30 -0500 From: jcmorris@mitre.ARPA I've seen several notes here and on other BBS on usoft's new version 4 C compiler, including comments that purchasers of the V3 product can get a price break on the upgrade. I haven't seen, however, anybody say just how we can get this deal. Users of other usoft products (e.g., WORD) get an order form in the mail, but although I sent in my registration form I've received no notice of the new release. Did the mail get lost, or did usoft take a cue from Borland and rely on word-of-mouth reports to announce their upgrade policy? (BTW: that really IS Borland's position. I asked them and they said yes.) Joe Morris (jcmorris@mitre) ------------------------------ Date: Tue, 23 Sep 86 11:33:54 MEZ To: INFO-IBMPC@B.ISI.EDU.ARPA From: UNI217%DBNRHRZ1.BITNET@WISCVM.WISC.EDU Subject: Paradise Autoswitch EGA Query Has anyone out there had any experience with EGA-compatible cards that can also emulate Hercules / CGA ? I have heard of a card called "Paradise Autoswitch EGA", which can operate like CGA/EGA/Hercules. The next question would be what monitor you need to operate such a card in all its modes. I would appreciate if someone could help me with this problem. (My hardware is a Zenith Z-158 PC clone). Thank you, Rainer Kleinrensing ------------------------------ Date: Tue, 23 Sep 86 09:15:56 PDT From: Dave_Goodman%SFU.Mailnet%UBC.MAILNET@MIT-MULTICS.ARPA To: INFO-IBMPC%B.ISI.EDU%MIT-MULTICS.ARPA@UBC.Mailnet Subject: Video Recorder Interface Query I would appreciate information on how one can interface a video recorder to a PC such that the PC can control the recorder to go to certain sections of the tape. Information on commercial products would also be valuable. ------------------------------ Date: Tue, 23 Sep 86 23:30 EDT From: Hess@MIT-MULTICS.ARPA Subject: Query: Head-settle time patch for DOS 3.10? To: INFO-IBMPC@B.ISI.EDU Does anybody have a head-settle patch for IBMBIO.COM for DOS 3.10? I've found one for DOS 2.10, but it seems that 3.10 is just as slow as all of them (except DOS 1.1). Thanks, Brian ------------------------------ From: nike!lll-crg!seismo!munnari!elecvax.oz!fredb@cad.Berkeley.EDU Date: Wed, 24 Sep 86 14:38:59 EST To: nike!B.ISI.EDU.UUCP!info-IBMPC To: info-ibmpc@b.isi.edu Subject: Xenix Graphics Screen driver wanted Wanted: Driver(s) under Xenix Sys V.2 for the bit-mapped screen of an IBM-PC/AT or a NEC APC-IV. (A poor-man's SUN ?) (The standard Xenix distribution only supports character mode for the IBM graphics devices). Source code would be preferred, so that the NEC 1024x780 "Power" graphics card could be supported in addition to the PC-compatible junk. Such drivers are technically feasible, and I have heard the rumour that SCO are developing a GKS driver (what device? when? where?) Any help would be appreciated - "Fred" (RJ) Bassett Dept of Textile Technology Uni of NSW Kensington 2033 Australia ACSnet: fredb@elecvax.oz ARPA: fredb%elecvax.oz@seismo CSnet: fredb@elecvax.oz@csnet-relay.csnet UUCP: {seismo,ubc-vision,ukc,mcvax,prlb2}!munnari!elecvax.oz!fredb ------------------------------ Date: Wed 24 Sep 86 05:21:35-PDT From: Tony Brand <BRAND@SUMEX-AIM.ARPA> Subject: Chemistry Program Wanted To: info-ibmpc@B.ISI.EDU One of my colleagues is looking for an PC-compatible program which will generate Russell-Saunders micro-state tables for eletronic configurations. Anyone out there tried it? Tony Brand Trenton State College Voice : (609)-771-3013 Data : (609)-771-2829 ------------------------------ Date: Wed, 24 Sep 86 10:35:24 CDT From: MATHPG1%UMCVMB.BITNET@WISCVM.WISC.EDU (Rich Winkel UMC Math Department) To: info-ibmpc@usc-isib.arpa Subject: Query: Mixing MS C & Fortran Does anyone have any experience calling an MS C subroutine from within an MS FORTRAN program? Any advice would be appreciated. Rich Winkel ------------------------------ Date: Wed, 24 Sep 86 18:59:30 EDT From: Clif Sothoron <cbsoth@BRL> To: info-ibmpc@usc-isib.ARPA Subject: PGA/EGA/CGA Card Wanted Does a card exist that emulates the IBM color graphics adapter, enhanced graphics adapter and the professional graphics adapter on an IBM PC-AT? I have a NEC Multisync (800x560 resolution) monitor which allows all these emulations. I am currently using a Quadram EGA+ card which emulates the IBM CGA/EGA cards but no PGA. The NEC documentation says the PGA card is an analog card. Does this prohibit the existance of the CGA/EGA/PGA card I am looking for? Thanks in advance, Clif Clifton B. Sothoron Ballistic Research Laboratory Aberdeen Proving Grounds, Md. ------------------------------ DATE: 092586 08.25.00 TO: <INFO-IBMPC-REQUEST@USC-ISIB> From: <ACSKATJ%HUTRUU0.BITNET@WISCVM.WISC.EDU> Subject: WPSplus and DECNet-DOS Query Are there any users which have experience with the DEC-packages WPSplus and/or DECNet-DOS for MSDOS-micro's? Impressions and conclusions about things like 'quality', 'performance', 'documentation', 'easiness of use', etc. are welcome. Comparison with other packages are also interesting. Please reply me directly by electronic mail. Thanks in advance! Jan van Kats ACCU (State University of Utrecht) EARN: ACSKATJ at HUTRUU0 EUNET: mcvax!accumv!acskatj ------------------------------ Date: Wed, 24 Sep 86 13:15:33 CDT From: CCRJW%UMCVMB.BITNET@WISCVM.WISC.EDU (Richard Winkel UMC Computing Services) To: INFO-IBMPC@USC-ISIB.ARPA Subject: Graphics screen dump Query Does anyone know of a program similar to GRAPHICS.COM which will work for the EGA in hi-res mode? Also, I'm looking for a GRAPHICS.COM which will drive the Toshiba 1351. Thanks for any help! ------------------------------ Date: Thu, 25 Sep 86 14:36 CET From: Ralf D. Kloth <ZRKL001%DTUZDV1.BitNet@ucbvax.Berkeley.EDU> Subject: Satellite tracking program wanted To: Info-IBMPC <INFO-IBMPC@b.isi.edu> I am looking for a tracking program for orbiting satellites (like the public amateur radio satellites OSCAR.., RS.., JAS1, as well as NOAA, etc) to predict a satellite's orbit and overflying over a given location by calculation from a given Keplerian element listing. Has anyone such a program available (public domain) which I could adapt to run on my IBM PC-XT ? PASCAL or FORTRAN preferred, but C or BASIC also welcome. Waiting for any source listings ... 73, Ralf D. Kloth (DL4TA), ZRKL001 at DTUZDV1.BITNET, West Germany ------------------------------ End of Info-IBMPC Digest ************************ -------