CHAPTER 8 8-BIT TIMER/EVENT COUNTERS 2 TO 5
User’s Manual U15905EJ2V1UD
248
8.4.2
Operation as external event counter (8 bits)
The external event counter counts the number of clock pulses input to the TIn pin from an external source by using
8-bit timer counter n (TMn).
Each time the valid edge specified by timer clock selection register n (TCLn) is input to the TIn pin, the TMn
register is incremented. Either the rising edge or the falling edge can be specified as the valid edge.
When the count value of the TMn register matches the value of 8-bit timer compare register n (CRn), the TMn
register is cleared to 0 and an interrupt request signal (INTTMn) is generated.
Setting method
<1>
Set each register.
TCLn register: Selects the TIn input edge.
Falling edge of TIn pin
→ TLCn = 00H
Rising edge of TIn pin
→ TCLn = 01H
CRn register: Compare value (N)
TMCn register: Stops count operation, selects the mode in which clear & start occurs on a match
between the TMn register and CRn register, disables timer output F/F inversion
operation, and disables timer output.
(TMCn register = 0000xx00B,
×: don’t care)
<2>
When the TMCEn bit of the TMCn register is set to 1, the counter counts the number of pulses input from
TIn.
<3>
When the values of the TMn register and CRn register match, INTTMn is generated (TMn register is
cleared to 00H).
<4>
Then, INTTMn is generated each time the values of the TMn register and CRn register match.
INTTMn is generated when the valid edge of TIn is input N + 1 times: N = 00 to FFH
Caution
During external event counter operation, do not rewrite the value of the CRn register.
Remark
n = 2 to 5
Figure 8-3. Timing of External Event Counter Operation (with Rising Edge Specified)
00H
01H
02H
03H
04H
05H
N 1
N
00H
01H
02H
03H
TIn
CRn
INTTMn
TMCEn
TMn count value
Count start
Remark
n = 2 to 5
相关PDF资料
XF2L-0535-1 CONN FPC 5POS 0.5MM SMT
PIC18LF23K22-I/SS IC PIC MCU 8KB FLASH 28SSOP
PIC16LF1933-I/ML IC PIC MCU FLASH 4K 28-QFN
PIC16F1933-I/ML IC MCU 8BIT FLASH 28-QFN
PIC16F785-I/ML IC PIC MCU FLASH 2KX14 20QFN
XF2L-0425-1 CONN FPC 4POS 0.5MM SMT
PIC16F1933-I/MV IC MCU 8BIT FLASH 28-UQFN
PIC16F785-I/SO IC PIC MCU FLASH 2KX14 20SOIC
相关代理商/技术参数
PIC24F08KL302-I/SP 功能描述:16位微控制器 - MCU 8KB FLASH 1KB RAM 256B 3V RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT
PIC24F08KL302-I/SS 功能描述:16位微控制器 - MCU 8KB FLASH 1KB RAM 512B 3V 10-BIT ADC RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT
PIC24F08KL302T-I/ML 功能描述:16位微控制器 - MCU 8KB FLASH 1KB RAM 512B 3V 10-BIT ADC RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT
PIC24F08KL302T-I/MQ 功能描述:16位微控制器 - MCU 8KB FL 1KB RAM 256B 3V RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT
PIC24F08KL302T-I/SO 功能描述:16位微控制器 - MCU 8KB FLASH 1KB RAM 512B 3V 10-BIT ADC RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT
PIC24F08KL302T-I/SS 功能描述:16位微控制器 - MCU 8KB FLASH 1KB RAM 512B 3V 10-BIT ADC RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT
PIC24F08KL401 制造商:MICROCHIP 制造商全称:Microchip Technology 功能描述:Low-Power, Low-Cost, General Purpose 16-Bit Flash Microcontrollers with nanoWatt XLP Technology
PIC24F08KL401-I/MQ 功能描述:16位微控制器 - MCU 8KB FLASH 1KB RAM 512B 3V 10-BIT ADC RoHS:否 制造商:Texas Instruments 核心:RISC 处理器系列:MSP430FR572x 数据总线宽度:16 bit 最大时钟频率:24 MHz 程序存储器大小:8 KB 数据 RAM 大小:1 KB 片上 ADC:Yes 工作电源电压:2 V to 3.6 V 工作温度范围:- 40 C to + 85 C 封装 / 箱体:VQFN-40 安装风格:SMD/SMT