51 MCU interrupt entry address representation in C language

Publisher:SereneMeadowLatest update time:2016-09-22 Source: eefocus Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
Function type Function name (any) Interrupt ID (different numbers represent different interrupt entries)

For example:
void INT () interrupt 0 //External interrupt 0
{}
void INT () interrupt 1 //Timer/Counter 0
{}
void INT () interrupt 2 //External interrupt 1
{}
void INT () interrupt 3 //Timer/Counter 1
{}
void INT () interrupt 4 //Serial port
{}

 

interrupt X X indicates the interrupt number, 0 indicates external interrupt 0, 1 indicates timer 0 overflow interrupt, 2 indicates external interrupt 1 (/INT1), 3 indicates timer 1 overflow interrupt, 4 indicates serial port interrupt, 5 indicates timer 2 overflow interrupt. Some enhanced 51s may have other interrupt usages: void timer0_ISR(void) interrupt 1 { }
Reference address:51 MCU interrupt entry address representation in C language

Previous article:27. Basic application technology of ADC0809 A/D converter
Next article:Calling the 4*4 matrix keyboard module program

Recommended ReadingLatest update time:2024-11-16 18:02

51 MCU Pin Introduction
AT89C2051 is a simplified version of 51 MCU. It has only 20 pins and has removed the P0 and P2 ports. However, it has a very practical analog comparator integrated inside, which is particularly suitable for developing simplified 51 application systems. After all, when we develop simple products, we often cannot use all
[Microcontroller]
51 MCU internal timer usage
/*------------------------------ Function: generate pulse signal Author: Zhang Kaizhou Date: 2019-5-15 22:50:43 ------------------------------*/ #include reg51.h #define uchar unsigned char sbit output = P1^0; volatile period = 250; uchar high = 50; float tcount = 0; void timer0() interrupt 1 using 1 { TH0 = (6
[Microcontroller]
How to learn stc51 microcontroller, first master the STC microcontroller program burning method!
Today I am here to discuss with you the topic of how to learn the 51 microcontroller . When I studied the microcontroller course in college in 2008, the learning content mainly included the development history of the microcontroller, the framework of the microcontroller, the registers of the microcontroller, and the o
[Microcontroller]
51 MCU timer counter principle and application (square wave, pwm, pulse counting, high level pulse width measurement)
1.TMOD timer/counter working mode register When GATE=1, the timer is controlled by INT and TR and is used to measure the pulse width; 2.TCON timer/counter control register 3.   2. Application examples: 2.1T0/T1 controls the external pin to output square wave 1. Design idea: Set the timer counter to work in t
[Microcontroller]
51 MCU timer counter principle and application (square wave, pwm, pulse counting, high level pulse width measurement)
51 Basic Knowledge——Summary of 51 MCU (I)
Overview The 51 single-chip microcomputer is a single-chip microcomputer that is more suitable for beginners. It has a simple structure and is easy to learn. This blog is a small summary of the author's self-study of single-chip microcomputers. I also learned to use single-chip microcomputers, and encountered many se
[Microcontroller]
51 Basic Knowledge——Summary of 51 MCU (I)
Design and application research of power carrier module based on 89C52/C51 series microcontroller
PowerLine CarrierWave (PLCW) communication is a communication method that uses power lines to transmit information. Power carrier communication is widely used in the automatic collection and transmission of remote three-meter (water meter, electricity meter, gas meter) information, and is favored in the construction o
[Microcontroller]
Design and application research of power carrier module based on 89C52/C51 series microcontroller
51 single chip microcomputer LCD1602
      LCD1602 is a very simple human-computer interaction. With this guy, learning is no longer lonely, at least with this guy's company. The comments are very detailed, see the code.     Schematic diagram:             Code: #include reg52.h #define uint unsigned int #define uchar unsigned char //Port
[Microcontroller]
C8051F020 Single Chip Microcomputer and Its Application in Total Phosphorus Online Automatic Analyzer
1 Overview The C8051F0XX series of MCUs are a new type of mixed signal system-level MCU launched by Cygnal. This series of MCUs contains the CPU core of CIP-51, and its instruction system is fully compatible with MCS-51. The C8051F020 MCU contains 64kB on-chip Flash program memory, 4352B RAM, 8 I/O ports with a
[Microcontroller]
C8051F020 Single Chip Microcomputer and Its Application in Total Phosphorus Online Automatic Analyzer
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号