參數(shù)資料
型號(hào): PIC16C642
廠商: Microchip Technology Inc.
英文描述: 8-Bit EPROM Microcontrollers with Analog Comparators(每個(gè)I/O口有25mA驅(qū)動(dòng)/吸收電流,可編程Vref,微控制器)
中文描述: 8位EPROM微控制器與模擬比較器(每個(gè)的I / O口有25毫安驅(qū)動(dòng)/吸收電流,可編程Vref的,微控制器)
文件頁數(shù): 66/136頁
文件大?。?/td> 837K
代理商: PIC16C642
PIC16C64X & PIC16C66X
DS30559A-page 66
Preliminary
1996 Microchip Technology Inc.
9.5
Interrupts
The PIC16C641 and PIC16C642 have four sources of
interrupt, while the PIC16C661 and PIC16C662 have
five sources:
External interrupt RB0/INT
TMR0 overflow interrupt
PORTB change interrupts (pins RB7:RB4)
Comparator interrupt
Parallel Slave Port interrupt (PIC16C661/662)
The interrupt control register, (INTCON), records
individual core interrupt requests in flag bits. It also has
various individual enable bits and the global interrupt
enable bit.
The global interrupt enable bit, GIE (INTCON<7>)
enables (if set) all un-masked interrupts or disables (if
cleared) all interrupts. Individual interrupts can be
disabled through their corresponding enable bits in
INTCON register. GIE is cleared on reset.
The “return from interrupt” instruction,
RETFIE
, exits
the interrupt routine as well as sets the GIE bit, which
allows any pending interrupt to execute.
Those interrupts associated with the “core” have their
flag and enable bits in the INTCON register. The core
interrupts are: RB0/INT pin interrupt, the RB port
change interrupt, and the TMR0 overflow interrupt. The
INTCON register also contains the Peripheral Interrupt
Enable bit, PEIE. Bit PEIE will enable/mask the periph-
eral interrupts (CM and PSP) from vectoring when bit
PEIE is set/cleared.
Flag bits PSPIF and CMIF are contained in special
function register PIR1. The corresponding interrupt
enable bits (PSPIE and CMIE) are contained in special
function register PIE1.
When an interrupt is responded to, the GIE is cleared
to disable any further interrupt, the return address is
pushed into the stack and the PC is loaded with 0004h.
Once in the interrupt service routine the source(s) of
the interrupt can be determined by polling the interrupt
flag bits. The interrupt flag bit(s) must be cleared in
software before re-enabling interrupts to avoid recur-
sive interrupts.
For external interrupt events, such as the RB0/INT or
Port RB change interrupt, the interrupt latency will be
three or four instruction cycles. The exact latency
depends when the interrupt event occurs (Figure 9-16).
The latency is the same for one or two cycle
instructions. Once in the interrupt service routine the
source(s) of the interrupt can be determined by polling
the interrupt flag bits. The interrupt flag bit(s) must be
cleared in software before re-enabling interrupts to
avoid multiple interrupt requests. Individual interrupt
flag bits are set regardless of the status of their
corresponding mask bit or the GIE bit.
Note 1:
Individual interrupt flag bits are set regard-
less of the status of their corresponding
mask bit or the GIE bit.
Note 2:
When an instruction that clears the GIE bit
is executed, any interrupts that were
pending for execution in the next cycle are
ignored. The CPU will execute a NOP in
the cycle immediately following the
instruction which clears the GIE bit. The
interrupts which were ignored are still
pending to be serviced when the GIE bit is
set again.
FIGURE 9-15: INTERRUPT LOGIC
RBIF
RBIE
T0IF
T0IE
INTF
INTE
GIE
CMIE
Wake-up
(If in SLEEP mode)
Interrupt
to CPU
CMIF
PSPIE
(1)
PSPIF
(1)
PEIE
Note 1: The Parallel Slave Port is implemented on the PIC16C661 and PIC16C662 only.
相關(guān)PDF資料
PDF描述
PIC16C64A Using the 8-Bit Parallel Slave Port(每個(gè)I/O口有25mA驅(qū)動(dòng)/吸收電流,并行從動(dòng)口,1路捕捉/比較/PWM的微控制器)
PIC16C66 8-Bit CMOS Microcontrollers(每個(gè)I/O口有25mA驅(qū)動(dòng)/吸收電流,1路捕捉/比較/PWM的微控制器)
PIC16C67 8-Bit CMOS Microcontrollers(每個(gè)I/O口有25mA驅(qū)動(dòng)/吸收電流,1路捕捉/比較/PWM的微控制器)
PIC16C62 8-Bit CMOS Microcontrollers(每個(gè)I/O口有25mA驅(qū)動(dòng)/吸收電流,22個(gè)I/O,2.5V的微控制器)
PIC16C62A 8-Bit CMOS Microcontrollers(每個(gè)I/O口有25mA驅(qū)動(dòng)/吸收電流,22個(gè)I/O,2.5V的微控制器)
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
PIC16C642/JW 功能描述:8位微控制器 -MCU 7KB 176 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時(shí)鐘頻率:50 MHz 程序存儲(chǔ)器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16C642-04/SO 功能描述:8位微控制器 -MCU 7KB 176 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時(shí)鐘頻率:50 MHz 程序存儲(chǔ)器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16C642-04/SP 功能描述:8位微控制器 -MCU 7KB 176 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時(shí)鐘頻率:50 MHz 程序存儲(chǔ)器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16C642-04E/SO 功能描述:8位微控制器 -MCU 7KB 176 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時(shí)鐘頻率:50 MHz 程序存儲(chǔ)器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16C642-04E/SP 功能描述:8位微控制器 -MCU 7KB 176 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時(shí)鐘頻率:50 MHz 程序存儲(chǔ)器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT