CY7C68013A/CY7C68014A
CY7C68015A/CY7C68016A
Docum ent #: 38-08032 Rev. *G Page 12 of 55
3.13.3 GPIF and FIFO Clock Rates
An 8051 register bit selects one of two frequencies for the
int ernall y suppl ied int erface clock: 30 MH z and 48 MHz. Alte r-
natively, an externally supplied clock of 5 MHz–48 MHz
feeding the IFCLK pin can be used as the interface clock.
IFCLK can be configured to function as an output clock when
the GPIF and FIFOs are internally clocked. An output enable
bit in the IFCONFIG register turns this clock output off, if
desired. Another bit within the IFCONFIG register will invert
the IFCLK signal whether internally or externally sourced.
3.14 GPIF
The GPIF is a flex ible 8- or 16-bi t par alle l int erface driven by a
user-programmable finite state machine. It allows the
CY7C68013A/15A to perform local bus mastering, and can
implement a wide variety of protocols such as ATA i nterface,
printer parallel port , and Utopia.
The GPIF has six programmable control outputs (CTL), nine
address outputs (GPIFADRx), and six general-purpose ready
inputs (RDY). The data bus width can be 8 or 16 bits. Each
GPIF vector def ines the st ate of the cont rol outputs, and deter-
mines what state a ready input (or multiple inputs) must be
before proceeding. The GPIF vector can be programmed to
advance a FIFO to the next data value, advance an address,
etc. A sequence of the GPIF vectors make up a single
waveform that will be executed to perform the desired data
move between the FX2LP and the ext ernal devic e.
3.14.1 Six Control OU T Signals
The 100- and 128-pin packages bring out all six Control Output
pins (CTL0- CTL5). The 8051 pr ograms the GPI F unit to defin e
the CTL waveforms. The 56-pin package brings out three of
these signals, CTL0–CTL2. CTLx waveform edges can be
programmed to make transitions as fast as once per clock
(20.8 ns using a 48-MHz cl ock).
3.14.2 Six Ready IN Signals
The 100- and 1 28-pin packages bring out a ll six Ready inputs
(RDY0–RDY5). The 8051 program s the GPIF unit to test the
RDY pins for GPI F branching. The 56-pin package bri ngs out
two of t hese signals, RDY0 –1.
3.14.3 Nine GPIF Address OUT Signals
Nine GPIF addre ss line s are avai lable in th e 100- an d 128- pin
packages, GPIFADR[8..0]. The GPIF address lines allow
indexing through up to a 512-byte block of RAM. If more
address lines are needed, I/O port pins can be used.
3.14.4 Long Transfer Mode
In mast er mod e, t he 8051 app ropr iate ly set s GPIF tr ans actio n
count registers (GPIFTCB3, GPIFTCB2, GPIFTCB1, or
GPIFTCB0) f or unat tended t ransf ers of up to 232 trans act ions.
The G P IF automatical ly thr ottles data flo w to p revent under or
overflow until the full number of requested transactions
complete. The GPIF decrements the value in these registers
to repr esent the current st atus of the transaction.
3.15 ECC Gen erati on[7]
The EZ-USB c an ca lcula te ECCs (E rror- Correct ing Cod es) on
data that passes across its GPIF or Slave FIFO interfaces.
There are two ECC configurations: Two ECCs, each calcu-
lated over 256 bytes (SmartMedi a™ Standard); and one ECC
calcul ated over 512 bytes.
The ECC can correct any one-bit error or detect any two-bit
error.
3.15 .1 EC C Im p lement a t ion
The two ECC confi gurations are selected by the ECCM bit:
3.15.1.1 ECCM=0
Two 3-byte ECCs, each calculated over a 256-byte block of
data. This configuration conforms to the SmartMedia
Standard.
Write any value to ECCRESET, then pass data across the
GPIF or Slave FI FO interface. The ECC for th e first 256 bytes
of data will be calculated and st ored in ECC1. The ECC for the
next 256 bytes will be stored in ECC2. After the second ECC
is cal culated, the values in the ECCx regist ers wil l not change
until ECCRESET is written again, even i f more data is subse-
quently passed across the interface.
3.15.1.2 ECCM=1
One 3-byte ECC cal culated over a 512-byte block of dat a.
Write any value to ECCRESET then pass data across the
GPIF or Slave FI FO interface. The ECC for th e first 512 bytes
of data will be calculated and stored in ECC1; ECC2 is unused.
Afte r the ECC i s calculat ed, th e value i n ECC1 will not cha nge
until ECCRESET is written again, even i f more data is subse-
quently passed across the in ter face
3.16 USB Upload s and Down loads
The core ha s t he abil ity to di rec tly ed it the dat a content s o f the
internal 16-KByte RAM and of the internal 512-byte scratch
pad RAM via a vendor-specific command. This capability is
normally used when “soft” downloading user code and is
available only to and from internal RAM, only when the 8051
is held in reset. The available RAM space s are 16 KBytes from
0x0000–0x3FFF (code/data) and 512 bytes from
0xE000–0xE1FF (scratch pad data RAM).[8]
3.17 Au topointer Acces s
FX2LP provi des two ident ical autop oin ters. They are similar to
the internal 8051 data pointers, but with an additiona l f eature:
they c an optionally increment after every memory a ccess. Thi s
capability is available to and from both internal and external
RAM. The autopointers are available in external FX2LP
registers, under control of a mode bit (AUTOPTRSET-UP.0).
Using the external FX2LP autopointer access (at 0xE67B –
0xE67C) allows the autopointer to access all RAM, internal
and ext ernal to the part. Also, t he autopoin ter s can point to any
FX2LP register or endpoint buffer space. When autopointer
access to external memory is enabled, location 0xE67B and
0xE67C in XDATA and code spac e cannot be used.
Notes:
7. To use the ECC logic, the GPIF or Sl ave FIFO interface must be configured for byte-wide operation.
8. After the data has been downloaded from the host, a “loader” can execute from internal RAM in order to transfer downloaded data to external memory.