摘要
由于PIC16F 877单片机没有设置外部的中断优先级,提出了一种用74LS148优先权编码器来扩展PIC16F 877单片机的外部中断源。当PIC16F 877单片机外部有多个中断源中断请求时,74LS148优先权编码器首先对这些中断源进行优先级排序,把优先级别高的中断送入单片机中断入口,让单片机响应中断级别高的中断请求,处理完这一中断后返回,等待下一轮中断请求。给出了PIC16F 877和74LS148的硬件连接图和中断服务子程序。
As PIC16F877 has no priority of outer interruption requests,a method of using priority encoder 74LS148 to expand its outer interruption requests is proposed' When there are several outer interruption requests,74LS 148 sorts them according to their priorities first,the request with higher priority is then sent to the interruption input of PIC16F877. When the interruption is processed completely,PIC16F 877 waits for next interruption request. The hardware connections between PIC168F 877 and 74LS 148,as well as the interruption service subroutine,are provided.
出处
《电力自动化设备》
EI
CSCD
北大核心
2007年第4期115-117,共3页
Electric Power Automation Equipment
关键词
优先权编码器
外部中断源
中断服务子程序
priority encoder
outer interrupt request
interrupt service subroutine