Question: PRACTICE SESSION - MICROCONTROLLERS Using MPLAB XIDE, execute the instructions given. Load the starting values for the registers and memory locations as given in the

 PRACTICE SESSION - MICROCONTROLLERS Using MPLAB XIDE, execute the instructions given.
Load the starting values for the registers and memory locations as given

PRACTICE SESSION - MICROCONTROLLERS Using MPLAB XIDE, execute the instructions given. Load the starting values for the registers and memory locations as given in the tables using MOV instructions. The registers and memory locations are modified by the instructions, confirm the final register and memory contents after each instruction with your calculated values. Register wo wi W2 W3 W4 Value Ox1004 Ox 1006 Ox8301 OxF0A2 OxFFFF Location Ox1000 Ox1002 Ox1004 Ox 1006 Ox1008 Value 0x382A OxFB80 Ox80FF 7B03 0001 MOV Ox1000, WREG 2. MOV W2, [W1] 3. ADD W2,W1,WO 4. ADD 0x1002, WREG 5. SUB.B WO, #5, W1 6. MOV #1006, WO 7. INC [WO], WI 8. MOV #1000, W1 9. DEC.B WO, [W] 10. SUB W2,[W] [WO] 11. DEC2.B W2,w1 12. INC 0x1004 1. Submit the code and outputs of the above instructions. 2. Write a PIC24 instruction sequence that accomplishes k=i-j-32, where i, j and k are uint8 variables. 3. Write PIC24 assembly language equivalents for the following C code fragment. Assume i, j and k are uint16 variables. k = i + (j & 0x4554) - Ox30 Submit the codes as well as memory blocks or watch variables windows to show the correct working of the code. PRACTICE SESSION - MICROCONTROLLERS Using MPLAB XIDE, execute the instructions given. Load the starting values for the registers and memory locations as given in the tables using MOV instructions. The registers and memory locations are modified by the instructions, confirm the final register and memory contents after each instruction with your calculated values. Register wo wi W2 W3 W4 Value Ox1004 Ox 1006 Ox8301 OxF0A2 OxFFFF Location Ox1000 Ox1002 Ox1004 Ox 1006 Ox1008 Value 0x382A OxFB80 Ox80FF 7B03 0001 MOV Ox1000, WREG 2. MOV W2, [W1] 3. ADD W2,W1,WO 4. ADD 0x1002, WREG 5. SUB.B WO, #5, W1 6. MOV #1006, WO 7. INC [WO], WI 8. MOV #1000, W1 9. DEC.B WO, [W] 10. SUB W2,[W] [WO] 11. DEC2.B W2,w1 12. INC 0x1004 1. Submit the code and outputs of the above instructions. 2. Write a PIC24 instruction sequence that accomplishes k=i-j-32, where i, j and k are uint8 variables. 3. Write PIC24 assembly language equivalents for the following C code fragment. Assume i, j and k are uint16 variables. k = i + (j & 0x4554) - Ox30 Submit the codes as well as memory blocks or watch variables windows to show the correct working of the code

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!