From: "Michael Duxbury" Newsgroups: comp.os.msdos.djgpp Subject: Re: assembler probs Date: Sat, 24 Mar 2001 20:10:01 -0000 Organization: BT Internet Lines: 52 Message-ID: <99iuvh$cbn$1@uranium.btinternet.com> References: <99dc06$p3b$1 AT uranium DOT btinternet DOT com> <99g2bn$dtt$4 AT ctb-nnrp2 DOT saix DOT net> NNTP-Posting-Host: host213-122-227-129.btinternet.com X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Thanks for the replys. I am just learning a bit of assembler within C. My code may not really be efficient or have any practical use other that helping me learn. the problem i get flagged for is a parse error before hello. Which means the syntax is wrong I think. I changed the syntax to resemble this:- hello: .ascii "Hello, world!", but still same problem. How can I just insert this string as I would in other assembly progs. Thanks. "Stefan Viljoen" wrote in message news:99g2bn$dtt$4 AT ctb-nnrp2 DOT saix DOT net... > > Michael Duxbury wrote in message > news:99dc06$p3b$1 AT uranium DOT btinternet DOT com... > > I am trying to compile this but get a slight problem with the hello: db > > void drawline(int x1,int x2, int y, char color) > > { > > asm (" movb %ax , 0xa000"); > > } > > > > Anyone help me out please? > > If you want to use the above to access video RAM, it won't work (I think!) > What you need is a > descriptor to video RAM - you cannot use segment addresses in a segment > register to attempt to access video RAM like you can do in real mode. See > http://home.intekom.com/rylan/ for some simple assembler examples (using > NASM) of how to access 320x200x256 VGA at the VGA video segment under DJGPP > + NASM. (NASM is a freeware assembler that accepts intel syntax assembly and > outputs DJGPP compatible COFF format object files that DJGPP can link and > use). > > Regards, > > Stefan Viljoen > F/EMS Dispatcher > Potchefstroom F/EMS > South Africa > http://home.intekom.com/rylan/ > > >