374
CY8C28xxx PSoC Programmable System-on-Chip TRM, Document No. 001-52594 Rev. *G
Digital Blocks
Chained SPIM.
When two adjacent communication blocks
are chained to form a more-than-8-bit SPIM function, the
preceding operations are maintained the same, with the fol-
lowing exceptions:
■
More transmissions for more bits.
■
Only need to enable LSB block to enable the function
such as in chained Timer/Counter/CRCPRS/PWMDBL
functions.
■
Need to write MSB TX register first and then LSB regis-
ter to initiate a transmission.
■
Always read MSB RX data first and then LSB RX data.
■
Always check LSB status bits for whole SPIM status if
you follow above TX/RX read/write operation sequence.
■
The interrupt in both blocks can be enabled and selected
arbitrarily. (But if clearing SPI complete bit or TX Empty
bit, still need to read the CR0 register or write DR1 regis-
ter in that block).
17.3.8
SPIS Timing
Enable/Disable Operation.
As soon as the block is config-
ured for SPI Slave and before enabling, the MISO output is
set to idle at logic 1. Both the enable bit must be set and the
SS_ asserted (either driven externally or forced by firmware
programming) for the block to output data. When enabled,
the primary output is the MSb or LSb of the shift register,
depending on the LSb First configuration in bit 7 of the Con-
trol register. The auxiliary output of the SPIS is always
forced into tri-state.
Because the SPIS has no internal clock, it must be enabled
with setup time to any external master supplying the clock.
Setup time is also required for a TX Buffer register write,
before the first edge of the clock or the first falling edge of
SS_, depending on the mode. This setup time must be
assured through the protocol and an understanding of the
timing between the master and slave in a system.
When the block is disabled, the MISO output reverts to its
idle '1' state. All internal state is reset (including CR0 status)
to its configuration-specific reset state, except for DR0, DR1,
and DR2 which are unaffected.
Normal Operation.
Typical timing for a SPIS transfer is
shown in
. If the SPIS is pri-
marily being used as a receiver, the RX Reg Full (polling
only) or SPI Complete (polling or interrupt) status may be
used to determine when a byte has been received. In this
way, the SPIS operates identically with the SPIM. However,
there are two main areas in which the SPIS operates differ-
ently: 1) SPIS behavior related to the SS_ signal, and 2) TX
data queuing (loading the TX Buffer register).
Figure 17-29. Typical SPIS Timing in Modes 0 and 1
SCLK (internal)
TX REG EMPTY
D7
MISO
D6
D5
D2
D1
D0
User writes first byte to the
TX Buffer register in
advance of transfer.
At the falling edge of SS_, MISO
transitions from an IDLE (high)
to output the first bit of data.
User writes the next byte
to the TX Buffer register.
SCLK (MODE 0)
Last bit of received data is valid
on this edge and is latched into
the RX Buffer register.
SCLK (MODE 1)
SS_
RX REG FULL
First input
bit is
latched.
First
Shift
D7
D6
D7
Summary of Contents for CY8C28 series
Page 65: ...64 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G RAM Paging ...
Page 125: ...124 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G ...
Page 311: ...310 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G IDAC_CR0 1 FDh ...
Page 317: ...316 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G ...
Page 393: ...392 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G ...
Page 477: ...476 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G Digital Clocks ...
Page 561: ...560 CY8C28xxx PSoC Programmable System on Chip TRM Document No 001 52594 Rev G ...