27089 total geeks with 3528 solutions
Recent challengers:
 Welcome, you are an anonymous user! [register] [login] Get a yourname@osix.net email address 

Articles

GEEK

User's box
Username:
Password:

Forgot password?
New account

Shoutbox
timsattemme
<ul><li><str ong><a href="http:/ /www.ywjx8.c om/">cheap wedding dresses</a>< /strong> </l i><li><stron g><a href="http:/ /www.ywjx8.c om/">Sexy Beach Wedding Dresses Sale</a></st rong> </li>< li><strong>< a href="http:/ /www.ywjx8.c om/">cheap wedding dresses</a>< /st
timsattemme
[b][url=http ://www.watch esiphone5.co m/]replica o<strong><a href="http:/ /www.watches iphone5.com/ ">replica omega watches</a>< /strong> <br > <strong><a href="http:/ /www.watches iphone5.com/ ">replica cartier watches</a>< /strong> <br >
timsattemme
<strong><a href="http:/ /www.watches iphone5.com/ ">cartier watches</a>< /strong> | <strong><a href="http:/ /www.watches iphone5.com/ ">rolex watches</a>< /strong> | <strong><a href="http:/ /www.watches iphone5.com/ ">omega watches</a>< /strong> <br > <title>Longi
timsattemme
[b][url=http ://www.copyr olexdaytona. com/]rolex new 2013[/url][/ b] [b][url=h ttp://www.co pyrolexdayto na.com/]role x basel[/url][ /b] [b][url=http ://www.copyr olexdaytona. com/]rolex Y<br><strong ><a href="http:/ /www.copyrol exdaytona.co m/">rolex new 2013</a></st
timsattemme
<br><strong> <a href="http:/ /www.copyrol exdaytona.co m/">rolex new 2013</a></st rong> <stron g><a href="http:/ /www.copyrol exdaytona.co m/">rolex basel</a></s trong> <br>< strong><a href="http:/ /www.copyrol exdaytona.co m/">rolex Yacht-Master II</a></stro ng> <br><b

Donate
Donate and help us fund new challenges
Donate!
Due Date: Oct 31
October Goal: $40.00
Gross: $0.00
Net Balance: $0.00
Left to go: $40.00
Contributors


News Feeds
The Register
SKYPE has the HOTS
for my NAKED WIFE
Time to test your
sarcasm detectors:
It"s the UN"s
global comms
shakeup
extravaganza!
Wanna see how
Russia et al hope
to shape the
internet? ITU opens
up (a little more)
t
Google CEO Larry
Page gives Sundar
Pichai keys to the
kingdom
Cheapo telcos fined
for their cheapo
security: Financial
records on 305,000
people spill
LG taps TSMC to
bake its first-ever
mobile chip
FCC: You"ll have to
wait even longer
for faster wireless
broadband
Breaking news:
Google exec in
terrifying SKY
PLUNGE DRAMA
Revealed: The
amazing magical
innovation in the
iPad Mini 3 ? a
lick of paint
Silicon Valley
scrooges paid staff
$1.21 an hour in a
122-hour week
Slashdot
Peter Kuran:Visual
Effects Artist and
Atomic Bomb
Archivist
OwnCloud Dev
Requests Removal
From Ubuntu Repos
Over Security Holes
Microsoft Now Makes
Money From Surface
Line, Q1 Sales
Reach Almost $1
Billion
Days After
Shooting, Canada
Proposes New
Restrictions On and
Offline
AT&T Locks
Apple SIM Cards On
New iPads
Passwords: Too Much
and Not Enough
Verizon Injects
Unique IDs Into
HTTP Traffic
Secretive Funding
Fuels Ongoing Net
Neutrality
Astroturfing
Controversy
A Low Cost, Open
Source Geiger
Counter (Video)
Computer Scientist
Parachutes From
135,908 Feet,
Breaking Record
Article viewer

Simple ASM program



Written by:dimport
Published by:sefo
Published on:2003-06-21 07:19:46
Topic:Assembly
Search OSI about Assembly.More articles by dimport.
 viewed 13739 times send this article printer friendly

Digg this!
    Rate this article :
This simple ASM program is designed to show you some of the syntax, and get you accustomed to how the code is written.

This example prints a character to the screen

An assembler is required to turn this into an executable application. Look here for details of downloading assemblers

.MODEL SMALL
 
.CODE

MOV AH,2 ;COMMAND TO PRINT CHAR
MOV DL,'J' ; CHARACTER TO PRINT
INT 21h ;INTERRUPT TO PRINT CHAR
INT20h ; RETURN SAFELY TO DOS
 
END


This article was originally written by JagWire

Did you like this article? There are hundreds more.

Comments:
typedeaF
2006-07-20 17:47:15
Horrible?
The comments tell you exactly whats going on... if you already understand whats going on :/ Even then, they are still vague.

This program makes use the the DOS service dispatcher which is called by making a software interrupt to vector 0x21. The particular service is called "Display Character" which is service 0x02. This is why AH is loaded with 2. The Print Character service also expects the character to be loaded in DL. Interrupt vector 0x20 is one of several ways to return control back to the program.

A lot could be said alone on software interrupts and the interrupt vector table before even getting into the particular services the DOS service dispatcher.

Learning assembly isnt about memorizing code snippits and instructions, its about memory addressing and memory management.

typedeaF
Anonymously add a comment: (or register here)
(registration is really fast and we send you no spam)
BB Code is enabled.
Captcha Number:


Blogs: (People who have posted blogs on this subject..)
jackier
jackier on Mon 13th Oct 10am
111
sefo
Sneak - encryption on Fri 17th Nov 12pm
I'm developing the win32 version of sneak: http://snarkles.net/scripts/sneak/sneak. php The ASM source code is available on cyberarmy svn (for members only - free) Check the forum for details: http://www.cyberarmy.net/forum/sneak/mes sages/295244.
sefo
Geek Toolbar on Mon 13th Nov 8am
This a very simple and small toolbar I wrote in my spare time. I use the same set of tools very often and I find it very annoying to look for them in the start menu, on the desktop or in explorer. http://www.osix.net/modules/folder/index .php?tid=134
sefo
BinScan and Alternate Data Stream on Thu 27th Jul 9am
BinScan I created this tool to quickly identify modifications in the PE, use of a TLS callback and Alternate Data Streams. -> Some modifications done in the PE structure of an executable can prevent debuggers or other tools to open the executable.
sefo
Wmf Creator on Wed 26th Jul 7am
Now that the blog is online, I'll be able to share two or three tools I wrote. The first one I'd like to share is WMF Creator. I already put a link in the comments of my article: Wmf Exploit but I thought it would look nicer here. This tool will tak

Test Yourself: (why not try testing your skill on this subject? Clicking the link will start the test.)
Reverse Engineering by Geek_Freek

A test to check your assembly and reversing skills.
Assembly Language - non compiler specific by TroPe

You can test your assembly knowledge by taking this test. It starts out relatively easy, but gets progressively hards very quickly! If you know assembly, or just want to see what you DONT know about assembly, this test is for you. A more advanced assembly


     
Your Ad Here
 
Copyright Open Source Institute, 2006