1
I’m trying to record a 40x20 character array, doing 2 cycles, where the character reads the character guard in a buffer, but I know we have to add 13.10 to change line and the cursor goes back to the beginning. But 13.10 is considered one byte? How can I add 13.10 at the end of the line or after reaching the last character of the line.
Part of the code
xor cx,cx
xor si,si
xor ax,ax
mov cx, 20
forLine:
forColumn:
mov ah, 08h ; Guarda o Caracter que est� na posi��o do Cursor
mov bh,0 ; numero da p�gina
int 10h
mov caraterLido, ah
mov buffer[SI], caraterLido
inc si
cmp si, 40
jne forColumn
//quando for igual a 40, adicionar 13 e 10 no fim da linha
loop forLine
It wouldn’t be: mov buffer[SI], $A inc si mov buffer[SI], $D ?
– Reginaldo Rigo
@Reginaldorigo because the $A and $D?
– jorge saraiva
I meant 10 and 13 in Hexa, but that’s in Delphi. Now I think in Assembly the correct would be: mov buffer[SI], 0AH inc si mov buffer[SI], 0DH
– Reginaldo Rigo