Hi Wolfgang,
That piece of code is an unused artifact from a previous version.
For those interested, bin2hex is a simple routine to convert the
value in eax to a hexadecimal number in a buffer pointed to by esi,
ecx is the number of digits to convert.
bin2hex:
push edx
mov edx, eax
lea esi,[esi+ecx-1] ; start with least significant digit
.1:
mov al, dl
shr edx, 4
and al, 0Fh
add al, '0'
cmp al, '9'
jbe .2
add al, 7
.2:
mov [esi], al
lea esi, [esi-1]
sub ecx, 1
jnz .1
pop edx
ret
> btw Mike, why you don't like INC DEC ? :)
They remind me of real mode code, (I also don't like the string
instructions). I'm waging a personal war against real mode
programming. With aeBIOS access to BIOS functions in 32 bit
protected mode is simple and easy.
Mike Gonta
look and see - many look but few see