Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I need explantation why R28 is 0x77 and R29 is 0x03 .EQU var1 = 14 .DEF count = r7 .ORG 0x0000 RJMP init .ORG 0x0046
I need explantation why R28 is 0x77 and R29 is 0x03
.EQU var1 = 14
.DEF count = r7
.ORG 0x0000
RJMP init
.ORG 0x0046
init:
CLR count
LDI r20, var1
LDI r21, 5
LDI YH, HIGH(resultA)
LDI YL, LOW(resultA)
loop:
CP r20, r21
BRLT finish
SUB r20, r21
INC count
RJMP loop
finish:
ST Y+, count
ST Y+, r20
done:
RJMP done
.DSEG
.ORG 0x0375
resultA: .BYTE 1
resultB: .BYTE 1
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started