[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

int 16h without wait for keypress

Posted on 1998-05-26
1
Medium Priority
?
436 Views
Last Modified: 2011-10-03
I don't know how to make program for keyboard that wont wait for key to be pressed.
prg. that I have : mov ah,0
                            int 16h
That prg. waits until one key is pressed, but I need to run something paralel with this.
0
Comment
Question by:ssdjgru1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 2

Accepted Solution

by:
kellyjj earned 800 total points
ID: 1217040
if you only call that code when there is a key actually pressed you should not be waiting.  
If you need other things to be done while waiting for this this is one way of doing it:

while (not done)
begin
   if (vec=2)
   begin
       dosomething;
   end
   if (vec=3)
   begin
       dosomething;
   end
   if (vec=4)
   begin
       dosomething;
   end
   if (vec=5)
   begin
       dosomething;
   end
   if (vec=6)
   begin
       dosomething;
   end

   if keypressed  getKey();  (* this is the assembler code *)
end


This is called Vectorizing.  This will allow you to do other things while you are waiting for a key to be pressed.  Keep in mind that you don't want to get stuck waiting for anything inside that loop.

Hope this helps.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If something goes wrong with Exchange, your IT resources are in trouble.All Exchange server migration processes are not designed to be identical and though migrating email from on-premises Exchange mailbox to Cloud’s Office 365 is relatively simple…
With so many activities to perform, Exchange administrators are always busy in organizations. If everything, including Exchange Servers, Outlook clients, and Office 365 accounts work without any issues, they can sit and relax. But unfortunately, it…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question