参数资料
型号: PIC16F870-E/SP
厂商: Microchip Technology
文件页数: 3/143页
文件大小: 0K
描述: IC MCU CMOS 20MHZ 2K FLASH 28DIP
产品培训模块: Asynchronous Stimulus
标准包装: 15
系列: PIC® 16F
核心处理器: PIC
芯体尺寸: 8-位
速度: 20MHz
连通性: UART/USART
外围设备: 欠压检测/复位,POR,PWM,WDT
输入/输出数: 22
程序存储器容量: 3.5KB(2K x 14)
程序存储器类型: 闪存
EEPROM 大小: 64 x 8
RAM 容量: 128 x 8
电压 - 电源 (Vcc/Vdd): 4 V ~ 5.5 V
数据转换器: A/D 5x10b
振荡器型: 外部
工作温度: -40°C ~ 125°C
封装/外壳: 28-DIP(0.300",7.62mm)
包装: 管件
配用: I3-DB16F871-ND - BOARD DAUGHTER ICEPIC3
PIC16F870/871
DS30569B-page 98
2003 Microchip Technology Inc.
11.11 Context Saving During Interrupts
During an interrupt, only the return PC value is saved
on the stack. Typically, users may wish to save key reg-
isters during an interrupt, (i.e., W register and STATUS
register). This will have to be implemented in software.
For the PIC16F870/871 devices, the register W_TEMP
must be defined in both banks 0 and 1 and must be
defined at the same offset from the bank base address
(i.e., If W_TEMP is defined at 0x20 in bank 0, it must
also be defined at 0xA0 in bank 1). The registers,
PCLATH_TEMP and STATUS_TEMP, are only defined
in bank 0.
Since the upper 16 bytes of each bank are common in
the PIC16F870/871 devices, temporary holding regis-
ters W_TEMP, STATUS_TEMP, and PCLATH_TEMP
should be placed in here. These 16 locations don’t
require banking and therefore, make it easier for con-
text save and restore. The same code shown in
Example 11-1 can be used.
EXAMPLE 11-1:
SAVING STATUS, W, AND PCLATH REGISTERS IN RAM
MOVWF
W_TEMP
;Copy W to TEMP register
SWAPF
STATUS,W
;Swap status to be saved into W
CLRF
STATUS
;bank 0, regardless of current bank, Clears IRP,RP1,RP0
MOVWF
STATUS_TEMP
;Save status to bank zero STATUS_TEMP register
MOVF
PCLATH, W
;Only required if using pages 1, 2 and/or 3
MOVWF
PCLATH_TEMP
;Save PCLATH into W
CLRF
PCLATH
;Page zero, regardless of current page
:
:(ISR)
;(Insert user code here)
:
MOVF
PCLATH_TEMP, W
;Restore PCLATH
MOVWF
PCLATH
;Move W into PCLATH
SWAPF
STATUS_TEMP,W
;Swap STATUS_TEMP register into W
;(sets bank to original state)
MOVWF
STATUS
;Move W into STATUS register
SWAPF
W_TEMP,F
;Swap W_TEMP
SWAPF
W_TEMP,W
;Swap W_TEMP into W
相关PDF资料
PDF描述
PIC16F870-E/SO IC MCU CMOS 20MHZ 2K FLSH 28SOIC
PIC16LCE624-04/P IC MCU OTP 1KX14 EE 18DIP
VI-BNP-IX-S CONVERTER MOD DC/DC 13.8V 75W
PIC16LC711-04E/SS IC MCU OTP 1KX14 A/D 20SSOP
PIC16CE625-04I/SS IC MCU OTP 2KX14 EE COMP 20SSOP
相关代理商/技术参数
参数描述
PIC16F870-I/SO 功能描述:8位微控制器 -MCU 3.5KB 128 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 处理器系列:C8051F39x 数据总线宽度:8 bit 最大时钟频率:50 MHz 程序存储器大小:16 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:1.8 V to 3.6 V 工作温度范围:- 40 C to + 105 C 封装 / 箱体:QFN-20 安装风格:SMD/SMT
PIC16F870-I/SO 制造商:Microchip Technology Inc 功能描述:8BIT FLASH MCU SMD 16F870 SOIC28
PIC16F870-I/SP 功能描述:8位微控制器 -MCU 3.5KB 128 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 处理器系列:C8051F39x 数据总线宽度:8 bit 最大时钟频率:50 MHz 程序存储器大小:16 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:1.8 V to 3.6 V 工作温度范围:- 40 C to + 105 C 封装 / 箱体:QFN-20 安装风格:SMD/SMT
PIC16F870-I/SP 制造商:Microchip Technology Inc 功能描述:IC 8BIT FLASH MCU 16F870 SDIL28
PIC16F870-I/SS 功能描述:8位微控制器 -MCU 3.5KB 128 RAM 22 I/O RoHS:否 制造商:Silicon Labs 核心:8051 处理器系列:C8051F39x 数据总线宽度:8 bit 最大时钟频率:50 MHz 程序存储器大小:16 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:1.8 V to 3.6 V 工作温度范围:- 40 C to + 105 C 封装 / 箱体:QFN-20 安装风格:SMD/SMT