I am new to assembly and creating a program that takes a value in the AX register, say F43A, and converts it to its ascii string in decimal.
For instance, AX = 8EFFh would print out -28929. (Convert 2s complement to ascii)
I am having trouble with comprehending the registers. Do I have to convert the AX register to decimal first, or is that implied that if AX = 000Ah in hex that AX is also equal to 10 in decimal.
So does
mov AX,000Ah
cmp AX,10
work?
Any help would be appreciated. We will be using the reduction of powers algorithm, which will be based off the decimal value of AX. Though the input value of AX will be in Hex.
If that doesn't work, how would I get the decimal value out of AX?