
December 22, 2003
Document No. 38-12009 Rev. *D
203
CY8C22xxx Preliminary Data Sheet
17. Digital Blocks
17.2.2
DxBxxCR0 Register
The DxBxxCR0 register is the digital blocks’ control register. It is described by function in
Table 17-14
. For additional informa-
tion, reference the
DxBxxCR0 register on page 93
.
Interrupt Mask Register
17.2.3
INT_MSK1 Register
The INT_MSK1 register is described in the
“Interrupt Con-
troller” chapter on page 51
. For additional information, refer-
ence the
INT_MSK1 register on page 135
.
Configuration Registers
The Configuration block contains 3 registers: Function
(DxBxxFN), Input (DxBxxIN), and Output (DxBxxOU). The
values in these registers should not be changed while the
block is enabled.
17.2.4
DxBxxFN Registers
These registers contain the primary Function and Mode bits.
The function bits configure the block into one of the avail-
able block functions (six for the Comm block, four for the
Basic block). The mode bits select the options available for
the selected function. These bits should only be changed
when the block is disabled.
Three additional control bits are found in this register. The
End/Single bit is used to indicate the last or most significant
block in a chainable function. This bit must also be set if the
chainable function only consists of a single block. The Data
Invert bit optimally inverts the selected data input.
The BCEN bits enable the primary output of the block, to
drive the row broadcast block. The BCEN bits are set inde-
pendently in each block and therefore, care must be taken
to ensure that only one BCEN bit in a given row is enabled.
However, if any of the blocks in a given row have the BCEN
bit set, the input that allows the broadcast net from other
rows to drive the given row’s broadcast net is disabled (see
Figure 16-2 on page 185
).
For additional information, reference the
DxBxxFN register
on page 149
.
Table 17-14. DxBxxCR0 Register Description
Function
Timer
Description
There are three bits in the Control (CR0) register: one for enabling the block, one for setting the optional interrupt on capture, and one to select
between one-half and a full clock for terminal count output.
One bit enable only.
There are three bits in the Control (CR0) register: one bit for enabling the block, and two bits to enable and control Dead Band Bit Bang mode.
When Bit Bang mode is enabled, the output of this register is substituted for the PWM reference. This register may be toggled by user firm-
ware, to generate PHI1 and PHI2 output clock with the programmed dead time. The options for Bit Bang mode are as follows:
0
Function uses the previous clock primary output as the input reference.
1
Function uses the Bit Bang Clock register as the input reference.
Two bits are used to enable operation.
The SPI Control (CR0) register contains both control and status bits. There are four control bits that are read/write: Enable, Clock Phase and
Clock Polarity to set the mode, and LSB First, which controls bit ordering. There are two read-only status bits: Overrun and SPI Complete.
There are two additional read-only status bits to indicate TX and RX Buffer status.
The SPI Control (CR0) register contains both control and status bits. There are four control bits that are read/write: Enable, Clock Phase and
Clock Polarity to set the mode, and LSB First, which controls bit ordering. There are two read-only status bits: Overrun and SPI Complete.
There are two additional read-only status bits to indicate TX and RX Buffer status.
The Transmitter Control (CR0) register contains three control bits and two status bits. The control bits are Enable, Parity Enable, and Parity
Type, and have read/write access. The status bits, TX Reg Empty and TX Complete, are read-only.
The Receiver Control (CR0) register contains both control and status bits. Three control bits are read/write: Enable, Parity Enable, and Parity
Type. There are five read-only status bits: RX Reg Full, RX Active, Framing Error, Overrun, and Parity Error.
Counter
Dead Band
CRCPRS
SPIM
SPIS
TXUART
RXUART
Table 17-15. DxBxxFN Function Registers
[2:0]: Function
000b: Timer
001b: Counter
010b: CRCPRS
011b: Reserved
100b: Dead band for PWM
101b: UART
110b: SPI
111b: Reserved
Function specific
1 == Block is not chained or is at the end of a chain
0 == Block is at the start of or in the middle of a chain
1 == Disable
0 == Enable
1 == Invert block’s data input
0 == Do not invert block’s data input
[4:3]: Mode
[5]: End/Single
[6]: BCEN
[7]: Data Invert