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

C8051F310 参数 Datasheet PDF下载

C8051F310图片预览
型号: C8051F310
PDF下载: 下载PDF文件 查看货源
内容描述: 8/16 KB ISP功能的Flash MCU系列 [8/16 kB ISP Flash MCU Family]
分类和应用: 微控制器和处理器
文件页数/大小: 228 页 / 2504 K
品牌: SILABS [ SILICON LABORATORIES ]
 浏览型号C8051F310的Datasheet PDF文件第200页浏览型号C8051F310的Datasheet PDF文件第201页浏览型号C8051F310的Datasheet PDF文件第202页浏览型号C8051F310的Datasheet PDF文件第203页浏览型号C8051F310的Datasheet PDF文件第205页浏览型号C8051F310的Datasheet PDF文件第206页浏览型号C8051F310的Datasheet PDF文件第207页浏览型号C8051F310的Datasheet PDF文件第208页  
C8051F310/1/2/3/4/5/6/7
18.1. PCA Counter/Timer
The 16-bit PCA counter/timer consists of two 8-bit SFRs: PCA0L and PCA0H. PCA0H is the high byte
(MSB) of the 16-bit counter/timer and PCA0L is the low byte (LSB). Reading PCA0L automatically latches
the value of PCA0H into a “snapshot” register; the following PCA0H read accesses this “snapshot” register.
Reading the PCA0L Register first guarantees an accurate reading of the entire 16-bit PCA0 counter.
Reading PCA0H or PCA0L does not disturb the counter operation. The CPS2-CPS0 bits in the PCA0MD
register select the timebase for the counter/timer as shown in Table 18.1.
Note that in ‘External oscillator
source divided by 8’ mode, the external oscillator source is synchronized with the system clock,
and must have a frequency less than or equal to the system clock.
When the counter/timer overflows from 0xFFFF to 0x0000, the Counter Overflow Flag (CF) in PCA0MD is
set to logic 1 and an interrupt request is generated if CF interrupts are enabled. Setting the ECF bit in
PCA0MD to logic 1 enables the CF flag to generate an interrupt request. The CF bit is not automatically
cleared by hardware when the CPU vectors to the interrupt service routine, and must be cleared by soft-
ware (Note: PCA0 interrupts must be globally enabled before CF interrupts are recognized. PCA0 inter-
rupts are globally enabled by setting the EA bit (IE.7) and the EPCA0 bit in EIE1 to logic 1). Clearing the
CIDL bit in the PCA0MD register allows the PCA to continue normal operation while the CPU is in Idle
mode.
Table 18.1. PCA Timebase Input Options
CPS2
0
0
0
0
1
1
CPS1
0
0
1
1
0
0
CPS0
0
1
0
1
0
1
Timebase
System clock divided by 12
System clock divided by 4
Timer 0 overflow
High-to-low transitions on ECI (max rate = system clock divided by 4)
System clock
External oscillator source divided by 8*
*Note:
External oscillator source divided by 8 is synchronized with the system clock.
IDLE
PCA0MD
C
W
W
I
D
D
D
T
L
L
E
C
K
PCA0CN
C
C
F
R
C
P
S
2
C
C
E
P
P
C
S
S
F
1
0
C
C
F
4
C
C
F
3
C
C
F
2
C
C
C
C
F
F
1
0
PCA0L
read
To SFR Bus
Snapshot
Register
SYSCLK/12
000
001
010
011
0
1
SYSCLK/4
Timer 0 Overflow
ECI
PCA0H
PCA0L
Overflow
To PCA Interrupt System
CF
SYSCLK
100
101
External Clock/8
To PCA Modules
Figure 18.2. PCA Counter/Timer Block Diagram
204
Rev. 1.7