P89V51RB2FN NXP Semiconductors, P89V51RB2FN Datasheet - Page 34

IC, MCU 8BIT 80C51 16K FLASH, DIP40

P89V51RB2FN

Manufacturer Part Number
P89V51RB2FN
Description
IC, MCU 8BIT 80C51 16K FLASH, DIP40
Manufacturer
NXP Semiconductors
Datasheet

Specifications of P89V51RB2FN

Controller Family/series
(8051) 8052
Core Size
8bit
No. Of I/o's
32
Program Memory Size
16KB
Ram Memory Size
1KB
Cpu Speed
33MHz
Oscillator Type
External Only
No. Of Timers
4
No. Of Pwm
RoHS Compliant

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
P89V51RB2FN
Manufacturer:
NXP/恩智浦
Quantity:
20 000
NXP Semiconductors
P89V51RB2_RC2_RD2_5
Product data sheet
Fig 13. Timer 2 in auto-reload mode (DCEN = 0)
OSC
T2 pin
T2EX pin
6
In this mode, there are two options selected by bit EXEN2 in T2CON register. If
EXEN2 = 0, then Timer 2 counts up to 0FFFFH and sets the TF2 (Overflow Flag) bit upon
overflow. This causes the Timer 2 registers to be reloaded with the 16-bit value in
RCAP2L and RCAP2H. The values in RCAP2L and RCAP2H are preset by software
means.
Auto reload frequency when Timer 2 is counting up can be determined from this formula:
Where SupplyFrequency is either f
(C/T2 = 1).
If EXEN2 = 1, a 16-bit reload can be triggered either by an overflow or by a 1-to-0
transition at input T2EX. This transition also sets the EXF2 bit. The Timer 2 interrupt, if
enabled, can be generated when either TF2 or EXF2 is ‘1’.
Microcontroller’s hardware will need three consecutive machine cycles in order to
recognize falling edge on T2EX and set EXF2 = 1: in the first machine cycle pin T2EX has
to be sampled as ‘1’; in the second machine cycle it has to be sampled as ‘0’, and in the
third machine cycle EXF2 will be set to ‘1’.
In
T2EX to control the direction of count. When a logic ‘1’ is applied at pin T2EX Timer 2 will
count up. Timer 2 will overflow at 0FFFFH and set the TF2 flag, which can then generate
an interrupt, if the interrupt is enabled. This timer overflow also causes the 16-bit value in
RCAP2L and RCAP2H to be reloaded into the timer registers TL2 and TH2.
------------------------------------------------------------------------------- -
65536
transition
detector
Figure
SupplyFrequency
C/T2 = 0
C/T2 = 1
14, DCEN = 1 and Timer 2 is enabled to count up or down. This mode allows pin
RCAP2H RCAP2L
EXEN2
control
Rev. 05 — 12 November 2009
TR2
control
reload
osc
RCAP2L RCAP2H
(8-bits)
TL2
(C/T2 = 0) or frequency of signal on T2 pin
(8-bits)
P89V51RB2/RC2/RD2
TH2
8-bit microcontrollers with 80C51 core
EXF2
TF2
© NXP B.V. 2009. All rights reserved.
002aaa524
interrupt
timer 2
34 of 80
(1)

Related parts for P89V51RB2FN