What are the addressing modes of the MCS-51 microcontroller and how do they operate?

Publisher:幸福之路Latest update time:2013-03-04 Source: 21IC Keywords:MCS-51 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

What is addressing mode? What are the addressing modes of MCS-51 microcontroller and how do they operate? What are the addressing spaces and ranges of various addressing modes?

Answer: MCS-51 microcontroller has 7 addressing modes: immediate addressing, register addressing, direct addressing, register indirect addressing, indexed addressing, bit addressing and instruction addressing. It can be divided into two categories: operand addressing and instruction addressing.

The addressing space and range of immediate addressing are: in the program storage space, read in MOV A with the instruction, #46H

The addressing space and range of direct addressing are: on-chip RAM, lower 128 bytes and SFR MOV A, 46H

The addressing space and range of register addressing are: use R0~R7, A, B, C, DPTR MOV A, R2

The addressing space and range of register indirect addressing are: On-chip RAM: use @Ri, SP; range is 256B, excluding SFR, Off-chip RAM: use @Ri, @DPTR; range is 64KB MOV A, @R0 MOVX A, @DPTR

The addressing space and range of indexed addressing are: using @A+PC, @A+DPTR; in program memory;

The ranges are within 256B after PC and the full 64KB space MOVC A, @A+DPTR

The addressing space and range of bit addressing are: using bit address; in bit addressing space; RAM 20H ~ 2FH and SFR SETB 36H

The addressing space and range of the instruction absolute addressing are: the operand is the target address; in the program storage space;

The range is 2KB or 64KB full space AJMP FIRST LJMP SECON

The addressing space and range of instruction relative addressing are: operand is relative address; in program storage space; range -128 to 127 SJMP LOOP

Keywords:MCS-51 Reference address:What are the addressing modes of the MCS-51 microcontroller and how do they operate?

Previous article:Design of 16×16 LED Chinese Character Scrolling Display Screen Based on AT89C51 Single Chip Microcomputer
Next article:A brief description of the assembly instruction format of the MCS-51 microcontroller

Recommended ReadingLatest update time:2024-11-16 22:32

The Principle of Multi-machine Communication of MCS-51 Series Single-Chip Microcomputers
  Multi-machine communication refers to data transmission between two or more computers. Master-slave multi-machine communication is the simplest and most widely used type of multi-machine communication system.   Working principle: SM2 in the serial port control register SCON is the multi-machine communication contr
[Microcontroller]
The Principle of Multi-machine Communication of MCS-51 Series Single-Chip Microcomputers
MCS-51 MCU Assembly Language Study Notes
The difference between ACC and A The popular explanation is: ACC is the register with address E0H, and A is the standard accumulator without address When it is to be expressed as a bit, ACC must be used, for example, it should be written as ACC.7, not A.7; but when it is used as an 8-bit binary number, both ACC and A
[Microcontroller]
Interface design of bank queuing system based on I2C bus
This paper takes the existing queueing system of the bank as an example and proposes the interface design of the single-chip microcomputer queueing system based on the IIC bus. Through the simulation test of the system, it not only simplifies the design circuit, reduces the circuit board area, saves components in the
[Microcontroller]
Interface design of bank queuing system based on I2C bus
Application and error correction of microcontroller timer
1 Introduction The timer is a very important part of the MCS-51 microcontroller. Since its application is related to other hardware of the microcontroller, there is a certain complexity . The timer is the most effective method to solve certain types of complex problems in microcontroller applications, and it is widel
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号