Cypress Semiconductor FX2LP Informacje Techniczne Strona 225

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 460
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 224
Chapter 10. General Programmable Interface (GPIF) Page 10-35
To perform a Single-Read transaction:
1. Initialize the GPIF Configuration Registers and Waveform Descriptors.
2. Perform a dummy read of the XGPIFSGLDATLX register to start a single transaction.
3. Wait for the GPIF to indicate that the transaction is complete. When the transaction is com-
plete, the DONE bit (GPIFIDLECS.7 or GPIFTRIG.7) will be set to 1. If enabled, a GPIFDONE
interrupt will also be generated.
4. Depending on the bus width and the desire to start another transaction, the read data can be
retrieved from the XGPIFSGLDATH, XGPIFSGLDATLX, and/or the
XGPIFSGLDATLNOX register (or from the SFR-space copies of these registers):
In 16-bit mode only, the most significant byte, FD[15:8], of data is read from the
XGPIFSGLDATH register.
In 8- and 16-bit modes, the least significant byte of data is read by either:
reading XGPIFSGLDATLX, which reads the least significant byte and starts another Sin-
gle-Read transaction.
reading XGPIFSGLDATLNOX, which reads the least significant byte but does not start
another Single-Read transaction.
The following C program fragments (Figures 10-17 and 10-18) illustrate how to perform a Sin-
gle-Read transaction in 8-bit mode (WORDWIDE=0):
Przeglądanie stron 224
1 2 ... 220 221 222 223 224 225 226 227 228 229 230 ... 459 460

Komentarze do niniejszej Instrukcji

Brak uwag