欢迎访问ic37.com |
会员登录 免费注册
发布采购

PIC16F716-I-P 参数 Datasheet PDF下载

PIC16F716-I-P图片预览
型号: PIC16F716-I-P
PDF下载: 下载PDF文件 查看货源
内容描述: 8位闪存单片机与A / D转换器和增强型捕捉/比较/ PWM [8-bit Flash-based Microcontroller with A/D Converter and Enhanced Capture/Compare/PWM]
分类和应用: 转换器闪存微控制器
文件页数/大小: 136 页 / 2598 K
品牌: MICROCHIP [ MICROCHIP ]
 浏览型号PIC16F716-I-P的Datasheet PDF文件第16页浏览型号PIC16F716-I-P的Datasheet PDF文件第17页浏览型号PIC16F716-I-P的Datasheet PDF文件第18页浏览型号PIC16F716-I-P的Datasheet PDF文件第19页浏览型号PIC16F716-I-P的Datasheet PDF文件第21页浏览型号PIC16F716-I-P的Datasheet PDF文件第22页浏览型号PIC16F716-I-P的Datasheet PDF文件第23页浏览型号PIC16F716-I-P的Datasheet PDF文件第24页  
PIC16F716  
EXAMPLE 2-2:  
HOW TO CLEAR RAM  
USING INDIRECT  
ADDRESSING  
2.5  
Indirect Addressing, INDF and  
FSR Registers  
The INDF register is not a physical register. Addressing  
INDF actually addresses the register whose address is  
contained in the FSR register (FSR is a pointer). This is  
indirect addressing.  
MOVLW 0x20  
MOVWF FSR  
CLRF INDF  
INCF FSR  
;initialize pointer  
;to RAM  
;clear RAM & FSR  
;inc pointer  
NEXT  
BTFSS FSR,4 ;all done?  
EXAMPLE 2-1:  
INDIRECT ADDRESSING  
GOTO  
NEXT  
;no, clear next  
;yes, continue  
CONTINUE  
• Register file 05 contains the value 10h  
• Register file 06 contains the value 0Ah  
• Load the value 05 into the FSR register  
:
An effective 9-bit address is obtained by concatenating  
the 8-bit FSR register and the IRP bit of the STATUS  
register, as shown in Figure 2-4. However, IRP is not  
used in the PIC16F716.  
• A read of the INDF register will return the value of  
10h  
• Increment the value of the FSR register by one  
(FSR = 06)  
• A read of the INDR register now will return the  
value of 0Ah.  
Reading INDF itself indirectly (FSR = 0) will produce  
00h. Writing to the INDF register indirectly results in a  
no-operation (although Status bits may be affected).  
A simple program to clear RAM locations 20h-2Fh  
using indirect addressing is shown in Example 2-2.  
FIGURE 2-4:  
DIRECT/INDIRECT ADDRESSING  
Direct Addressing  
from opcode  
Indirect Addressing  
RP1:  
7
RP0  
6
0
0
IRP  
FSR register  
(2)  
(2)  
bank select  
location select  
bank select  
location select  
00  
01  
80h  
10  
100h  
11  
00h  
180h  
(3)  
(3)  
Data  
Memory  
(1)  
7Fh  
Bank 0  
Note 1: For register file map detail see Figure 2-2.  
FFh  
17Fh  
Bank 2  
1FFh  
Bank 3  
Bank 1  
2: Maintain clear for upward compatibility with future products.  
3: Not implemented.  
DS41206B-page 18  
© 2007 Microchip Technology Inc.  
 复制成功!