954,479 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

How could I break an infinite loop??

Hi guys again,
If I have an infinite loop for example:

MOV CX, 240
           MOV DX, 320
 
HERE:  MOV AH, 2CH
           INT 21H
           CMP DH, 1
           JE DOT
           MOV AX, 0C00H
           INT 10H
DOT:    MOV AX, 0C04H
            INT 10H
            JMP HERE


In the example I have an infinite loop. I want to break this, however, I don't want to stop it functionality ( plups every 60 seconds) ...

int 21, ah = 01 will stop the loop untill you press any key.
As I said I don't stop the loop, I wanna keep it working untill someone press ESC for example...

So, if any idea please tell me about it.
Thanks in advance

eeeraser
Newbie Poster
22 posts since Apr 2007
Reputation Points: 10
Solved Threads: 0
 

Indispensable reading.
http://www.cs.cmu.edu/afs/cs/user/ralf/pub/WWW/files.html

Int 16/AH=01h perhaps.

Salem
Posting Sage
Team Colleague
11,531 posts since Dec 2005
Reputation Points: 5,862
Solved Threads: 953
 

Thanks, it works Int 16, Ah = 01
I have witten this code in my program and it works

START:  MOV AH,01
 INT 16H
 CMP AL, 0DH
 JNE GOAGAIN
 POP AX
 MOV AH, 00H
 INT 10H
 MOV AX, 4C00H
 INT 21H
 
GOAGAIN: mov ah,02
              INt 1Ah
                 -
                 -
                 -
to the end of the loop and it comes again back to START.


Thanks man alot.

eeeraser
Newbie Poster
22 posts since Apr 2007
Reputation Points: 10
Solved Threads: 0
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You