During the loop, my 8086 build programs have a threshold for pressing the keyboard key if you press the key too many times when the PC speaker starts to sound. This is unpleasant, and it slows down my programs to crawl, since the processor must bounce off my program and spend half a second driving the speaker.
I didn’t even know that this problem exists until a few months ago I started testing my programs on real hardware. This problem is not a problem in DosBox or even in Dos 6.22 installed inside DosBox. So it must be some kind of low-level hardware interrupt built into the BIOS for the PC, I don’t know too much about it.
This happens on my 286 machine and my Pentium mmx laptop, regardless of operating system.
Even if it’s just a dead loop, and I haven’t even tried to enter from the keyboard, the beep will still happen if I press too many keys
I tried to wrap only my input code inside cli and sti, in order to hope for masking keyboard input, but this does not work. I collect scancode only at a specific point in my program, so the rest of the interrupt time is allowed. Thus, an audio signal can still occur in the vast majority of cases.
There must be some kind of hardware register that I can disable or something like that. I scanned the Boch ports list ( http://bochs.sourceforge.net/techspec/PORTS.LST ) well, looking for something like this, but didn't see anything.
Maybe I can just disable the interrupt? I guess many build programmers must have encountered this problem, but Google really doesn't help me at all here.
assembly interrupt x86-16 pc
My life is a bug.
source share