Re: Boot sector problems...



spamtrap@xxxxxxxxxx wrote:
Hello all,
I am having very odd, peculaiar and strange problems with my
bootsector. I do not know how to explain the problem since it seems to
be illogical, but when I comment out two lines of source code,
everything works fine.
The lines commented out are:
;Begin ASM Code
cmp bl,0x04
jne cont
;End ASM code

It's actually the "inc bl" that's killin' ya. Without these lines, it gets set back to zero every time. Since the buffer for the sector read is es:bx, we really don't want bx changing... If you use di as the index into prog...

.....
mov bx,0
xor di, di
pop si
read_sector_anim:
pusha
mov ah,0x02
mov dh,12
mov dl,51
int 0x10
popa
inc bl
inc di
cmp di, 4
jne cont
;cmp bl,0x04
;jne cont
mov bl,0
xor di, di
cont:
pusha
mov ah,0x0A
mov al,[prog+bx]
mov al, [prog + di]
.....

This seems to bring back the 'e'. Whew!

Best,
Frank

.



Relevant Pages

  • Re: More bits: and, NOT operation
    ... I need some help interpreting the following 8088 .asm code: ... mov al, value;move somthing stored in "value" to al ... al;result of middle instruction out I/O at dx ... DATA equ 00000001b ...
    (comp.lang.asm.x86)
  • Re: running asm code from heap
    ... Im generating asm code runtime, the generated asm code is stored on ... I do not have Windows Server 2008 nor Delphi7. ... mov(w.MEM_RESERVE, eax); ...
    (comp.lang.asm.x86)
  • Re: More bits: and, NOT operation
    ... I need some help interpreting the following 8088 .asm code: ... mov al, value;move somthing stored in "value" to al ... al;result of middle instruction out I/O at dx ... code equ 1; 00000001 ...
    (comp.lang.asm.x86)
  • Re: RDTSC code timing
    ... mov TT1,edx; ... are all equal to 0, as if asm code did not execute, or mov ... instruction in the code did not execute. ... then the `popa` clobbered them. ...
    (alt.lang.asm)