View this week's entry ad »
Part Inventory
powered by:
Part Finder
Go
powered by:
  • Quick Poll
What Social Networking site do you use the most?



VOTE VIEW RESULTS
Previous Polls
Hotspots » Analog & Mixed SignalPowerEmbedded

Premium Content

Editors' Picks

Featured Industry Resources

Use Four External Interrupts Through One 8051 Input

By Yuri Magda

May 13, 2002

Print
Reprints Comment Subscribe

The 8051-compatible microcontrollers are equipped with up to two inputs that may be used as general-purpose interrupts. A simple way to increase the number of interrupt inputs is shown in the figure. The 74LS08 chip provides up to four interrupt inputs through the standard INT0 input.

This circuit is built so that Interrupt 1 has the highest priority and Interrupt 4 has the lowest priority. Intel standard assembler is used for the demonstration program shown in the code listing. The program code allows masking of the unusable or undesirable interrupts. Here, the variable IE_MASK is used to hide the interrupts by setting the appropriate bits of the high-order nibble to "1." Each time the corresponding interrupt is implemented, the interrupt handler switches on the appropriate LED.

You see from the code that Interrupts 2 and 3 are disabled, so only 1 and 4 will be processed. Of course, the program code is only a skeleton for more complicated applications that readers can build.

To download a listing, click Download the Code below.

Download the code.

Average ( Ratings):
Filed Under:

Check for price and availability on Source ESB:

Go
powered by  

Related Products

1 comments
Add A Comment\(Log in or create an account\)
  • January 06, 2010 07:01 AM

    by TheDocta

    Great methodology, and I fully intend to use it but I can't seem to find the code listing you mention. I read this article last month and the listing was there so it must have been removed. Would it be possible to re-post it or send me a copy at emblazer@hotmail.com?

    Thanks

    Euan Macrae

You must log on before posting a comment.

Are you a new visitor? Register Now

Acceptable Use Policy

Sponsored Links