參數(shù)資料
型號: R5F64211KFB
元件分類: 微控制器/微處理器
英文描述: 32-BIT, FLASH, 64 MHz, MICROCONTROLLER, PQFP100
封裝: 14 X 14 MM, 0.50 MM PITCH, PLASTIC, LQFP-100
文件頁數(shù): 23/50頁
文件大小: 777K
代理商: R5F64211KFB
102
ATmega165A/PA/325A/PA/3250A/PA/645A/P/6450A/P [DATASHEET]
8285E–AVR–02/2013
Note:
The assembly code example requires that the r17:r16 register pair contains the value to be written to TCNT1.
16.3.1
Reusing the Temporary High Byte Register
If writing to more than one 16-bit register where the high byte is the same for all registers written, then the high byte
only needs to be written once. However, note that the same rule of atomic operation described previously also
applies in this case.
16.4
Timer/Counter Clock Sources
The Timer/Counter can be clocked by an internal or an external clock source. The clock source is selected by the
Clock Select logic which is controlled by the Clock Select (CS12:0) bits located in the Timer/Counter control Regis-
ter B (TCCR1B). For details on clock sources and prescaler, see ”Timer/Counter0 and Timer/Counter1 prescalers”
16.5
Counter Unit
The main part of the 16-bit Timer/Counter is the programmable 16-bit bi-directional counter unit. Figure 16-2 shows
a block diagram of the counter and its surroundings.
Assembly code example (1)
TIM16_WriteTCNT
1:
; Save global interrupt flag
in
r18,SREG
; Disable interrupts
cli
; Set TCNT
1 to r17:r16
out
TCNT
1H,r17
out
TCNT
1L,r16
; Restore global interrupt flag
out
SREG,r18
ret
C code example
void
TIM16_WriteTCNT
1( unsigned int i )
{
unsigned char
sreg;
unsigned int
i;
/* Save global interrupt flag */
sreg = SREG;
/* Disable interrupts */
__disable_interrupt();
/* Set TCNT
1 to i */
TCNT
1 = i;
/* Restore global interrupt flag */
SREG = sreg;
}
相關(guān)PDF資料
PDF描述
R5F6421FJFB 32-BIT, FLASH, 64 MHz, MICROCONTROLLER, PQFP100
R5F6421GJFB 32-BIT, FLASH, 64 MHz, MICROCONTROLLER, PQFP100
R5F6421HKFB 32-BIT, FLASH, 64 MHz, MICROCONTROLLER, PQFP100
R5F64212KFB 32-BIT, FLASH, 64 MHz, MICROCONTROLLER, PQFP100
R5F64210LFB 32-BIT, FLASH, 64 MHz, MICROCONTROLLER, PQFP100
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
R5F64211LFB 制造商:RENESAS 制造商全稱:Renesas Technology Corp 功能描述:RENESAS MCU
R5F64212JFB 制造商:Renesas Electronics Corporation 功能描述:
R5F64212KFB 制造商:RENESAS 制造商全稱:Renesas Technology Corp 功能描述:RENESAS MCU
R5F64212LFB 制造商:RENESAS 制造商全稱:Renesas Technology Corp 功能描述:RENESAS MCU
R5F64213JFB 制造商:RENESAS 制造商全稱:Renesas Technology Corp 功能描述:RENESAS MCU