delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/04/29/19:21:37

From: "Rafal Maj" <maj_rafal AT poczta DOT onet DOT pl>
Newsgroups: comp.os.msdos.djgpp
Subject: Assembler smal question
Date: Sun, 29 Apr 2001 23:04:24 +0200
Organization: Academic Computer Center CYFRONET AGH
Lines: 27
Message-ID: <9chviu$1ps$1@info.cyf-kr.edu.pl>
NNTP-Posting-Host: d-94-53-01.cyfronet.krakow.pl
X-Trace: info.cyf-kr.edu.pl 988578206 1852 149.156.1.161 (29 Apr 2001 21:03:26 GMT)
X-Complaints-To: news AT cyf-kr DOT edu DOT pl
NNTP-Posting-Date: Sun, 29 Apr 2001 21:03:26 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2615.200
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

I have only one small question about assembler. I'm using modem, so I  REALY
can't read online documentation or FAQ for DJGPP.

How can I write code like this :

mov AX,0x10
int 0x13

I want to use assembler direct inside my C++ functions like:
int main() { _asm { mov AX,0x10 } }

How can I fill memory from A000:0000 to A000:0FFF with pattern of increasing
bytes ? Something like this :

mov cx,0x0FFF
xor dl,dl
begin :
mov bx:cx, dl
inc dl
dec cx
loop begin

I know that this example probably has some bugs (I'm newbie to assembler ;)

Thanks in advice.


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019