Question: QUESTION 2 [ 2 0 MARKS ] ( a ) Given [ 0 2 0 ] = 0 7 A , [ 0 2 1

QUESTION 2[20 MARKS]
(a) Given [020]=07A,[021]=005 and C=1, show the status of N,OV and DC after the following instruction:
[3 Marks]
MOVF 020, W, A
ADDWFC 021,F,A
(b) Without using multiplication instruction, multiply the content of 043 with 2.
[3 Marks]
(c) Write an instruction sequence to read one byte data at program memory location 02480 and write to file register at 0250.
[6 Marks]
(d) Figure 2 depicts a macro program and an incomplete delay subroutine. There are missing instructions from Line 3 until Line 7. The time delay provided by delay subroutine is 20ms. Calculate total instruction cycles and complete the missing lines by writing a complete subroutine named delay. Assume the crystal frequency is 32MHz. Show ALL your calculations.
[8 Marks]Figure 2: Program for Question 2(d)help
 QUESTION 2[20 MARKS] (a) Given [020]=07A,[021]=005 and C=1, show the status

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!