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

12F5101 参数 Datasheet PDF下载

12F5101图片预览
型号: 12F5101
PDF下载: 下载PDF文件 查看货源
内容描述: - 12号的铝制车身绘( RAL 7032 ) []
分类和应用:
文件页数/大小: 114 页 / 1604 K
品牌: ETC [ ETC ]
 浏览型号12F5101的Datasheet PDF文件第40页浏览型号12F5101的Datasheet PDF文件第41页浏览型号12F5101的Datasheet PDF文件第42页浏览型号12F5101的Datasheet PDF文件第43页浏览型号12F5101的Datasheet PDF文件第45页浏览型号12F5101的Datasheet PDF文件第46页浏览型号12F5101的Datasheet PDF文件第47页浏览型号12F5101的Datasheet PDF文件第48页  
PIC12F510/16F506  
To change prescaler from the WDT to the Timer0  
module, use the sequence shown in Example 6-2. This  
sequence must be used even if the WDT is disabled. A  
CLRWDT instruction should be executed before  
switching the prescaler.  
6.2.1  
SWITCHING PRESCALER  
ASSIGNMENT  
The prescaler assignment is fully under software  
control (i.e., it can be changed “on-the-fly” during pro-  
gram execution). To avoid an unintended device Reset,  
the following instruction sequence (Example 6-1) must  
be executed when changing the prescaler assignment  
from Timer0 to the WDT.  
EXAMPLE 6-2:  
CHANGING PRESCALER  
(WDTTIMER0)  
CLRWDT  
;Clear WDT and  
;prescaler  
EXAMPLE 6-1:  
CHANGING PRESCALER  
(TIMER0 WDT)  
;Clear WDT  
MOVLW ‘xxxx0xxx’ ;Select TMR0, new  
;prescale value and  
;clock source  
CLRWDT  
CLRF  
TMR0  
;Clear TMR0 & Prescaler  
OPTION  
MOVLW ‘00xx1111’b ;These 3 lines (5, 6, 7)  
OPTION  
;are required only if  
;desired  
CLRWDT  
;PS<2:0> are 000 or 001  
MOVLW ‘00xx1xxx’b ;Set Postscaler to  
OPTION  
;desired WDT rate  
FIGURE 6-5:  
BLOCK DIAGRAM OF THE TIMER0/WDT PRESCALER  
(2)  
T0CKI  
Pin  
TCY (= FOSC/4)  
Data Bus  
8
0
M
U
X
1
1
0
M
U
X
Comparator  
Output  
Sync  
2
Cycles  
1
TMR0 Reg  
0
(1)  
(1)  
T0SE  
T0CS  
(1)  
PSA  
(3)  
C1T0CS  
0
1
8-bit Prescaler  
M
U
X
8
Watchdog  
Timer  
(1)  
8-to-1 MUX  
PS<2:0>  
(1)  
PSA  
1
0
WDT Enable bit  
(1)  
MUX  
PSA  
WDT  
Time-Out  
Note 1: T0CS, T0SE, PSA, PS<2:0> are bits in the OPTION register.  
2: T0CKI is shared with pin GP2 on the PIC12F510 and shared with RC5 on the PIC16F506.  
3: Bit C1T0CS is located in the CM1CON0 register.  
DS41268B-page 42  
Preliminary  
© 2006 Microchip Technology Inc.  
 复制成功!