MP Lab Manual PDF
MP Lab Manual PDF
Faculty:
S.K.Chaitanya.R (Section-‘B’)
1
DIGITAL ELECTRONICS & MICROPROCESSOR LAB
INDEX
Page
S.No Name of the Experiment
Number
1. Study of basic gates. 3
2. Realization of Gates by using Universal Building Blocks. 5
3. Realization of Flip-Flops. 9
4. 4-bit Ripple counter. 11
5. 4-bit Shift Register. 14
6. 4-bit & 8-bit Binary Adders 17
7. Addition of two 8-bit numbers 20
8. Subtraction of two 8 - bit numbers 23
9. Multiplication of two 8-bit numbers 26
10. Division of two 8-bit numbers 29
11. Addition of two 16-bit numbers 32
12. Subtraction of two 16 - bit numbers 35
13. BCD addition 38
14. BCD subtraction 42
15. Sorting of data in Ascending order and finding Largest 45
Number in the array
16. Sorting of data in Descending order and finding Smallest 49
Number in the array
17. DAC/ADC interface 53
18. Stepper motor controller 57
19. 8279- programmable keyboard/display interface 61
2
EXPERIMENT: 1 STUDY OF BASIC GATES
LEARNING OBJECTIVE:
• Identify various ICs and their specification.
COMPONENTS REQUIRED:
• Logic gates (IC) trainer kit.
• Connecting patch chords.
• IC 7400, IC 7408, IC 7432, IC 7406, IC 7402, IC 7404, IC 7486
THEORY:
The basic logic gates are the building blocks of more complex logic circuits. These logic
gates perform the basic Boolean functions, such as AND, OR, NAND, NOR, Inversion, Exclusive-
OR, Exclusive-NOR. Fig. below shows the circuit symbol, Boolean function, and truth. It is seen
from the Fig that each gate has one or two binary inputs, A and B, and one binary output, C. The
small circle on the output of the circuit symbols designates the logic complement. The AND, OR,
NAND, and NOR gates can be extended to have more than two inputs. A gate can be extended to
have multiple inputs if the binary operation it represents is commutative and associative.
These basic logic gates are implemented as small-scale integrated circuits (SSICs) or as part
of more complex medium scale (MSI) or very large-scale (VLSI) integrated circuits. Digital IC gates
are classified not only by their logic operation, but also the specific logic-circuit family to which they
belong. Each logic family has its own basic electronic circuit upon which more complex digital
circuits and functions are developed. The following logic families are the most frequently used.
TTL and ECL are based upon bipolar transistors. TTL has a well established popularity among
logic families. ECL is used only in systems requiring high-speed operation. MOS and CMOS, are based
on field effect transistors. They are widely used in large scale integrated circuits because of their high
3
component density and relatively low power consumption. CMOS logic consumes far less power than
MOS logic. There are various commercial integrated circuit chips available. TTL ICs are usually
distinguished by numerical designation as the 5400 and 7400 series.
PROCEDURE:
1. Check the components for their working.
2. Insert the appropriate IC into the IC base.
3. Make connections as shown in the circuit diagram.
4. Provide the input data via the input switches and observe the output on output LEDs
4
EXPERIMENT: 2 REALIZATION OF GATES BY USING UNIVERSAL
BUILDING BLOCKS
Result :
5
Circuit Diagram :
6
Realization of EX-NOR gate using only NAND gates
7
Realization of EX-OR gate using only NOR gates
8
EXPERIMENT: 3 REALIZATION OF FLIPFLOPS
Aim : To Construct different types of flip-flops and verify the truth tables.
Procedure :
1. RS flip-flop is wired as shown in fig and input signals are fed from logic input
switches and the output is monitored on the logic level output condition indicators and
the truth table is verified.
2. JK flip-flop is wired as shown in fig and the input signals are fed from logic input
switches and the output is monitored on the logic level output condition indicators and
the truth table is verified.
3. Verify the truth tables of D flip flop and T flip flop in the same procedure.
Result :
Circuit Diagram:
9
JK flip- flop
Theoretical Practical
Clk PR CR J K
Qn+1 Qn+1
0 0 1 X X 1
0 1 0 X X 0
↓ 1 1 0 0 Qn
↓ 1 1 0 1 0
↓ 1 1 1 0 1
↓ 1 1 1 1 Qn
T flip- flop
Theoretical Practical
Clk PR CR T
Qn+1 Qn+1
0 0 1 X 1
0 1 0 X 0
↓ 1 1 0 Qn
↓ 1 1 1 Qn
D flip- flop
Theoretical Practical
Clk PR CR D
Qn+1 Qn+1
0 0 1 X 1
0 1 0 X 0
↓ 1 1 0 0
↓ 1 1 1 1
10
EXPERIMENT: 4 4-BIT RIPPLE COUNTER
Aim : To design Asynchronous ( Ripple) counter and verify the truth table.
Procedure :
Result :
11
4 – bit Ripple Counter Truth Table.
Clock pulses Q3 Q2 Q1 Q0
0 0 0 0 0
1 0 0 0 1
2 0 0 1 0
3 0 0 1 1
4 0 1 0 0
5 0 1 0 1
6 0 1 1 0
7 0 1 1 1
8 1 0 0 0
9 1 0 0 1
10 1 0 1 0
11 1 0 1 1
12 1 1 0 0
13 1 1 0 1
14 1 1 1 0
15 1 1 1 1
16 0 0 0 0
12
Circuit Diagram:
13
EXPERIMENT: 5 4 - BIT SHIFT REGISTER
Aim : To design 4-bit shift register and verify the operation of serial loading
and parallel loading,
Procedure :
Result : The operation of 4-bit shift register for serial loading and parallel loading is observed
14
4 – bit Shift Register Truth Table :
Parallel output
Load Clk Clear Serial i/p Serial output Qo
Q3 Q2 Q1 Q0
0 X 0 X 0 0 0 0 0
0 1 1 0 0 0 0 0 0
0 2 1 1 1 0 0 0 0
0 3 1 0 0 1 0 0 0
0 4 1 1 1 0 1 0 0
0 5 1 0 0 1 0 1 1
0 6 1 0 0 0 1 0 0
0 7 1 0 0 0 0 1 1
0 X 0 X X X X 0 0 0 0 0
1 X 1 1 0 1 0 1 0 1 0 0
0 1 1 X X X X 0 1 0 1 1
0 2 1 X X X X 0 0 1 0 0
0 3 1 X X X X 0 0 0 1 1
15
Circuit Diagram:
16
EXPERIMENT: 6 4-BIT & 8-BIT BINARY ADDERS
Procedure :
Adders:
Result :
The truth tables for 4 bit & 8 bit full adders are verified.
Truth Table :
A3 A2 A1 A0 B3 B2 B1 B0 Cin S3 S2 S1 S0 Cout
17
8 – bit Binary Adder :
A7 A6 A5 A4 A3 A2 A1 A0 B7 B6 B5 B4 B3 B2 B1 B0 Cin S7 S6 S5 S4 S3 S2 S1 S0 Cout
Circuit Diagram:
18
19
EXPERIMENT: 7 ADDITION OF TWO 8-BIT NUMBERS
PROGRAM:
Write an assembly language program to add two binary numbers of 8-bit data stored in memory
locations 8C40H and 8C41H and store the result in 8C42H and 8C43H.
PROBLEM ANALYSIS:
To perform addition in 8085 one of the data should be in accumulator and another data can be in
any one of the general purpose register or in memory. After addition the sum will be in
accumulator. The sum of two 8-bit data can be either 8-bit (sum only) or 9 bits (sum and carry).
The accumulator can be accommodated only the sum and if there is a carry, the 8085 will
indicate by setting carry flag. Hence one of the register is used to account for carry.
ALGORITHM:
20
FLOWCHART:
21
ASSEMBLY LANGUAGE PROGRAM:
OUTPUT:
8C40::02
8C41::03
8C42::05
8C43::00
22
EXPERIMENT: 8 SUBTRACTION OF TWO 8 - BIT NUMBERS
PROGRAM:
Write an assembly language program to subtract two numbers of 8-bit data stored in memory
locations 8C40H and 8C41H. Store the magnitude of the result in 8C42H. If the result is positive
store 00 in 8C43H or if the result is negative store 01in 8C43H.
PROGRAM ANALYSIS:
To perform subtraction in 8085 one of the data should be in accumulator and another data can be
in anyone of the general purpose register or in memory. After subtraction the result will be in
accumulator. The 8085 performs 2’s complement subtraction and then complements the carry.
Therefore if the result is negative then carry flag is set and accumulator will have 2’s
complement of the result. Hence one of the register is used to account for sign of the result. To
get the magnitude of the result again take 2’s complement of the result.
ALGORITHM:
1. Load the subtrahend (the data to be subtracted) from memory to accumulator and move it
to B- register.
2. Load the minuend from memory to accumulator.
3. Clear C register to account for sign of the result.
4. Subtract the content of B-register from the content of the accumulator.
5. Check for carry . if carry =1 go to step 6 or if carry=0 , go to step 7.
6. Increment C register , complement the accumulator and add 01H
7. store the difference in memory.
8. Move the content of C register (sign bit) to accumulator and store in memory.
9. Stop.
23
FLOWCHART:
24
ASSEMBLY LANGUAGE PROGRAM:
in A-reg
OUTPUT:
8C40::02
8C41::03
8C42::01
8C43::01
25
EXPERIMENT: 9 MULTIPLICATION OF TWO 8-BIT NUMBERS
PROBLEM:
Write an assembly language program to multiply two numbers of 8–bit data stored in memory
8C4OH and 8C41H. Store the product in 8C42H and 8C43H.
PROBLEM ANALYSIS:
In this method multiplication is performed as repeated additions. The initial value of sum is
assumed as zero. One of the data is used as count (N) . For number of additions to be performed.
Another data is added to the sum N times where N is the count. The result of the product of two
8-bit data may be 16-bit data. Hence another register is used to account for over flow.
ALGORITHM:
26
FLOWCHART:
27
ASSEMBLY LANGUAGE PROGRAM:
OUTPUT:
8C40::02
8C41::03
8C42::06
8C43::00
28
EXPERIMENT: 10 DIVISION OF TWO 8-BIT NUMBERS
PROBLEM:
4. Stop subtraction when the dividend is less than the divisor .The dividend now
29
FLOWCHART:
START
B 00
[HL] 4500
A M
[HL] [HL]+1
M A-M
[B] [B] +1
NO
IS A<0
YES
A A+ M
B B-1
[HL] [HL]+1
[M] [A]
[HL] [HL]+1
[M] [B]
30
STOP
ASSEMBLY LANGUAGE PROGRAM:
OUTPUT:
4500::06
4501::03
4502::00
4503::02
31
EXPERIMENT: 11 16-BIT ADDITION
PROGRAM:
Write an assembly language program to add two numbers of 16-bit data stored in memory
8C40H, 8C41H and 8C42H, 8C43H. The data are stored such that LSB first and then MSB and
store the result from 8C44H to 8C46H
PROBLEM ANALYSIS:
The 16-bit addition can be performed in 8085 microprocessor either in terms of 8-bit addition
or by using DAD instruction. In addition using DAD instruction, one of the data should be in H
L pair and another data can be another register pair. After addition the sum will be in H L
register pair. If there is a carry in addition then that is indicated by setting carry flag. Hence
one the register is used to account for carry.
ALGORITHM:
32
FLOWCHART:
33
ASSEMBLY LANGUAGE PROGRAM:
OUTPUT:
8C40::02
8C41::03
8C42::05
8C43::00
8C44::07
8C45::03
8C46::00
34
EXPERIMENT: 12 16-BIT SUBTRACTION
PROGRAM:
Write an assembly language program to subtract two numbers of 16-bit data stored in memory
from 8C40H to 8C43H. The data are stored such that LSB first and then MSB. Store the result in
8C44H and 8C45H.
PROBLEM ANALYSIS:
The 16-bit subtraction is performed in terms of 8-bit subtraction. First LSB’s of the data are
subtracted and the result is stored in memory. Then MSB’s of the data are subtracted along with
borrow in the previous subtraction and the result is stored in memory.
ALGORITHM:
1. Load the low byte of subtrahend in accumulator from memory and move is to B-register.
2. Load the low byte of minuend in accumulator from memory.
3. Subtract the content of B-register from the content of accumulator.
4. Store the low byte of result in memory.
5. Load the high byte of subtrahend in accumulator from memory and move it to B-register.
6. Load the high byte of minuend in accumulator from memory.
7. Subtract the content of B-register and the carry from the content of accumulator.
8. Store high byte of result in memory.
9. Stop the program.
35
FLOWCHART:
36
ASSEMBLY LANGUAGE PROGRAM:
37
EXPERIMENT: 13 TWO DIGIT BCD ADDITION
PROGRAM:
Write an assembly language program to add two numbers of two digit (single precession) BCD
data stored memory locations 8C40H and 8C41H. Store the result in 8C42H and 8C43H.
PROBLEM ANALYSIS:
The 8085 microprocessor will perform only binary addition. Hence for BCD addition, the binary
addition of BCD data is performed and then the sum is corrected to get result in BCD. After
binary addition the following correction should be made to get the result in BCD.
1. if the sum of lower nibble exceeds 9 or if there is an auxiliary carry then 06 is added
to lower nibble.
2. if the sum of upper nibble exceeds 9 or if there is carry then 06 is added to upper
nibble.
The above correction is taken care by DAA instruction. Therefore after binary addition execute
DAA instruction to do the above correction in the sum.
ALGORITHM:
38
10. Stop.
39
FLOWCHART:
40
ASSEMBLY LANGUAGE PROGRAM:
OUTPUT:
8C40::80
8C41::80
8C42::60
8C43::01
41
EXPERIMENT 14 TWO DIGIT BCD SUBTRACTION
PROGRAM:
Write an assembly language program to subtract BCD numbers of 2 digit BCD data stored in
memory 8C40H and 8C41H. store the result in 8C42H.
PROBLEM ANALYSIS:
The 8085 microprocessor will perform only binary subtraction. Hence for BCD subtraction 10’s
complement subtraction is performed. First the 10’s complement of the subtrahend is obtained
and then added to minuend. The DAA instruction is executed to get the result in BCD.
ALGORITHM:
42
FLOWCHART:
43
ASSEMBLY LANGUAGE PROGRAM:
OUTPUT:
8C40::80
8C41::60
8C42::20
8C43::00
44
EXPERIMENT 15 SORTING OF DATA IN ASCENDING ORDER AND
FINDING LARGEST NUMBER IN THE ARRAY
PROGRAM:
Write an assembly language program to sort an array of data in ascending order and find the
largest number and display it in the data field. The array is stored in memory starting from
8C40H. The first element of the array gives the count value for the number of elements in the
array.
PROBLEM ANALYSIS:
The algorithm for bubble sorting is given below. In bubble sorting of N-data,
(N-1) comparisons are carried by taking two consecutive data at a time. After each comparison,
the data are rearranged such that smallest among the two is in first memory location and largest
in the next memory location. When we perform (N-1) comparisons as mentioned above, for (N-
1) times then the array consisting of N-data will be sorted in the ascending order.
ALGORITHM:
1. Load the count value from memory to A-reg. and save it in B-reg.
2. Decrement B-reg . (B is a count for N-1 repetitions)
3. Set H L pair as data address pointer.
4. Set C-register as counter for (N-1) comparisons.
5. Load a data of the array in accumulator using the data address pointer.
6. Increment the H L pair (data address pointer).
7. Compare the data pointed by H L with accumulator.
8. if carry flag is set (if the content of the accumulator is smaller than memory) then go to
step 10, otherwise go to next step.
9. Exchange the content of memory pointed by H L and the accumulator.
10. Decrement C-register. if zero flag is reset go to the step 6 otherwise go to next step.
11. Decrement B-register. If zero flag is reset go to step 3 otherwise go to next step.
12. Load the largest value from memory into accumulator.
13. Store the content of accumulator in memory location 8FF1H.
14. Call subroutine to display the content of memory location 8FF1H into the data field.
45
15. Stop.
46
FLOWCHART:
47
ASSEMBLY LANGUAGE PROGRAM:
MEMORY MACHINE LABEL MNEMONIC COMMENT
LOCATION CODE
8COOH 3A 40 8C LDA 8C4OH ; load the count value in A-reg.
8CO3H 47 MOV B,A ; set counter for (N-1)repetitions of
8CO4H 05 DCR B N-1 comparisons.
8CO5H 21 40 8C L2 LXI H,8C4OH ; set pointer for array.
8CO8H 4E MOV C,M ; set counter for (N-1) comparisons.
8CO9H OD DCR C ;
8COAH 23 INX H ; increment pointer
8COBH 7E L1 MOV A,M ; get one data of array in A-reg.
8COCH 23 INX H ; increment pointer.
8CODH BE CMP M ; compare next data with A-reg.
8COEH DA 16 8C JC L3 ; if content of A is less than
memory then go to L3
8C11H 56 MOV D,M ; if the content of A is greater than
8C12H 77 MOV M,A the content of memory then exchange
8C13H 2B DCX H the content of memory pointed by H L
8C14H 72 MOV M,D and previous location.
8C15H 23 INX H ;
8C16H OD L3 DCR C ; decrement C-register.
8C17H C2 0B 8C JNZ L1 ; repeat comparisons until C reg.
count is zero.
8C1AH 05 DCR B ; decrement B-register.
8C1BH C2 05 8C JNZ L2 ; repeat until B count is zero.
8C1EH 7E MOV A,M ; get the largest number into
accumulator.
8C1FH 32 F1 8F STA 8FF1H ; store the content of accumulator
in memory location 8FF1H.
8C22H CD 4C 04 CALL 044CH ; call subroutine to display the
content of the memory location
8FF1H in data field.
8C25H 76 HLT ; halt the program.
OUTPUT:
8C40::03 8C43::03
8C41::01 8FF1::03
8C42::02
48
EXPERIMENT 16 SORTING OF DATA IN DESCENDING ORDER
AND FINDING SMALLEST NUMBER IN THE ARRAY
PROGRAM:
Write an assembly language program to sort an array of data in descending order and find the
smallest number and display it in the data field. The array is stored in memory starting from
8C40H. The first element of the array gives the count value for the number of elements in the
array.
PROBLEM ANALYSIS:
The algorithm for bubble sorting is given below. In bubble sorting of N-data , (N-1) comparisons
are carried by taking two consecutive data at a time. After each comparison, the data are
rearranged such that largest among the two is in first memory location and smallest in the next
memory location. When we perform (N-1) comparisons as mentioned above, for N times then
the array consisting of N-data will be sorted in the descending order.
ALGORITHM:
1. Load the count value from memory to A-reg. and save it in B-reg.
2. Decrement B-reg (B is a count for N-1 repetitions).
3. Set H L pair as data address pointer.
4. Set C-register as counter for (N-1) comparisons.
5. Load a data of the array in accumulator using the data address pointer.
6. Increment the H L pair (data address pointer).
7. Compare the data pointed by H L with accumulator.
8. If carry flag is reset (if the content of the accumulator is larger than memory) then go to
step 10, otherwise go to next step.
9. Exchange the content of memory pointed by H L and the accumulator.
10. Decrement C-register. if zero flag is reset go to the step 6 otherwise go to next step.
11. Decrement B-register. If zero flag is reset go to step 3 otherwise go to next step.
12. Load the smallest value from memory into accumulator.
13. Store the content of accumulator in memory location 8FF1H.
14. Call subroutine to display the content of memory location 8FF1H into the
49
data field.
15. Stop.
50
FLOWCHART:
51
ASSEMBLY LANGUAGE PROGRAM:
MEMORY MACHINE LABEL MNEMONIC COMMENT
LOCATION CODE
52
EXPERIMENT 17 DIGITAL TO ANALOG CONVERSION
Source code:
ORG 4100
START : MVI A, 00
OUT 0C8H
CALL DELAY
MVI A, 0FF
OUT 0C8H
CALL DELAY
JMP START
DELAY : MVI B, 05
L1 : MVI C, 0FF
L2 : DCR C
JNZ L2
DCR B
JNZ L1
RET
CALCULATION:
Amplitude:
Time Period:
53
b) To generate sine-wave at DAC1 output.
Source code:
ORG 4100H
START : LXI H, 4110H
MVI C, 46
LOOP : MOV A, M
OUT 0C0H
INX H
DCR C
JNZ LOOP
JMP START
LOOK-UP TABLE : (4110)
7F 8A 95 A0
AA B5 BF C8
D1 D9 E0 E7
ED F2 F7 FA
FC FE FF FE
FC FA F7 F2
ED E7 E0 D9
D1 C8 BF B5
AA A0 95 8A
7F 74 69 5F
53 49 3F 36
2D 25 1D 17
10 0B 07 04
01 00 01 04
07 0B 10 17
1D 25 2D 36
3F 49 53 57
69 74
54
c) To generate triangular waveform at DAC2 output
Source code:
ORG 4100H
START : MVI L, 00
L1 : MOV A, L
OUT 0C8H
INR L
JNZ L1
MVI L, 0FFH
L2 : MOV A, L
OUT 0C8H
DCR L
JNZ L2
JMP START
CALCULATION:
Amplitude:
Time Period:
55
d) To create a saw-tooth wave at the output of DAC1.
Source code:
ORG 4100H
START : MVI A, 00H
L1 : OUT 0C0H
INR A
JNZ L1
JMP START
CALCULATION:
Amplitude:
Time Period:
56
EXPERIMENT 18 STEPPER MOTOR CONTROLLER
a. Stepper motor at different speeds
Aim: To write an ALP for run a stepper motor at different speeds in two directions and observe
the actions which takes place.
Apparatus:
1. Micro-85EB 8085 µP kit
2. Stepper motor Interface Module
3. Bus card
Source Code:
START: LXI H, LOOK UP
MVI B,04
REPT: MOV A,M
OUT 0C0H
LXI D, 0303H
DELAY NOP
DCX D
MOV A,E
ORA D
JNZ DELAY
INX H
DCR B
JNZ REPT
JMP START
LOOK UP:
DB: 09 05 06 0A
Procedure:
1. Enter the above program starting from 4100h. Connect the stepper motor in port1 and
execute.
2. The stepper motor can be rotates. Speed can be varied by varying the count at DE pair.
3. Direction can be varied by entering the data in the LOOK UP table in the reverse order.
57
b. Stepper motor at different angles
Aim: To write an ALP for run a stepper motor for required angle within 3600, which is
equivalent to 256 steps.
Apparatus:
1. Micro-85EB 8085 µP kit
2. Stepper motor Interface Module
3. Bus card
Source Code:
MVI C, HEX DATA
START: LXI H, LOOK UP
MVI B,04
REPT: MOV A,M
OUT C0
DCR C
JZ END
LXI D, COUNT
DELAY: NOP
DCX D
MOV A,E
ORA D
JNZ DELAY
INX H
DCR B
JNZ REPT
JMP START
LOOK UP:
DB :09 05 06 0A
END: HLT
Procedure:
1. Enter the above program. Connect the stepper motor in port1 and execute.
2. By converting the required steps in decimal to hex and entering the hex data at 4101h.
3. The motor rotates for so much steps and then stops.
58
C. Stepper motor at both directions
Aim: To write an ALP for run stepper motor in both forward and reverse directions with delay.
Apparatus:
1. Micro-85EB 8085 µP kit
2. Stepper motor Interface Module
3. Bus card
Source Code:
START: MVI C,20H
FORWD: LXI H, FORLOOK
CALL ROTATE
DCR C
JNZ FORWD
CALL STOP
MVI C,20H
REVES: LXI H,REVLOOK
CALL ROTATE
DCR C
JNZ REVES
CALL STOP
JMP START
ROTATE: MVI B,04H
REPT: MOV A,M
OUT C0H
LXI D,0303H
LOOP1: DCX D
MOV A,E
ORA D
JNZ LOOP1
INX H
DCR B
JNZ REPT
RET
59
DB 09H 05H 06H 0AH
REVLOOK
DB 0AH 06H 05H 09H
END
Procedure:
1. Enter the above program starting from 4100h.
2. Connect the stepper motor in port1 and execute.
3. Observe that the stepper motor runs in forward direction and reverse direction
continuously with a delay.
RESULT:
Hence the stepper is rotated in different directions and different angles and different speeds.
60
EXPERIMENT 19 8279- PROGRAMMABLE KEYBOARD/DISPLAY INTERFACE
Aim: To display the rolling message ‘HELP US” in the display.
Apparatus:
1. Micro-85EB 8085 µP kit
2. 8279 Interface Module (Key board & Display)
3. Bus card
Equivalent: CNT EQU C2H
DAT EQU C0H
POINTER EQU 412CH
Source Code:
START: LXI H, POINTER
MVI D, 0FH
MVI A, 10H
OUT CNT
MVI A, CCH
OUT CNT
MVI A, 90H
OUT CNT
LOP: MOV A,M
OUT DAT
CALL DELAY
INX H
DCR D
JNZ LOP
JMP START
DELAY: MVI B, A0H
LOP1: MVI C, FFH
LOP2: DCR C
JNZ LOP2
DCR B
61
JNZ LOP1
RET
POINTER: FF FF FF FF
FF FF FF FF
98 68 7C C8
1C 29 FF FF
Procedure:
1. Enter the above program starting from 4100h.
2. The data fetched from address 412Ch and display in the first digit of the display.
3. The next data is displayed in the second digit of the display.
4. A time delay is given between successive digits for a lively display.
RESULT:
Hence the message HELPUS is displayed.
62