int 16h without wait for keypress

Posted on 1998-05-26
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.
Question by:ssdjgru1
1 Comment

Accepted Solution

kellyjj earned 200 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)
   if (vec=2)
   if (vec=3)
   if (vec=4)
   if (vec=5)
   if (vec=6)

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

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.

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

SEO can be a real minefield to navigate, but there are three simple ways to up your SEO game just be re-assessing your content output.
Employees depend heavily on their PCs, and new threats like ransomware make it even more critical to protect their important data.
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.

815 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now