參數(shù)資料
型號: PIC16CR74T-I/PT
廠商: Microchip Technology
文件頁數(shù): 31/172頁
文件大小: 0K
描述: IC PIC MCU 4KX14 44TQFP
標準包裝: 1,200
系列: PIC® 16C
核心處理器: PIC
芯體尺寸: 8-位
速度: 20MHz
連通性: I²C,SPI,UART/USART
外圍設(shè)備: 欠壓檢測/復(fù)位,POR,PWM,WDT
輸入/輸出數(shù): 33
程序存儲器容量: 7KB(4K x 14)
程序存儲器類型: ROM
RAM 容量: 192 x 8
電壓 - 電源 (Vcc/Vdd): 2 V ~ 5.5 V
數(shù)據(jù)轉(zhuǎn)換器: A/D 8x8b
振蕩器型: 內(nèi)部
工作溫度: -40°C ~ 85°C
封裝/外殼: 44-TQFP
包裝: 帶卷 (TR)
PIC18F2220/2320/4220/4320
DS39599G-page 124
2007 Microchip Technology Inc.
12.4
Timer1 Interrupt
The TMR1 register pair (TMR1H:TMR1L) increments
from 0000h to FFFFh and rolls over to 0000h. The
Timer1 interrupt, if enabled, is generated on overflow
which is latched in interrupt flag bit, TMR1IF
(PIR1<0>). This interrupt can be enabled/disabled by
setting/clearing Timer1 interrupt enable bit, TMR1IE
(PIE1<0>).
12.5
Resetting Timer1 Using a CCP
Trigger Output
If the CCP module is configured in Compare mode to
generate a “Special Event Trigger” (CCP1M3:CCP1M0
= 1011), this signal will reset Timer1 and start an A/D
conversion if the A/D module is enabled (see
information).
Timer1 must be configured for either Timer or Synchro-
nized Counter mode to take advantage of this feature.
If Timer1 is running in Asynchronous Counter mode,
this Reset operation may not work.
In the event that a write to Timer1 coincides with a
Special Event Trigger from CCP1, the write will take
precedence.
In this mode of operation, the CCPR1H:CCPR1L
register pair effectively becomes the period register for
Timer1.
12.6
Timer1 16-Bit Read/Write Mode
Timer1 can be configured for 16-bit reads and writes
(see Figure 12-2). When the RD16 control bit
(T1CON<7>) is set, the address for TMR1H is mapped
to a buffer register for the high byte of Timer1. A read
from TMR1L will load the contents of the high byte of
Timer1 into the Timer1 high byte buffer. This provides
the user with the ability to accurately read all 16 bits of
Timer1 without having to determine whether a read of
the high byte, followed by a read of the low byte, is valid
due to a rollover between reads.
A write to the high byte of Timer1 must also take place
through the TMR1H Buffer register. Timer1 high byte is
updated with the contents of TMR1H when a write
occurs to TMR1L. This allows a user to write all 16 bits
to both the high and low bytes of Timer1 at once.
The high byte of Timer1 is not directly readable or writ-
able in this mode. All reads and writes must take place
through the Timer1 High Byte Buffer register. Writes to
TMR1H do not clear the Timer1 prescaler. The
prescaler is only cleared on writes to TMR1L.
12.7
Using Timer1 as a Real-Time
Clock
Adding an external LP oscillator to Timer1 (such as the
above), gives users the option to include RTC function-
ality to their applications. This is accomplished with an
inexpensive watch crystal to provide an accurate time
base and several lines of application code to calculate
the time. When operating in Sleep mode and using a
battery or supercapacitor as a power source, it can
completely eliminate the need for a separate RTC
device and battery backup.
The application code routine, RTCisr, shown in
Example 12-1, demonstrates a simple method to
increment a counter at one-second intervals using an
Interrupt Service Routine. Incrementing the TMR1 reg-
ister pair to overflow, triggers the interrupt and calls the
routine, which increments the seconds counter by one;
additional counters for minutes and hours are
incremented as the previous counter overflow.
Since the register pair is 16 bits wide, counting up to
overflow the register directly from a 32.768 kHz clock
would take 2 seconds. To force the overflow at the
required one-second intervals, it is necessary to pre-
load it; the simplest method is to set the MSbit of
TMR1H with a BSF instruction. Note that the TMR1L
register is never preloaded or altered; doing so may
introduce cumulative error over many cycles.
For this method to be accurate, Timer1 must operate in
Asynchronous mode and the Timer1 overflow interrupt
must be enabled (PIE1<0> = 1) as shown in the rou-
tine, RTCinit. The Timer1 oscillator must also be
enabled and running at all times.
Note:
The Special Event Triggers from the CCP1
module will not set interrupt flag bit,
TMR1IF (PIR1<0>).
相關(guān)PDF資料
PDF描述
PIC16F627A-I/ML IC MCU FLASH 1KX14 EEPROM 28QFN
PIC24F08KL401-I/P IC MCU 16BIT 8KB FLASH 20-PDIP
PIC16LF727-I/P IC PIC MCU FLASH 8K 1.8V 40-DIP
PIC12C672-10/SM IC MCU OTP 2KX14 A/D 8-SOIJ
PIC16LF628A-I/P IC MCU FLASH 2KX14 EEPROM 18DIP
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
PIC16CR76-I/ML 功能描述:IC PIC MCU 8KX14 28QFN RoHS:是 類別:集成電路 (IC) >> 嵌入式 - 微控制器, 系列:PIC® 16C 產(chǎn)品培訓(xùn)模塊:XLP Deep Sleep Mode 8-bit PIC® Microcontroller Portfolio 標準包裝:22 系列:PIC® XLP™ 18F 核心處理器:PIC 芯體尺寸:8-位 速度:48MHz 連通性:I²C,SPI,UART/USART,USB 外圍設(shè)備:欠壓檢測/復(fù)位,POR,PWM,WDT 輸入/輸出數(shù):14 程序存儲器容量:8KB(4K x 16) 程序存儲器類型:閃存 EEPROM 大小:256 x 8 RAM 容量:512 x 8 電壓 - 電源 (Vcc/Vdd):1.8 V ~ 5.5 V 數(shù)據(jù)轉(zhuǎn)換器:A/D 11x10b 振蕩器型:內(nèi)部 工作溫度:-40°C ~ 85°C 封裝/外殼:20-DIP(0.300",7.62mm) 包裝:管件 產(chǎn)品目錄頁面:642 (CN2011-ZH PDF) 配用:DV164126-ND - KIT DEVELOPMENT USB W/PICKIT 2DM164127-ND - KIT DEVELOPMENT USB 18F14/13K50AC164112-ND - VOLTAGE LIMITER MPLAB ICD2 VPP
PIC16CR76-I/SO 功能描述:IC PIC MCU 8KX14 28SOIC RoHS:是 類別:集成電路 (IC) >> 嵌入式 - 微控制器, 系列:PIC® 16C 產(chǎn)品培訓(xùn)模塊:XLP Deep Sleep Mode 8-bit PIC® Microcontroller Portfolio 標準包裝:22 系列:PIC® XLP™ 18F 核心處理器:PIC 芯體尺寸:8-位 速度:48MHz 連通性:I²C,SPI,UART/USART,USB 外圍設(shè)備:欠壓檢測/復(fù)位,POR,PWM,WDT 輸入/輸出數(shù):14 程序存儲器容量:8KB(4K x 16) 程序存儲器類型:閃存 EEPROM 大小:256 x 8 RAM 容量:512 x 8 電壓 - 電源 (Vcc/Vdd):1.8 V ~ 5.5 V 數(shù)據(jù)轉(zhuǎn)換器:A/D 11x10b 振蕩器型:內(nèi)部 工作溫度:-40°C ~ 85°C 封裝/外殼:20-DIP(0.300",7.62mm) 包裝:管件 產(chǎn)品目錄頁面:642 (CN2011-ZH PDF) 配用:DV164126-ND - KIT DEVELOPMENT USB W/PICKIT 2DM164127-ND - KIT DEVELOPMENT USB 18F14/13K50AC164112-ND - VOLTAGE LIMITER MPLAB ICD2 VPP
PIC16CR76-I/SP 功能描述:IC PIC MCU 8KX14 28DIP RoHS:是 類別:集成電路 (IC) >> 嵌入式 - 微控制器, 系列:PIC® 16C 產(chǎn)品培訓(xùn)模塊:XLP Deep Sleep Mode 8-bit PIC® Microcontroller Portfolio 標準包裝:22 系列:PIC® XLP™ 18F 核心處理器:PIC 芯體尺寸:8-位 速度:48MHz 連通性:I²C,SPI,UART/USART,USB 外圍設(shè)備:欠壓檢測/復(fù)位,POR,PWM,WDT 輸入/輸出數(shù):14 程序存儲器容量:8KB(4K x 16) 程序存儲器類型:閃存 EEPROM 大小:256 x 8 RAM 容量:512 x 8 電壓 - 電源 (Vcc/Vdd):1.8 V ~ 5.5 V 數(shù)據(jù)轉(zhuǎn)換器:A/D 11x10b 振蕩器型:內(nèi)部 工作溫度:-40°C ~ 85°C 封裝/外殼:20-DIP(0.300",7.62mm) 包裝:管件 產(chǎn)品目錄頁面:642 (CN2011-ZH PDF) 配用:DV164126-ND - KIT DEVELOPMENT USB W/PICKIT 2DM164127-ND - KIT DEVELOPMENT USB 18F14/13K50AC164112-ND - VOLTAGE LIMITER MPLAB ICD2 VPP
PIC16CR76-I/SS 功能描述:IC PIC MCU 8KX14 28SSOP RoHS:是 類別:集成電路 (IC) >> 嵌入式 - 微控制器, 系列:PIC® 16C 產(chǎn)品培訓(xùn)模塊:XLP Deep Sleep Mode 8-bit PIC® Microcontroller Portfolio 標準包裝:22 系列:PIC® XLP™ 18F 核心處理器:PIC 芯體尺寸:8-位 速度:48MHz 連通性:I²C,SPI,UART/USART,USB 外圍設(shè)備:欠壓檢測/復(fù)位,POR,PWM,WDT 輸入/輸出數(shù):14 程序存儲器容量:8KB(4K x 16) 程序存儲器類型:閃存 EEPROM 大小:256 x 8 RAM 容量:512 x 8 電壓 - 電源 (Vcc/Vdd):1.8 V ~ 5.5 V 數(shù)據(jù)轉(zhuǎn)換器:A/D 11x10b 振蕩器型:內(nèi)部 工作溫度:-40°C ~ 85°C 封裝/外殼:20-DIP(0.300",7.62mm) 包裝:管件 產(chǎn)品目錄頁面:642 (CN2011-ZH PDF) 配用:DV164126-ND - KIT DEVELOPMENT USB W/PICKIT 2DM164127-ND - KIT DEVELOPMENT USB 18F14/13K50AC164112-ND - VOLTAGE LIMITER MPLAB ICD2 VPP
PIC16CR76T-I/ML 功能描述:IC PIC MCU 8KX14 28QFN RoHS:是 類別:集成電路 (IC) >> 嵌入式 - 微控制器, 系列:PIC® 16C 產(chǎn)品培訓(xùn)模塊:XLP Deep Sleep Mode 8-bit PIC® Microcontroller Portfolio 標準包裝:22 系列:PIC® XLP™ 18F 核心處理器:PIC 芯體尺寸:8-位 速度:48MHz 連通性:I²C,SPI,UART/USART,USB 外圍設(shè)備:欠壓檢測/復(fù)位,POR,PWM,WDT 輸入/輸出數(shù):14 程序存儲器容量:8KB(4K x 16) 程序存儲器類型:閃存 EEPROM 大小:256 x 8 RAM 容量:512 x 8 電壓 - 電源 (Vcc/Vdd):1.8 V ~ 5.5 V 數(shù)據(jù)轉(zhuǎn)換器:A/D 11x10b 振蕩器型:內(nèi)部 工作溫度:-40°C ~ 85°C 封裝/外殼:20-DIP(0.300",7.62mm) 包裝:管件 產(chǎn)品目錄頁面:642 (CN2011-ZH PDF) 配用:DV164126-ND - KIT DEVELOPMENT USB W/PICKIT 2DM164127-ND - KIT DEVELOPMENT USB 18F14/13K50AC164112-ND - VOLTAGE LIMITER MPLAB ICD2 VPP