M2A2.docx - M2A2:Lab Introduction to MPLABX IDE ELEC307...

This preview shows page 1 - 3 out of 7 pages.

M2A2:Lab Introduction to MPLABX IDE ELEC307 Microcontrollers MOD2 Assignment 2: Lab Intro to MPLABX IDE Mark A. Domingue Dr. Sohail Anwar Table of contents: Problem Statement: Page 3 Theoretical Analysis (flow chart, manual calculation results): Page 3 Procedure: Page 4 Source Code: Page 4 IDE Simulation: Pages 4 -5 Simulation Results and Discussion: Page 6 Conclusion: Page 6 References: Page 7 1
M2A2:Lab Introduction to MPLABX IDE Problem Statement: The following program adds two bytes, BYTE1 and BYTE2. If the sum generates an overflow, it clears REG10; otherwise save the sum in REG10. Complete the following problem. Theoretical Analysis: Students will attempt to write a program that adds 34H to 56H and stores the sum into register 0x10. If there is no overflow it will save the sum to REG10, if there is an overflow it will clear WREG and REG10. Procedure: 1. Start MPLAB and select FILE > CLOSE ALL PROJECTS. 2. Start a new project by selecting FILE > NEW PROJECT. Student will see the following wizard:

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture