S3C2440 external interrupt response register setting method

Publisher:云淡风轻2014Latest update time:2019-11-06 Source: 51heiKeywords:S3C2440 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

If the following settings are not followed, the interrupt will not be executed or the next interrupt will not be entered.

/*Interrupt suspension setting, this process is added to the main function and loaded at startup*/

void Eint_wait()

{

   rSRCPND=rSRCPND; //Interrupt pending register clear

   rINTPND=rINTPND; //Interrupt source pending register clear

   rEINTPEND|=0x1<<13; //External interrupt pending register, Eint pending interrupt

   rSRCPND=BIT_EINT8_23; //Interrupt source pending register corresponding position 1 waiting for interrupt

   rINTPND=BIT_EINT8_23; //Interrupt pending register corresponding position 1 waiting for interrupt

}

/*End of interrupt suspend setup*/



/*The following is the processing procedure when responding to an interrupt, which is the function in the pISR pointer*/

void __irq Eint_Isr(void)

{

   if(rEINTPEND == (1<<13)) //When judging whether Eint13 has a response, execute as follows

   {

     rGPBDAT=0x0<<6; //led6 is on

     delay(10000); //Description: Since the edge triggering method is used, the edge process will be completed after the button is pressed. After completion, the else processing will be immediately entered and the light will be turned off. The naked eye may not be able to see it. In order to see the effect, the LED needs to be on for a while!

     rEINTPEND=(1<<13); //Set the interrupt suspend register Eint13 to 1 and wait for the next interrupt to arrive. If the next interrupt is not set, the program cannot enter.

   }

   else //When it is not Eint13, execute as follows

   {

     rGPBDAT=0x1<<6;

     rEINTPEND=(1<<13); //Set the interrupt suspend register Eint13 to 1 and wait for the next interrupt to arrive. If the next interrupt is not set, the program cannot enter.

   }

}


The above two parts are important contents of simplified interrupt processing, which can be used by modifying rGPBDAT and rEINTPEND according to the output pin. Other settings are not explained here. 


Keywords:S3C2440 Reference address:S3C2440 external interrupt response register setting method

Previous article:Samsung S3C2440A Nand Flash Mapping
Next article:S3C2440 development board uses external interrupts to implement button switching of different functions

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

LCD display of ARM9 (S3C2440) - theoretical knowledge
       Today I would like to discuss the LCD display problem of S3C2440 with you. I hope you can give me more advice. If I say something wrong, I hope you can help me correct it in time so that I can increase my knowledge and not cause inconvenience to others' learning. Haha Let me first take a look at an article I fo
[Microcontroller]
S3C2440 bare metal assembly lights up the LED light
Virtual machine environment: Oracle VM VirtualBox Linux system: ubuntu_14.04.6 Cross-compilation tools: (https://eyun.baidu.com/s/3b1UtLc) All files shared by 100ask 002_JZ2440 Data CD_20180516 (free) Data CD Disk A tools.zip arm-linux-gcc-4.3.2.tar.bz2 gcc-3.4.5-glibc-2.3.6/bin Step 1: View the Schematic O
[Microcontroller]
S3C2440 bare metal assembly lights up the LED light
How to determine the address space used by peripherals
The S3C2410/S3C2440 storage controller has the following features: 1. The address space of each BANK is 128MB, totaling 1GB (8 BANKs); 2. Programmable control bus width (8/16/32-bit), but BANK0 can only choose two bit widths (16/32-bit); 3. There are 8 banks in total, BANK0~BANK5 can support external ROM, SRAM,
[Microcontroller]
How to determine the address space used by peripherals
Understanding of link address 0x30008000 (S3C2440)
When we write the linker script, we will set the starting link address of the code segment to 0x30008000 (S3C2440). If you misunderstand the link address, you may encounter problems like mine. Q: The link address written in the gboot linker script is actually 0x30008000 in the memory. When the cross-tool is used to
[Microcontroller]
S3C2440 LED Driver Summary
1. Circuit Diagram 2. Instructions for use Code language: javascript This driver implements two operating modes: Normal operation mode: ./LedTest led1/led2/led3 on/off Turn on or off a certain LED Mask operation mode: ./LedTest
[Microcontroller]
S3C2440 LED Driver Summary
05-S3C2440 learning kernel (porting) linux3.4.2 porting (3) support DM9000C network card and modify support serial port 2
We have previously cut and transplanted the linux3.4.2 kernel http://blog.csdn.net/fengyuwuzu0519/article/details/70162666 I also learned how to port the DM9000C network card driver to the linux2.2.26 kernel http://blog.csdn.net/fengyuwuzu0519/article/details/72821567 Next, based on this, we transplant the DM9000c
[Microcontroller]
05-S3C2440 learning kernel (porting) linux3.4.2 porting (3) support DM9000C network card and modify support serial port 2
S3C2440 bare metal serial port
Preface Based on JZ2440 development board 1. Mind map 2. Code 1.uart.c The code is as follows (example): /****************************************************** *********************** * * File name: uart.c * * Function: Enter characters on the keyboard, and the information will be printed on the interface throu
[Microcontroller]
S3C2440 bare metal serial port
S3C2440 AD Converter
       The 10-bit CMOS ADC (Analog/Digital Converter) is an 8-channel analog input recirculation type device. It converts the analog input signal into a 10-bit binary The A/D converter supports on-chip sample-and-hold functions and power-down mode operation.   The touch screen will be in the next article. ADC c
[Microcontroller]
S3C2440 AD Converter
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号