home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / os / msdos / programm / 8625 < prev    next >
Encoding:
Internet Message Format  |  1992-08-19  |  2.1 KB

  1. From: dubner@hpspkla.spk.hp.com (Joe Dubner)
  2. Date: Wed, 19 Aug 1992 15:10:34 GMT
  3. Subject: Re: How to detect base address of COMx ports?
  4. Message-ID: <29820002@hpspkla.spk.hp.com>
  5. Organization: Hewlett Packard Company, Spokane, Wa.
  6. Path: sparky!uunet!charon.amdahl.com!pacbell.com!mips!sdd.hp.com!hp-cv!hp-pcd!hpspkla!dubner
  7. Newsgroups: comp.os.msdos.programmer
  8. References: <LUBKT.92Aug17132854@synergy.CC.Lehigh.EDU>
  9. Lines: 34
  10.  
  11. lubkt@synergy.CC.Lehigh.EDU (Binod Taterway) writes:
  12.  
  13. > I am writing a software that dials various computers using a comm
  14. > package. In order to dial thru a particular, I need to know the base
  15. > address of the serial port. For COM1 and COM2, base addresses are set
  16. > to 0x3F8 and 0x2F8, respectively. For the rest of the ports, their
  17. > addresses are highly dependent on the vendor. So right now, I ask my
  18. > users to specify this address and the interrupt level if they are
  19. > using ports such as COM3 and COM4. Many of these users are too naive
  20. > to understand what these two terms and have hard time looking up the
  21. > manual. Is there any way, via some interrupt routine or the like, to
  22. > determine how many ports are available and their base addresses and
  23. > interrupt levels. Is it stored anywhere on the system?
  24.  
  25. MS-DOS stores the serial port base addresses at 0:400, 0:402, 0:404, and
  26. 0:406 for COM1 through COM4.  (Parallel port base addresses are also
  27. stored, starting at 0:408.)  Using DEBUG, take a look at this area with
  28. a "d 0:400" command.  Note that DOS has to "know" about COM3 and COM4 --
  29. I'm not certain how it "finds out" about them, particularly if they're
  30. at non-standard I/O addresses.  And support for COM3 and COM4 was not
  31. present in earlier versions of DOS.
  32.  
  33. As for interrupts, sorry, but I don't have any ideas for you.  I'm of
  34. the opinion that you're up against a brick wall here.
  35.  
  36. Regards,
  37. Joe
  38.  
  39. ---------------------------------------------------------------------------
  40. Joe Dubner   K7JD  |  Hewlett Packard Company  |  dubner@hpspkla.spk.HP.COM
  41.                    |  TAFC-34         M.S. 2I  |
  42.                    |  Spokane, WA  99220       |  (509) 921-3514
  43. ---------------------------------------------------------------------------
  44.  
  45.