0% found this document useful (0 votes)
2 views6 pages

8085 Microprocessor Logical Programs

Uploaded by

gwagon620
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views6 pages

8085 Microprocessor Logical Programs

Uploaded by

gwagon620
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

MICROPROCESSOR PRACTICAL (CS-354) CO22370

Practical 10
Logical Programs

Teacher Signature:
MICROPROCESSOR PRACTICAL (CS-354) CO22370

PROGRAM- 10
AIM: Logical Programs.

Hardware Requirements:
Microprocessor 8085 (MAXEDU-01 8085 Microprocessor Training Kit).
Software Requirements:
8085 Simulator IDE

Program 10(a): Find the square of the given number.


Memory Machine Mnemonics Operands Comments
Address Code

2070 3A,00,25 LDA 2500H Load data in accumulator.


2073 6F MOV L, A Move data in register L.
2074 26 MVI H, 26H Move 26 in register H with
immediate.
2075 7E MOV A, M Move
Square of data in accumulator.
2076 32,01,25 STA 2501 H Store data to address.
2079 76 HLT - Stop the execution temporarily.

1. Reset Kit and Load the Data from address to accumulator.

2. Move the data in register pair.

Teacher Signature:
MICROPROCESSOR PRACTICAL (CS-354) CO22370

3. Move the data in register pair with immediate.

4. Move the values of data in accumulator.

5. Store data to address.

6. Excetution stoped and successful executed.

7. Values is in the assigned address.

Teacher Signature:
MICROPROCESSOR PRACTICAL (CS-354) CO22370

10(b) Find the larger of the two numbers.

Memory Machine Code Mnemonics Operands Comments


Address

2070 21,01,25 LXI H, 2501H Address of first number in H-L pair.

2073 7E MOV A, M Move 1st number to accumulator.

2074 23 INX H Increment the value in Address of


2nd number in H-L pair.

2075 BE CMP M Compare 2nd number with 1st


number.

2076 D2 JNC AHEAD No, larger is in accumulator. Go to


AHEAD.

2079 7E MOV A, M Yes, get 2nd number in the


accumulator.

207A 32,03,25 STA 2503 H Store larger number in 2503H.

207D 76 HLT - Stop the execution temporarily.

1. Reset Kit and load address to register.

Teacher Signature:
MICROPROCESSOR PRACTICAL (CS-354) CO22370

2. Move data from register to Accumulator.

3. Increment the value in the register.

4. Compare the values of Accumulator and register.

5. Jump if no larger is in accumulator.

6. Move second no. from register to accumulator.

7. Store larger number in the address.

Teacher Signature:
MICROPROCESSOR PRACTICAL (CS-354) CO22370

8. Excetution stoped and successful executed.

9. Value is in the assigned address.

Teacher Signature:

You might also like