home *** CD-ROM | disk | FTP | other *** search
/ hobbes.nmsu.edu / 2008-06-02_hobbes.nmsu.edu.zip / dos / mscdex2.zip / MSCDEX.OS2 next >
Text File  |  1993-03-02  |  15KB  |  314 lines

  1.                   MSCDEX.EXE under OS2
  2.  
  3.      Due to tremendous interest in getting version of MSCDEX.EXE
  4. that would work in normal DOS session under OS2, I have pulled
  5. following message from my archive. At the time of reading the message
  6. it seemed to be very interesting. I have done almost the same
  7. thing as the author of the original message. Not testing my results
  8. properly I have posted first version of my hack to hobbes (on 3.1.93).
  9. The I was notified by several prospective users that it doesn't
  10. work. So I have tried harder and finaly understood what is going
  11. on:
  12.  
  13. 1) I have learned, that MSCDEX.EXE is a wild hack on the Microsoft
  14.    side, accessing internal structures of DOS. So they have good
  15.    reason to check on the version of DOS (they originaly allow
  16.    versions of DOS 3.1 - 5.x, see following post of the
  17.    first hacker). I happen to have also Correl SCSI v 1.1 that
  18.    contains replacement for MSCDEX.EXE called CORELCDX.EXE.
  19.    It checks the version of DOS only from below (>= 3.1) but
  20.    complains about "Invalid DOS pointers found" when run under OS2 DOS
  21.    session.
  22.  
  23. 2) Then I went back to documentation and found on the page 81 of
  24.    volume 2 of famous "Red Books" small note about VCDROM and
  25.    MSCDEX. It basically says, that VCDROM virtual device driver
  26.    enables audio support for CD-ROM applications running in
  27.    virtual DOS machines. Under native DOS, audio and other IOCTL
  28.    support is provided by the pass-through function of the CD-ROM
  29.    file system driver, MSCDEX. VCDROM provides two features necessary
  30.    to support DOS CD-ROM applications:
  31.     * It emulates the presence of MSCDEX
  32.     * It translates the DOS style IOCTLs into requests that the
  33.       physical CD-ROM device driver can understand.
  34.    VCDROM provides only audio IOCTL support and not a full emulation
  35.    of MSCDEX, as most DOS CD-ROM applications use standard DOS interface
  36.    for file system services and the MSCDEX interface for audio services
  37.    only. Any application, that calls MSCDEX for file system services
  38.    WILL NOT RUN in a virtual DOS machine.
  39.  
  40. 3) That was bad news. If I may summarize - there is no hope for getting
  41.    patched version of MSCDEX servicing file requests under virtual
  42.    DOS machine (it means standard DOS session under OS2). Of course
  43.    you have file services available with proper OS2 drivers for your
  44.    equipment, but it is done in a different way, not in the style
  45.    of MSCDEX.
  46.  
  47. 4) Now for the good news - from the paragraph 2 follows, that there
  48.    was some hope at least for audio services with patched MSCDEX
  49.    (that would start and not complain about bad DOS version). So I
  50.    did exactly that - I have patched original MSCDEX.EXE to avoid
  51.    checking for DOS version. It will serve two purposes in standard
  52.    OS2 DOS session - it will positively answer to program inquiries
  53.    about the presence of "MSCDEX extansions" and it will enable
  54.    you to use your favourite program for listening audio CD's on
  55.    your CD-ROM (Trantor Musicbox, Correl CD-Audio, IBM CD Play -
  56.    almost any DOS program should work). I have also verified, that
  57.    you can play audio CD's also in Windows started in that particular
  58.    session after you have installed my  patched MSCDEX2.EXE. You
  59.    don't even have to have installed in your config.sys VCDROM.SYS.
  60.  
  61. 5) How should you install the whole thing (in case you are
  62.    interested in its limited functionality) ? It is simple:
  63.     a) First make sure that your setup works under real DOS.
  64.        That means install CD-ROM software and verify that everything
  65.        works.
  66.     b) Then for a dedicated DOS session go to its DOS Settings and
  67.        under DOS_DEVICE setting type in relevant lines from your
  68.        native config.sys that are connected with CD-ROM. Usually
  69.        it is either one line specifying device driver, or two
  70.        lines serving the same purpose, only one is so
  71.        called ASPI driver and second is true device driver.
  72.        You are supposed to type only what comes after "device="
  73.        from your native DOS config.sys, but with all switches
  74.        and parameters. That will start for that particular DOS
  75.        session relevant device drivers for communication with
  76.        your CD-ROM hardware.
  77.     c) After the session has started (or as a parameter at the
  78.        startup or in AUTOEXEC.BAT) you are supposed to start my
  79.        patched MSCDEX2.EXE.
  80.        There are only two parameters that you are supposed to
  81.        specify - first is /D:MSCD001 or something similar, which
  82.        represents the name by which MSCDEX2.EXE will recognize
  83.        your hardware device drivers. It is almost always set up
  84.        during setting things up under native DOS by installation
  85.        program. I sugest that you use the same name as whas used
  86.        under native DOS (to avoid confusion). The second parameter
  87.        that you MUST provide is /L:H where H is drive letter
  88.        that is not currently used in your system. This parameter
  89.        has in this case a very simple function - it will enable
  90.        MSCDEX2.EXE to start successfully. In case you don't provide
  91.        this parameter poor MSCDEX2.EXE goes to investigate the tables
  92.        of currently used drive letters, gets completely confused and
  93.        usually whole session is hung (rember gentle warning from
  94.        Correl SCSI software about invalid DOS pointers ?).
  95.        So you start like this
  96.          mscdex2.exe /D:MSCD001 /L:H
  97.        Don't panic when after this you will not see drive H, because
  98.        you will not. It really just helps poor guy to start - that's
  99.        it. It also means that you cannot access your CD with commands
  100.        like dir or copy, because drive letter for it simply doesn't
  101.        exist. But now you can start at least your audio CD program and
  102.        enjoy hi quality sound from your CD-ROM.
  103.  
  104. 6) Does that mean that there is no way you guys without native OS2
  105.    CD-ROM support can see files on your CD-ROM ? No, it just requires
  106.    you to go through the pain of creating "DOS from A:" session. There
  107.    you will be able to copy files from your CD-ROM to hard drive
  108.    without limits. How are you supposed to achieve that ? I have
  109.    included at the end of this file fairly good description of the
  110.    whole procedure by the guy that has successfully done it some
  111.    time ago.
  112.  
  113.  
  114.    Sorry guys for the bad news, I really tried to help you. I am
  115. happily using my setup (Trantor T13B with IBM CD_ROM I) with native
  116. OS2 support, but I know fairly well how you feel.
  117.    If you need additional help feel free to contact me via Email.
  118.  
  119.  
  120.                                          Jan Ftacnik
  121.                                     ftacnikj@fnal05.fnal.gov
  122.  
  123.  
  124. Message from the original hacker follows:
  125.  
  126.  
  127.  
  128. From bnlux1.bnl.gov!psinntp!psinntp!uunet!uunet.ca!geac!zooid!kovarski Mon Jan 18 15:46:48 1993
  129. Article: 12049 of comp.os.os2.advocacy
  130. Newsgroups: comp.os.os2.advocacy
  131. Path: bnlux1.bnl.gov!psinntp!psinntp!uunet!uunet.ca!geac!zooid!kovarski
  132. From: Mark Kovarski <kovarski@zooid.guild.org>
  133. Subject: Problems with MSCDEX and OS/2 - Solution Found.
  134. Organization: The Zoo of Ids
  135. Date: Sat, 16 Jan 1993 04:29:51 GMT
  136. Message-ID: <1993Jan16.042951.12155@zooid.guild.org>
  137. Lines: 91
  138.  
  139.  
  140. Thanks go to Gary for hacking the thing and letting everybody know.
  141. Also many thanks to George for posting it onto the network. Since
  142. many of you might be interested, here it is.
  143.  
  144. Mark K.
  145. ============================= Cut Here =================================
  146.  
  147. Date: 01-12-93 (11:10)              Number: 17692 of 17697 (Echo)
  148.   To: DENNIS POWELL                 Refer#: NONE
  149. From: GEORGE MARENGO                  Read: NO
  150. Subj: MITSUMI CD ROM & OS/2         Status: PUBLIC MESSAGE
  151. Conf: OS2 (75)                   Read Type: GENERAL (-)
  152.  
  153. DP>anyway, anybody got the thing to run in other than native dos?
  154.  
  155.  Does it use MSCDEX? If so I found a message that may be of interest,
  156. and possibly even help<g>. I know nothing of the following first hand,
  157. so treat it accordingly.
  158. ========================================================================
  159. Since Setver uses *documented* dos calls and MSCDEX uses *undocumented*
  160. dos calls, MSCDEX won't work with OS/2 except in a VDM. Or will it?
  161. What follows is part of a post I found most interesting:
  162. <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
  163. -------CUT-------CUT-------CUT-------CUT-------CUT-------CUT------------
  164.  
  165. Ok, what did I do to make it work under OS/2 2.0?  Simple, I went
  166. looking for the release level check (INT 21 Code 30) and found the
  167. following code:
  168.  MOV  AH,30
  169.  INT  21
  170.  XCHG AL,AH
  171.  CMP  AX,030A    ; Check for DOS Version 3.1
  172.  JB   3C19       ; Less < 3.1 - Fail
  173.  CMP  AX,0600    ; Check if >= Dos 6.0
  174.  JGE  3C19       ; >= 6 so fail
  175.  CMP  WORD PTR [0600],+01 ; look for list of lists
  176.  JA   3C19       ; not found, fail
  177.  JZ   3C1F       ; ???
  178.  JMP  3C97       ; OK - Do the right stuff
  179.  
  180. So, I just zapped out everything from the MOV AH,30 through the JZ 3C1F
  181. with no-ops (90).  Thus bypassing the version check.  I didn't spend the
  182. time looking for the segment of code that called this routine, so an
  183. easier zap is possible.
  184.  
  185. I've tested this with two musical CD's, using the Music Box program
  186. and did a full functional test (ff, rev, eject, play, random, etc.)
  187. Also did it with an info CD (a large shareware disk) and it worked
  188. fine.  I don't have MAMMALS with does use a mono output mode with
  189. one track to the left channel and one to the right.
  190.  
  191. --------------
  192. To run under OS/2.
  193. Change the settings on the full screen windows icon, and under devices
  194. put in the dos device driver (mine is D:\DOSTOOLS\PCD650S.SYS /M:H).
  195.  
  196. Save this and close.
  197.  
  198. Now edit AUTOEXEC.BAT, and add a line for MSCDEX2, ie:
  199. MSCDEX2 /E /V /D:MSCD001 /L:F
  200.  
  201. Now when you start Windows, the device driver will be loaded, and the
  202. MSCDEX interface.  (BTW if you start a regular dos session, MSCDEX
  203. will complain about not finding a CD-ROM driver, so you may want
  204. to re-direct the output to NUL).
  205.  
  206. I don't run seamless windows, but I'd expect you could get it
  207. to run by creating a program template for PROGMAN.EXE and changing
  208. the DEVICE entry as above.  From PROGMAN you could the open and
  209. start the MM support you wanted.
  210.  
  211. So far it works with musical CDs and CDs that don't require a
  212. formal disk drive structure in place.  I haven't gotten it to
  213. work reliably with one of my share-ware cd-roms.
  214.  
  215. I'm going to dig further into the structure this weekend and see
  216. if it really can be fixed.
  217.  
  218. Good Luck
  219.  
  220. Gary
  221.  
  222.  
  223. ====================================================================
  224.  
  225. Now message about installing CD-ROM support under specific DOS
  226. session:
  227.  
  228.  
  229. From bnlux1.bnl.gov!psinntp!psinntp!rpi!usc!sdd.hp.com!elroy.jpl.nasa.gov!swrinde!cs.utexas.edu!bcm!lib!oac.hsc.uth.tmc.edu!jmaynard Sat Nov 14 23:45:34 EST 1992
  230. Article: 38605 of comp.os.os2.misc
  231. Path: bnlux1.bnl.gov!psinntp!psinntp!rpi!usc!sdd.hp.com!elroy.jpl.nasa.gov!swrinde!cs.utexas.edu!bcm!lib!oac.hsc.uth.tmc.edu!jmaynard
  232. From: jmaynard@oac.hsc.uth.tmc.edu (Jay Maynard)
  233. Newsgroups: comp.os.os2.misc
  234. Subject: Getting the DAK $199 CDROM working with OS/2
  235. Message-ID: <7844@lib.tmc.edu>
  236. Date: 12 Nov 1992 19:28:44 GMT
  237. Sender: usenet@lib.tmc.edu
  238. Organization: UT Health Science Center Houston
  239. Lines: 72
  240. Nntp-Posting-Host: oac.hsc.uth.tmc.edu
  241.  
  242.  
  243. After a bit of hacking, I have gotten my DAK CDROM to run with OS/2 2.0. As
  244. Tim Sipples has said, it will only work in a specific DOS session, set up
  245. properly. Here's how I went about it:
  246.  
  247. 1) I built a bootable DOS floppy by running FORMAT /S on a machine running DOS
  248. 5.0. I also copied DOSKEY.EXE, SETVER.EXE and APPEND.EXE from the DOS
  249. directory on that machine to the disk, and then copied
  250. C:\OS2\MDOS\FSFILTER.SYS to it.
  251. I created a CONFIG.SYS by hand on the floppy, as follows:
  252. DEVICE=FSFILTER.SYS
  253. FILES=50
  254. BUFFERS=4
  255. LASTDRIVE=Z
  256.  
  257. 2) I booted that floppy on the OS/2 system by double-clicking the DOS from
  258. Drive A icon, and was presented with a DOS prompt.
  259.  
  260. 3) I ran the DAK INSTALL program on the CD Launcher customization disk. This
  261. stuck a bunch of files in C:\, and modified C:\CONFIG.SYS and C:\AUTOEXEC.BAT.
  262. (There's no way to tell the program to put the files elsewhere.) I then moved
  263. all the files it added to D:\CDROM (a directory name I fished out of thin
  264. air), moved the modified AUTOEXEC.BAT and CONFIG.SYS there, and renamed the
  265. previous files, saved as AUTOEXEC.OLD and CONFIG.OLD, back to the right names.
  266. The install program checks ports 300H, 310H, 320H, 340H, and 380H to see if
  267. there's hardware there before recommending which port address to use; mine
  268. locked up on me until I removed the NE2000 card that was set for port 300H
  269. from the system. Note also that the only possibilitied for the card's
  270. interrupt vector are 2, 3, and 5.
  271.  
  272. 4) I copied all of the DAK-installed files to the floppy. I then used the new
  273. AUTOEXEC.BAT and CONFIG.SYS files, as modified by DAK, to build the following
  274. files:
  275.  
  276. CONFIG.SYS:
  277. DEVICE=FSFILTER.SYS
  278. DEVICE=C:\OS2\MDOS\HIMEM.SYS
  279. DOS=HIGH,UMB
  280. DEVICEHIGH=SETVER.EXE
  281. DEVICEHIGH=MTMCDSA.SYS (parameters as supplied by the INSTALL program)
  282. FILES=50
  283. BUFFERS=4
  284. LASTDRIVE=Z
  285.  
  286. AUTOEXEC.BAT:
  287. @ECHO OFF
  288. MSCDEX (parameters as supplied by INSTALL)
  289. PATH A:\;(rest of path as supplied by OS/2)
  290. PROMPT (as supplied by OS/2)
  291. LOADHIGH DOSKEY (parameters)
  292. LOADHIGH C:\OS2\MDOS\MOUSE
  293.  
  294. While arriving at this configuration, I ran into various problems with illegal
  295. instruction traps, bad or missing drivers, MSCDEX complaining about bad DOS
  296. versions, and so on; all of those went away when I used VMDISK to build a
  297. bootable image in D:\CDROM and booted from that. I have not tried turning
  298. HW_ROM_TO_RAM on for the DOS from Drive A: object, but I plan to try that when
  299. I get home.
  300.  
  301. At this point, I had a running DOS 5.0 session that I could use to run CD
  302. software and so forth. The CDROM is accessible as drive S: in that session.
  303. The DiscPassage search software that came with The Family Doctor CDROM works
  304. just fine. Unfortunately, the same cannot be said for the Microsoft Bookshelf:
  305. the MSL program used to access the library blows up every time, with an
  306. illegal instruction trap.
  307.  
  308. Hopefully, this will get others pointed down the right track towards getting
  309. their DAK $199 CDROM packages going. Good luck!
  310. --
  311. Jay Maynard, EMT-P, K5ZC, PP-ASEL | Never ascribe to malice that which can
  312. jmaynard@oac.hsc.uth.tmc.edu      | adequately be explained by stupidity.
  313.      We survived Jimmy Carter; we'll (probably) survive Bill Clinton.
  314.