www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/09/03/08:30:31

From: rjvdboon AT cs DOT vu DOT nl
Newsgroups: comp.os.msdos.djgpp
Subject: Re: reading/writing to COM ports
Date: 3 Sep 1998 11:02:18 GMT
Organization: Fac. Wiskunde & Informatica, VU, Amsterdam
Lines: 29
Message-ID: <6slsvq$8t7$1@star.cs.vu.nl>
References: <Pine DOT SUN DOT 3 DOT 91 DOT 980830183518 DOT 20257w-100000 AT is> <35E9747E DOT B7AEDED7 AT unb DOT ca> <35ec4a73 DOT 10588573 AT news DOT pcn DOT net>
NNTP-Posting-Host: sloep24.cs.vu.nl
User-Agent: tin/pre-1.4-980730 (UNIX) (SunOS/5.5.1 (sun4u))
Originator: rjvdboon AT sloep24 DOT cs DOT vu DOT nl
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

NGO DINH Nhan <nngodinh AT pcn DOT net> wrote:
> On Sun, 30 Aug 1998 12:49:18 -0300, Endlisnis <s257m AT unb DOT ca> wrote:
>>I'm quite sure that won't work, because I have a 'WinModem'. I've
>>never been able to get it to work from DOS. It doesn't use a
>>standard address (like 0x110 or something).

> I think you should look at the Ralf Brown Interrupt List if you want
> to go directly to read ports and get IRQ calls.
>
[snip - RalphBrown Interrupt list - snip]
>
> And it means that you can modify the default COM1 port IO addres by
> putting in 0040h:0000h the right value. The same thing is for COM2,
> COM3 and COM4, that can be modified by putting the right value in the
> address 0040h:0002h for COM2, and just add 2 to the offset for the
> other 2 ports (DJGPP in flat mode need to have 400h, 402h, 404h,
> 406h).

Note however that you can't count on the BIOS doing the right thing. I
have some (very recent) motherboard/BIOS/S3 graphics-card combinations
which put the COM4 address (if there's no COM3) at 40:04 (the place of
COM3). I had to create a debug script that manually updated that area
to make some programs work with the modem.

hth,
 Robert
-- 
rjvdboon AT cs DOT vu DOT nl        | "En dat is niet waar!" sprak ex-Staatsecretaris-
www.cs.vu.nl/~rjvdboon   |    van-onderwijs Netelenbos fel.
href=3D"mailto:dotproduct AT usa DOT net">dotproduct AT usa DOT net</A><BR>Spectrum=20
Innovations<BR><A=20
href=3D"http://www.itv.se/~a1066/spectrum">http://www.itv.se/~a1066/spect=
rum</A><BR></DIV>
<BLOCKQUOTE=20
style=3D"BORDER-LEFT: #000000 solid 2px; MARGIN-LEFT: 5px; PADDING-LEFT: =
5px">
    <DIV>jud<JUD AT TMINET DOT COM> wrote in message &lt;<A=20
    =
href=3D"mailto:6sl05n$e8h$1 AT supernews DOT com">6sl05n$e8h$1 AT supernews DOT com</A>=
&gt;...</DIV>
    <DIV><FONT face=3D"Courier New" size=3D2>
    <P>I keep getting an error on this function, any ideas?&nbsp;</P>
    <P>&nbsp;</P>
    <P>void vganorm() {</P>
    <P>__dpmi_regs r;</P>
    <P>r.x.ax =3D 3;</P>
    <P>__dpmi_int(0x10, &amp;r);</P>
    <P>}</P></FONT></DIV></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0027_01BDD700.A7EC6060--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019