comp.lang.ada
 help / color / mirror / Atom feed
From: Marin David Condic <nobody@noplace.com>
Subject: Re: Keyboard Polling Solution
Date: Fri, 20 Feb 2004 12:15:40 GMT
Date: 2004-02-20T12:15:40+00:00	[thread overview]
Message-ID: <4035FA69.1060301@noplace.com> (raw)
In-Reply-To: 40354027.C7D28149@mchsi.com

Well, there you go! I have not messed with any keyboard input in so long 
I'd completely forgotten about that. But yes, that looks like it would 
do the job.

I'd be curious why you want to poll. Usually, one tries to avoid that, 
but I know I've wanted something going on in the background that might 
stop when the user hit a key. The usual trick would be to have a task 
looking at keyboard input with another task doing the background job. 
Sometimes this wouldn't work with some implementations because the I/O 
operation didn't flag the task as "blocked", so the background would 
starve. Then you might want to resort to some kind of polling.

MDC

Bruce or Tracy Jacobs wrote:
> A version of Get_Immediate does this.  If there is nothing in the
> buffer, it returns
> FALSE and lets you continue on.  
> 

-- 
======================================================================
Marin David Condic
I work for: http://www.belcan.com/
My project is: http://www.jsf.mil/NSFrames.htm

Send Replies To: m   o   d   c @ a   m   o   g
                    c   n   i       c   .   r

     "Face it ladies, its not the dress that makes you look fat.
     Its the FAT that makes you look fat."

         --  Al Bundy

======================================================================




  reply	other threads:[~2004-02-20 12:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-02-18 21:37 Keyboard Polling Solution Me
2004-02-18 23:10 ` Preben Randhol
2004-02-19  0:30   ` Bruce or Tracy Jacobs
2004-02-19 11:47   ` Marin David Condic
2004-02-19 22:57     ` Bruce or Tracy Jacobs
2004-02-20 12:15       ` Marin David Condic [this message]
2004-02-20 20:59         ` Chad R. Meiners
2004-02-22 21:26         ` Bruce or Tracy Jacobs
2004-02-23 10:40           ` Preben Randhol
2004-02-25  0:44             ` Bruce or Tracy Jacobs
2004-02-25  2:05               ` Chad R. Meiners
2004-03-03 16:20                 ` Me
2004-02-20 21:38 ` Warren W. Gay VE3WWG
2004-02-22 21:30   ` Bruce or Tracy Jacobs
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox