Question: Write, Assemble and build ONE complete assembly program using the MPLAB IDE software based on the PIC 1 8 F 4 5 8 architecture to
Write, Assemble and build ONE complete assembly program using the MPLAB IDE software based on the PICF architecture to perform the following tasks:
a Setup and initialise the table pointer to point to an array of dataset stored at the Program memory with a starting at address x and label it as Array. The Dataset has a total of D elements of bit, signed numbers given in Hexadecimal representation.
b Count positive elements excluding zero in Array and save the result in POSNUM at address x in data memory.
c Sum all the positive elements in the dataset and save the result as a byte answer to file registers of addresses x until x at data memory using the littleendian format.
Requirements:
Your main program must start at address x Make sure you include sufficient Comments to make your program readable and understandable.
For debugging purpose, in your assembly program, define a data section at the program Memory after your main program. The data section should be named Array and Consists of a dataset:
Dataset:
xxxxxxxx
xxxxxxxx
xxxBxExxxx
xxxExxxxAx
xExxAxxExxxF
xDxxAxxExxxA
xDxFxxBxDxAxExA
xxxxxCxExBx
xxBxAxCxxDxx
xExxxExCxExxE
xxDBxFxExBxxFxED
xBxDxxxxDxxD
xCxxFxAxDxxxF
xExxAxExxBxAx
xCxxCxxxBxCxE
xAxxxBxFE,xxBx
xDA,xAxxFxxExBxF
xxAxExxxFxAxCA
xFxBxxDxxExExA
xxxBxxxxxB
xEF,xxCDxCxxBxFxC
xxxxBxAxxxD
xxEF,xDCxExxAxx
xxxCDxxCxxExD
xExFxxxDxBCxx
xFxxxFxxFCxAxB
xAxDxFxxxxxBF
xxExExxFxFxEx
xCxxBDxBxCxxBxAE
xFxAxxAxxDCxBxC
xxDxBxDxDxxxC
xDxxCCxxDxDxxE
Please Help me to provide me the below:
AFlowchart diagram drawing of your program
b The full assembly program
c The entire full MPLAB Output Window clearly showing the result of the build Process
d Screenshot of The contents of the program memory displayed as Symbolic for main program Starting at address x
e Screenshot of the contents of the program memory displayed as Opcode Hex for Array data section d Screenshot ofThe screenshot final contents of data memory block of BANK
e Screenshot ofThe final contents of watch window with the following registers: WREG, STATUS, TABLAT, TBLPTR FSRx
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
