1 byte (int) --> 2 (char)
Posted: Wed Apr 10, 2002 11:00 pm
Hello,
I've got an algorithm that changes 1 byte int
to 2 byte char...
pre-condition: al := converting content
post-condition: ah == higher byte, al == lower byte
---- this is the code ----
pusha
mov ah,0x00
mov al,a
aam
or al,0x30
mov a,al
or ah,0x30
mov b,ah
popa
---- END ----
Ben Hsu
I've got an algorithm that changes 1 byte int
to 2 byte char...
pre-condition: al := converting content
post-condition: ah == higher byte, al == lower byte
---- this is the code ----
pusha
mov ah,0x00
mov al,a
aam
or al,0x30
mov a,al
or ah,0x30
mov b,ah
popa
---- END ----
Ben Hsu