delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/10/20/09:03:23

From: daghakmy AT login DOT eunet DOT no (Dag Håkon Myrdal)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Using inportb() (thanks)
Date: 20 Oct 1997 10:56:12 GMT
Organization: EUnet Norway
Lines: 32
Message-ID: <62fdcc$iva$1@elle.eunet.no>
References: <Pine DOT SUN DOT 3 DOT 91 DOT 971015131204 DOT 17868I-100000 AT is>
NNTP-Posting-Host: login.eunet.no
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

In article <Pine DOT SUN DOT 3 DOT 91 DOT 971015131204 DOT 17868I-100000 AT is>,
Eli Zaretskii  <eliz AT is DOT elta DOT co DOT il> wrote:
[...]
>You use `outportb' incorrectly: it requires a second argument--the
>value being written to the port.  The way you used it, it writes some
>random value (whatever it finds on the stack), which will certainly
>not work.

Sorry - that was just a bug in my example - not the program itself.

[...]
>> To me, the only obvious difference here is that I no longer 
>> explitly ask for access to the IO bus - is this not necessary with
>> djgpp?
>
>No, at least as long as you use it under MS-DOS.

Thanks for that info.
What had happened actually was this:
I had tried 2 different cards, both reported an error reading from
the card, after which I assumed there had to be something wrong with my
code. 
Reading your advice, I tried a third card...
It turned out I had a hardware problem with two cards, the third one
working correctly!


Best regards,


Dag Håkon Myrdal

- Raw text -


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