write an assembly code which can call function in a loop
with al value from 0 to 9
Answers were Sorted based on User's Feedback
Answer / laxman
org 00h
mov r0,#09
mov r1,#01
loop : acall func; ; calling function in loop 9-0 times
djnz r0,loop
func : inc r1 ; output will be in r1 register
ret
end
if any thing plz mail to me laxman_balu@hotmail.com
Is This Answer Correct ? | 8 Yes | 1 No |
Answer / dinesh kumar.r
MVI B,00
MVI C,OA
LOOP:
INR B
DCR C
SUB C
JNZ LOOP
HLT
Is This Answer Correct ? | 2 Yes | 1 No |
Answer / sivasyam
mov ro,#10h
here:
acall fun
inc a1
djnz ro,here
Is This Answer Correct ? | 5 Yes | 5 No |
Answer / sridevi
Mr.Lakshman, I found some changes in your code. Hope this is OK.
org 00h
mov r0,#00
mov r1,#00
loop : acall func
inc r0
cjne r0,#09,loop
jmp pgmend
func: inc r1
ret
pgmend:
end
Is This Answer Correct ? | 2 Yes | 2 No |
Answer / pk
xor ax, ax
loop1:
call foo
inc al
cmp ax, 10
jb loop1
Is This Answer Correct ? | 3 Yes | 4 No |
In 8085 which is called as high order / low order register?
What are the general purpose registers in 8085?
What does quality factor mean?
The interrupt response time is determined by?
What does the parity flag do?
How many memory locations can be addressed by a microprocessor with 14 address lines?
What is the significance of the hold and hlda pins?
What was is the primary usage of a 8085 microprocessor?
Define the 8085 instruction format and their classification according to word size?
what is program counter?
How many hardware interrupts 8085 supports?
These are two ways in which a microprocessor can come out of Halt state.