VRS51C1000-40-L RAMTRON [Ramtron International Corporation], VRS51C1000-40-L Datasheet - Page 19

no-image

VRS51C1000-40-L

Manufacturer Part Number
VRS51C1000-40-L
Description
Versa 8051 MCU with 64KB of IAP/ISP Flash
Manufacturer
RAMTRON [Ramtron International Corporation]
Datasheet
Mode 3
In Mode 3, Timer 1 is blocked as if its’ control bit, TR1,
was set to 0. In this mode, Timer 0’s registers TL0 and
TH0 are configured as two separate 8-bit counters.
The TL0 counter uses Timer 0’s control bits (C/T,
GATE, TR0, INT0, TF0), the TH0 counter is held in
Timer Mode (counting machine cycles) and gains
control over TR1 and TF1 from Timer 1. At this point,
TH0 controls the Timer 1 interrupt.
Timer 2
Timer 2 of the VRS51C1000 is a 16-bit Timer/Counter
and is similar to Timers 0 and 1 in that it can operate
either as an event counter or as a timer. This is
controlled by the C/T2 bit in the T2CON special
function register. Timer 2 has three operating modes -
Auto-Load, Capture and Baud Rate Generator. These
modes are selected via the T2CON SFR.
following table describes T2CON special function
register bits.
T
______________________________________________________________________________________________
www.ramtron.com
F
INT0 PIN
IGURE
ABLE
Bit
7
6
VRS51C1000
GATE
TR0
TF2
Fosc
T0PIN
7
28: T
12: T
IMER
Mnemonic
TF2
EXF2
IMER
EXF2
6
2 C
/C
OUNTER
ONTROL
÷12
RCLK
5
0 M
R
EGISTER
Description
Timer 2 Overflow Flag: Set by an overflow
of Timer 2 and must be cleared by
software. TF2 will not be set when either
RCLK =1 or TCLK =1.
Timer 2 external flag change in state occurs
when either a capture or reload is caused
by a negative transition on T2EX and
EXEN2=1. When Timer 2 is enabled,
EXF=1 will cause the CPU to Vector to the
Timer 2 interrupt routine. Note that EXF2
must be cleared by software.
ODE
0
1
TCLK
C/T =0
C/T =1
3
4
(T2CON) –SFR C8
Control
Control
EXEN2
3
TR1
CLK
CLK
H
TR2
2
0
0
TF1
TF0
C/T2
1
TH0
TL0
CP/RL2
INTERRUPT
INTERRUPT
7
7
0
The
The Timer 2 Mode selection bits and their function are
described in the following table.
T
The modes are discussed in the following sections.
ABLE
5
4
3
2
1
0
RCLK + TCLK
0
0
1
X
29: T
RCLK
TCLK
EXEN2
TR2
C/T2
CP/RL2
IMER
2 M
ODE
S
ELECTION
Serial Port Receive Clock Source.
1: Causes Serial Port to use Timer 2
overflow pulses for its receive clock in
Modes 1 and 3.
0: Causes Timer 1 overflow to be used for
the Serial Port receive clock.
Serial Port Transmit Clock.
1: Causes Serial Port to use Timer 2
overflow pulses for its transmit clock in
Modes 1 and 3.
0: Causes Timer 1 overflow to be used for
the Serial Port transmit clock.
Timer 2 External Mode Enable.
1: Allows a capture or reload to occur as a
result of a negative transition on T2EX if
Timer 2 is not being used to clock the Serial
Port.
0: Causes Timer 2 to ignore events at
T2EX.
Start/Stop Control for Timer 2.
1: Start Timer 2
0: Stop Timer 2
Timer or Counter Select (Timer 2)
1: External event counter falling edge
triggered.
0: Internal Timer (OSC/12)
Capture/Reload Select.
1: Capture of Timer 2 value into RCAP2H,
RCAP2L is performed if EXEN2=1 and a
negative transitions occurs on the T2EX
pin. The capture mode requires RCLK and
TCLK to be 0.
0: Auto-reload reloads will occur either with
Timer 2 overflows or negative transitions at
T2EX when EXEN2=1. When either RCK
=1 or TCLK =1, this bit is ignored and the
timer is forced to auto-reload on Timer 2
overflow.
CP/RL2
0
1
X
X
B
ITS
TR2
1
1
1
0
page 19 of 48
MODE
16-bit Auto-
Reload Mode
16-bit Capture
Mode
Baud Rate
Generator Mode
Timer 2 stops

Related parts for VRS51C1000-40-L