Reputation: 395
I'm working with emu8086, in a source code I've found this line at the top:
include 'emu8086.inc'
and this line in the end:
DEFINE_SCAN_NUM
I know that scan num is a part of emu8086.inc, and I opened up the inc file with an editor but still can't figure out what does exactly scan_function do?
Upvotes: 1
Views: 5779
Reputation: 11
To use scan_num
, we need to declare DEFINE_SCAN_NUM
before END
. And scan_num
procedure helps us to take input from keyboard.
Upvotes: 1
Reputation: 43698
It reads a number between -32767 and 32767 and returns it into CX, using BIOS functions for keyboard input and display of the number.
(Actually, it will accept the -
sign at any position, not only at the start).
Upvotes: 4