delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/09/10/13:12:54

Date: Thu, 10 Sep 1998 20:11:54 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: djgpp AT delorie DOT com
Subject: Re: More Q's about IRQs
In-Reply-To: <35F7E365.A765E58A@res.raytheon.com>
Message-ID: <Pine.SUN.3.91.980910200028.10176A@is>
MIME-Version: 1.0

On Thu, 10 Sep 1998 default AT is DOT elta DOT co DOT il wrote:

> > Interrupt-driven transmitting is tricky.  Please post the code that
> > initializes the UART, the key to this mystery might be there.
> 
>  The big problem is not the Initialization, everything works fine in real
> mode

The fact that it works in real mode is, in my opinion, no proof that your 
problem is indeed in how you hook the PM interrupt.  Since the interrupts 
begin to work once you read the UART, it seems like the interrupt is 
hooked okay anyway.

DJGPP differs from real-mode compilers in other ways, beyond the 
protected mode issue.  It can well be that one of these differences make 
your initialization code not work when compiled with DJGPP.  That is why 
I asked to see the initialization code.

Of course, it is up to whether you need help badly enough to post that 
code.

> It just seems like there is some subtle point that I'm missing in declaring
> the PM interrupt. Maybe my main loop is performing a mode switch somewhere?

The loop that you posted does a mode switch inside `kbhit' and again 
inside `delay'.

But don't worry about mode switches: the interrupts are always reflected 
to your protected-mode handler, even if the interrupt happens while the CPU 
is in real mode.  So this shouldn't be your problem.

- Raw text -


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