Mail Archives: djgpp/1998/11/03/18:55:29
Here's the answer to your first one:
Because DJGPP doesn't accept the Intel asm syntax, you have to write it in
AT&T syntax. Therefore:
mov dx,3DAh
l1:
in al,dx
and al,08h
jnz l1
l2:
in al,dx
and al,08h
jz l2
becomes
asm("
movw $0x3da, %dx;
l1:
inb %dx, %al;
andb $0x8, %al;
jnz l1;
l2:
inb %dx, %al;
andb $0x8, %al;
jz l2;
);
The 2nd one, look up the faq at the DJGPP website on mode 13h. They'll tell
you every thing there.
tbelius AT algonet DOT se wrote in message <363f3376 DOT 1676539 AT news DOT algonet DOT se>...
>I need help with 2 things:
>
>1. I need to convert this asm code for waiting for the vertical
>retrace converted to a function that djgpp accepts.
>I am trying to learn asm but i havnt come so long
>that i can do it myself. I did notice one thing thow.
>Are the in al,dx instructions valid? The lx and dx
>regs are of different size right?
>What does the in intruction do anyway?
>Can you use this function under windows?
>
>mov dx,3DAh
>l1:
> in al,dx
> and al,08h
> jnz l1
>l2:
> in al,dx
> and al,08h
> jz l2
>
- Raw text -