CY8C20X34 CYPRESS [Cypress Semiconductor], CY8C20X34 Datasheet - Page 76

no-image

CY8C20X34

Manufacturer Part Number
CY8C20X34
Description
Technical Reference Manual (TRM)
Manufacturer
CYPRESS [Cypress Semiconductor]
Datasheet
CapSense Module
10.2
The following registers are associated with the CapSense Module and are listed in address order. The register descriptions
have an associated register table showing the bit structure for that register. The bits in the tables that are grayed out are
reserved bits and are not detailed in the register descriptions that follow. Reserved bits should always be written with a value
of ‘0’. For a complete table of CapSense Module registers, refer to the
page
10.2.1
The CapSense Control Register 0 (CS_CR0) controls the
operation of the CapSense counters. Bits [7:1] should never
be written to while the block is enabled.
Bits 7 and 6: CSOUT[1:0]. These bits select between a
number of CapSense signals that can be driven to an output
pin. Refer to
and to
Bits 2 and 1: MODE[1:0]. These bits specify the operating
mode of the counter logic. The modes are shown in the
adjacent table.
76
0,A0h
CSOUT[1:0]
Address
00
01
10
11
72.
Figure 10-8 on page 81
Register Definitions
CS_CR0
Figure 10-4 on page 74
CS_CR0 Register
IN
CS_INT
COL
COH
Name
Bit 7
CSOUT[1:0]
for IN and CS_INT.
Description
for the COL and COH,
Bit 6
Bit 5
Bit 4
Bit 0: EN. When this bit is written to ‘1’, the counters are
enabled for counting. When this bit is written to ‘0’, counting
is stopped and all counter values are reset to ‘0’. If the
counting mode is stopped in conjunction with an event (see
MODE[1:0]), the current count is held and can be subse-
quently read from the counter registers. The EN bit must be
toggled to ‘0’ and then back to ‘1’ to start a new count.
For additional information, refer to the
page
MODE[1:0]
00
01
10
11
153.
Bit 3
“Summary Table of the CapSense Registers” on
Stop On Event
In this mode, the block starts counting when the EN bit is
set, and stops counting on the selected interrupt event. This
mode allows the user to read the counter results in firm-
ware. Counting can be started again by disabling and re-
enabling the block using the EN bit.
Pulse Width
In this mode, after the EN bit is set, the block waits for a
positive edge on the data input selection to start the
counter, and then stops the counter on the following nega-
tive edge of the data input. Polarity can be adjusted with the
INV bit (CS_CR1). Counting can be started again by dis-
abling and re-enabling the block using the EN bit.
Period
In this mode, after the EN bit is set, the block waits for a
positive edge on the data input selection to start the
counter, and then stops the counter on the following posi-
tive edge of the data input. Polarity can be adjusted with the
INV bit (CS_CR1). Counting can be started again by dis-
abling and re-enabling the block using the EN bit.
Continuous
In this mode, the counter can be used to generate a peri-
odic interrupt. The period is set by the input clock selection
in conjunction with using one 8-bit counter (period=100h) or
the chained 16-bit counter (period = 10000h).
Bit 2
MODE[1:0]
PSoC CY8C20x34 TRM, Version 1.0
Bit 1
Description
CS_CR0 register on
Bit 0
EN
Access
RW : 00

Related parts for CY8C20X34