Experiment No-1
Aim
To
write an assembly language for adding two 8-bit numbers by using microprocessor
kit.
Apparatus required
8085
micro processor kit, ( 0-5V ) DC battery.
Theory
In order to perform
addition in 8085, one of the data should be in the accumulator and another data
can be in any one of the general purpose register or in the memory. After
addition, the sum is stored in .
The sum of two 8-bit
data can be either 8-bit ( sum only) or 9-bit ( sum and carry ).
The accumulator can
accumulated only the sum and if there is a carry, the 8085 will indicate by
setting the carry flag. Here one of the register is used to account for carry.
Algorithm
Step-1 MVI,A
Step-2 Load first data in a register A (
Accumulator )
Step-3 MVI,B
Step-4 Load second data in a register B
Step-5 ADD,B
Step-6 STA,2050h
Step-7 HLT
Assembly Language program
Address
Mnemonics Op.Codes ( Hex-codes)
2000 MVI,A 3E
2001 30h 30
2002 MVI,B 06
2003 20h 20
2004 ADD,B 80
2005 STA 32
2006 50 (Low byte of M.Add.) 50
2007 20 ( High byte of M.Add) 20
2008 HLT 76
Results
Result- 50h
The assembly language
program addition of two 8-bit numbers was executed successfully by using 8085
Microprocessor kit.
Experiment No-2
Aim
To
write an assembly language for subtracting two 8-bit numbers by using microprocessor
kit.
Apparatus required
8085
micro processor kit, ( 0-5V ) DC battery.
Theory
In order to perform
subtracting in 8085, one of the data should be in the accumulator and another
data can be in any one of the general purpose register or in the memory. After
subtraction, the result is stored in accumulator.
Algorithm
Step-1 MVI,A
Step-2 Load first data in a register A (
Accumulator )
Step-3 MVI,B
Step-4 Load second data in a register B
Step-5 SUB,B
Step-6 STA,2050h
Step-7 HLT
Assembly Language program
Address
Mnemonics Op.Codes ( Hex-codes)
2000 MVI,A 3E
2001 30h 30
2002 MVI,B 06
2003 20h 20
2004 SUB,B 90
2005 STA 32
2006 50 (Low byte of M.Add.) 50
2007 20 ( High byte of M.Add) 20
2008 HLT 76
Results
Result- 10h
The assembly language
program subtraction of two 8-bit numbers was executed successfully by using 8085
Microprocessor kit.
Record breaking sir...I cannot say something ....
ReplyDeleteEvery course is taught by the best teachers and conducted in an engaging manner to keep students involved.
ReplyDeletePrimary PSLE Tuition
Your post is just outstanding! thanx for such a post,its really going great and great work.
ReplyDeletePsle math tuition
psle science tuition
psle english tuition