
17. Digital Blocks
CY8C22xxx Preliminary Data Sheet
198
Document No. 38-12009 Rev. *D
December 22, 2003
17.2
Register Definitions
The Digital Block registers in this chapter are organized by
function, as presented in
Table 17-5
. To reference timing
diagrams associated with the digital block registers, see
“Timing Diagrams” on page 204
. For a complete list of the
Digital Block registers showing their addresses and bit
names, reference the
“Digital Register Summary” on
page 176
.
Data and Control Registers
17.2.1
DxBxxDRx Registers
The Data and Control registers presented in this section
encompass the DxBxxDR0, DxBxxDR1, and DxBxxDR2
registers. They are discussed according to which bank they
are located in and then detailed in tables by function type.
There are two banks of registers associated with the PSoC
device. Bank 0 encompasses the user registers for the
device and Bank 1 encompasses the configuration registers
for the device. Both are defined below. Reference the
“Bank
0 Registers” on page 86
and the
“Bank 1 Registers” on
page 145
for more information.
For additional information, reference the Register Details
chapter for the following registers:
DxBxxDR0 register on page 90
.
I
DxBxxDR1 register on page 91
.
I
DxBxxDR2 register on page 92
.
I
17.2.1.1
Timer Register Definitions
Table 17-5. Digital Block Register Definitions
DR0
DR1
DR2
CR0
Function
Down Counter
Down Counter
Down Counter
LFSR
Shifter
Shifter
Shifter
Shifter
Access
R*
R*
R*
R*
N/A
N/A
N/A
N/A
Function
Period
Period
Period
Polynomial
TX Buffer
TX Buffer
TX Buffer
N/A
Access
W
W
W
W
W
W
W
N/A
Function
Capture/Compare
Compare
N/A
Seed
RX Buffer
RX Buffer
N/A
RX Buffer
Access
RW
RW
N/A
RW
R
R
N/A
R
Function
Control
Control
Control
Control
Control/Status
Control/Status
Control/Status
Control/Status
Access
RW
RW
RW
RW
RW**
RW**
RW**
RW**
Timer
Counter
Dead Band
CRCPRS
SPIM
SPIS
TXUART
RXUART
LEGEND
* In Timer, Counter, Dead Band, and CRCPRS functions, a read of the DR0 register returns 00h and transfers DR0 to DR2.
** In the Communications functions, control bits are Read-Write access and status bits are Read-Only access.
Bank 0:
There are three 8-bit data registers and a 3-bit control register.
Table 17-6
explains the meaning of these registers in the context of timer opera-
tion.
Bank 1:
The mode bits in the Function register are block type specific. Other bit fields in this register, as well as the definitions of the Input and Output reg-
isters, are common to all functions and are described in the
“DxBxxIN Registers” on page 204
and the
“DxBxxOU Registers” on page 204
.
These mode bits are independent in the Timer block and control the Interrupt Type and the Compare Type. Timers have a special divide by one
mode, when the period of the DR0 register is set to 00h. In this configuration, the primary output Terminal Count (TC) is the inverted input clock.
The interrupt output is also the input clock inverted.
Table 17-6. Timer Data Register Descriptions
Name
Function
Count Value
Description
DR0
Not Directly Readable or Writeable.
During normal operation, DR0 stores the current count of a synchronous down counter.
When disabled, a write to the DR1 Period register is also simultaneously loaded into DR0 from the data bus.
When disabled, a read of DR0 returns 00h to the data bus and transfers the contents of DR0 to DR2. This transfer only
occurs in the addressed block.
When enabled, a read of DR0 returns 00h to the data bus and synchronously transfers the contents of DR0 to DR2. Oper-
ates simultaneously on the byte addressed and all higher bytes in a multi-block timer.
Note that when the hardware capture input is high, the read of DR0 (software capture) will be masked and will not occur. The
hardware capture input must be low for a software capture to occur.