Addressing Modes and Instruction Set (Part 1) PDF file

8:18 AM 6 Comments


Download it here!

6 comments:

  1. Hi ma'am hannah. What is the main purpose of the addressing modes? and why does it has 5 different addressing modes?

    ReplyDelete
    Replies
    1. hi Jen! The way an operand is specified is known as its addressing modes. It helps the programmer to store or retrieve the data which is stored in any part of the data memory. the 8051 microcontroller is designed to 5 addressing modes that's why it has 5 :) Hope this helps!

      Delete
  2. It is not yet clear to me the function of the indexed addressing mode, Ma'am. Yeah :)

    ReplyDelete
    Replies
    1. The address of the operand is obtained by adding the contents of the general register (called index register) a constant value. The number of the index register and the constant value are included in the instruction code. Index Mode is used to access an array whose elements are in successive memory locations. The content of the instruction code, represents the starting address of the array and the value of the index register, and the index value of the current element. By incrementing or decrementing index register different element of the array can be accessed.

      For example, our data pointer (DPTR) is in address 0054H. and our accumulator has the immediate value of 02H. When we execute the instruction:
      MOV A, @A+DPTR
      We first add A and DPTR. So we add 0054H and 02H we now have 0056H. Meaning, whatever value is stored in the address 0056H, we will move it to the accumulator. So if 0056H has the value of 0AH, our accumulator will now have a value 0f 0AH. Hope this helps!

      Delete
  3. Ma'am ano po ito Autoincrement /Autodecrement Mode and Displacement Mode?

    ReplyDelete