By Heshalini Rajagopal
By Heshalini Rajagopal
By
Heshalini Rajagopal
Write an assembly language to compare two data
and print the message that the data is equal or not
equal.
Second Option
Third Option:
Write an assembly language to add two data and
print the message that the addition result has
carry.
Second Option
Write a program to add two words located at offset address 0800H and 0700H in the
segment address 3000H and the result has to be stored at 0900H in the same
segment and carry will be stored at 0902H in the same segment.
#start=led_display.exe#
#make_bin#
name "led"
MOV AX, 0
x1:
OUT 199, AX
INC AX
CMP AX,101
JE exit
JMP x1
exit:
HLT
Write a programe to display “Hello World!”
character by character on the EMU 8086 screen
ORG 100H
JMP START
MSG DB ‘Hello World!’, 0
START:
MOV SI, 0
NEXT_CHAR:
MOV AL, MSG[SI]
CMP AL, 0
JE STOP
MOV AH, OEH; PRINT CHARACTER IN TELETYPE MODE
INT 10H
INC SI
JMP NEXT_CHAR
STOP:
MOV AH, 0; WAIT FOR ANY KEY TO PRESS
INT 16H
RET; EXIT HERE AND RETURN CONTROL TO OS
END; STOP THE COMPILER
Option 2
org 100h
mov cx,12d
jmp start
msg db 'Hello World!'
start:
mov si, 0
nxt:
mov al, msg[si]
mov ah, 0eh ; print character in teletype mode
int 10h
inc si
loopne nxt
hlt
Write a program to add two BCD data 29H and 98H and store
the result in BCD form in the memory location 2000H:3000H
and carry in 2000H:3001H