Kantipur Forum - a real solution
WELCOME !!

Please Register, ask for assignment solutions & post the solutions if you know any.

LETS START POSTING YOUR IDEAS AND THOUGHTS AND BUILD THE COMMUNITY OF EXPERTS.



ASK FOR SOLUTION YOU WILL BE SATISFIED
HomeGalleryFAQSearchCalendarRegisterLog in

Share | 
 

 Assesment question for 8085

View previous topic View next topic Go down 
AuthorMessage
tihor
Administrator


Number of posts: 54
Location: Earth
faculty: bct/2/2
Points: 63
Reputation: 4
Registration date: 2009-02-28

PostSubject: Assesment question for 8085   21st March 2009, 2:20 pm

Q> With the assumption that there are 100 eight bit data in a table starting form A000H, Write an 8085 program to find the sums of even and odd numbers of the table and store the 16-bit sums at the end of the table.

Solution:

LXI B,A000H
LXI D,0000H
LXI H,0000H

START: LDAX B
RRC
JC ODD
RLC
ADD E
JNZC P1
INR D
P1: MOV E,A
JMP INCR

ODD: RLC
ADD L
JNC P2
INR H
P2: MOV L,A

INCR: INX B
MOV A,C
CPI 64H
JNZ START

SHLD A064H
XCHG
SHLD A066H
HLT


Back to top Go down
View user profile
 

Assesment question for 8085

View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Kantipur Forum - a real solution :: Computer and Technology :: Programming :: Application Development :: Assembly Langauge :: 8085 Solutions-
Jump to:  
Forum free | © phpBB | Free forum support | Contact | Report an abuse | Free forums