Mail Archives: djgpp/1997/09/23/22:37:29
> asm("movb %ah,$0;
> movb %al,$0x13;
> int $10");
> I get a error message: "operators given don't match any 380 instruction"
> from assembler (as.exe).
Your back to front - your mixing syntax's - your operands move from left
to right, not the Intel format of right to left, so your code should be:
movb $0, %ah; // put value of 0 in register ah
movb $0x13, %al; // put hex 13 into al
int $10; // call interrupt 10
(Why not just movw $0x13, %ax; ?)
> Same days ago, I did't get any error... and I don't want to use <dpmi.h>
> If I write "movb %ah, 0" instead of "movb %ah,$0", i don't get any error,
> but my program don't change the graphic mode.
> What happen???
Because you saying move the register ah to memory location 0... which should
have crashed under cwsdpmi (no?) but I'll assume your using Win95 which
couldn't care less (NT would have cracked a sad as well)
Leathal.
- Raw text -