Originally posted by penghuahui at 2007-12-16 11:27 PM:
汇编?
可以讲解一下吗?
com文件:
按键输入可见字符的(包括空格)都显示一个*号,并同时向以0:201h开始的内存地址空间写入该字符;是退格键时就只是把上一个显示的*号换成空格,下次这个空格可能被新输入的可见字符覆盖(如果按退格键时前面没有*号就什么也不做);是回车键时就结束输入过程,并把字符串的长度写入0:200h。
批处理执行完com文件后就用debug把从0:200h到0:220h的数据写到文件中,根据字符串的长度获得原始输入数据并显示出来。
Last edited by s11ss on 2007-12-17 at 09:31 AM ]
Originally posted by penghuahui at 2007-12-16 11:27 PM:
Assembly?
Can you explain it?
COM file:
For visible characters (including spaces) entered by pressing keys, display an asterisk (*) and simultaneously write the character to the memory address space starting at 0:201h; when the backspace key is pressed, only replace the previous asterisk with a space, and this space may be overwritten by a newly entered visible character next time (if there is no asterisk before pressing the backspace key, do nothing); when the enter key is pressed, end the input process and write the length of the string to 0:200h.
After the batch processing executes the COM file, use debug to write the data from 0:200h to 0:220h to a file, obtain the original input data according to the length of the string and display it.
Last edited by s11ss on 2007-12-17 at 09:31 AM ]