I’m trying to use the debug tool in windows to for a simple program. I want to input a string of characters and then inspect the memory to see the characters saved.
Here’s the code I have:
mov bx,200
mov byte [bx],33 ;; Set maximum string length (32 + Ent)
mov ah, 0Ah
int 21h
Every time I assemble the code and run it, it lets me input the string and then DEBUG automatically quits. This my first time ever using it so I’m not sure what the problem is.
Any help/tips would be greatly appreciated.
Thanks!
Function 0Ah expects the buffer address in DS:DX, your code only sets up BX, never DX.
Here’s how I type the code in:
Here’s what I get:
Here’s what’s in the registers:
Next I just use the “proceed” command to execute the code instruction by instruction:
Then type in “QWE” followed by enter:
Done. And here it is in the memory: