Mail Archives: djgpp/2001/06/18/05:00:22
From: | "Giovanni Ceglia" <giovanniceglia AT inwind DOT it>
|
Newsgroups: | comp.os.msdos.djgpp
|
Subject: | problem with asm
|
Date: | Mon, 18 Jun 2001 09:31:49 +0200
|
Organization: | Wind Telecomunicazioni S.p.A.
|
Lines: | 88
|
Message-ID: | <9gkb0v$gsc$1@nreadB.inwind.it>
|
NNTP-Posting-Host: | 62.98.182.66
|
X-Trace: | nreadB.inwind.it 992849759 17292 62.98.182.66 (18 Jun 2001 07:35:59 GMT)
|
X-Complaints-To: | abuse AT inwind DOT it
|
NNTP-Posting-Date: | 18 Jun 2001 07:35:59 GMT
|
X-Priority: | 3
|
X-MSMail-Priority: | Normal
|
X-Newsreader: | Microsoft Outlook Express 5.00.2314.1300
|
X-MimeOLE: | Produced By Microsoft MimeOLE V5.00.2314.1300
|
To: | djgpp AT delorie DOT com
|
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp
|
Reply-To: | djgpp AT delorie DOT com
|
Hello all, i write because i ' ve some problems with mingw/cygwin and DevC++
compilers.
I operate with IDE tool called Dev C++, i 'm tring to do som graphic
function, but i encountered a lot of problems, i never had with others
compiler.
I ' tryed to write my function in assembler, but i don't know why, the
system go in crash, when i run it.
The function is very simple, it call BIOS interrupt 10h
what i must do is that:
AX=13h
INT 10h
With Intel Assembly i can do it with:
mov ax,013h
int 10h
With Assembley used by DevC++/Mingw/CygWin i tried that:
void vga( )
{
__asm__("
movb $0x00,%ah /n
movb $0x13,&al /n
int $0x10 /n
");
}
The system compile, but program go in irreversible crash on Windows 95 ( I
have Win 95 installed ).
So i tried also:
void vga( )
{
asm (".byte 184,19,0,205,16");
}
The system compile, but program go in a reversible crash, but however is
crash.
I studyed a lot the problem and i discovered who could be possible resolve
this my problem with a complete C sintax with the library "dmpi.h".
void vga()
{
__dpmi_regs rg;
rg.x.ax = 0x13;
__dpmi_int(0x10, &rg);
}
void txt()
{
__dpmi_regs rg;
rg.x.ax = 0x03;
__dpmi_int(0x10, &rg);
}
I searched for this lib into system libraries directory but i didn't found
it!
So my question is, how can i realize with DevC++/Mingw/Cygwin compiler
operation AX=13h and Int 10h?
Where can i found dmpi.h library?
Is it possible to do the same things with system libraries?
Thanks if anyone can tell me about this problems.
--
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Giovanni Ceglia
WebMaster & WebDesigner
http://www.xungame.com/
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Raw text -