© 2010 Lattice Semiconductor Corp. All Lattice trademarks, registered trademarks, patents, and disclaimers are as listed at www.latticesemi.com/legal. All other brand
or product names are trademarks or registered trademarks of their respective holders. The specifications and information herein are subject to change without notice.
IPUG59_01.7, September 2010 2 Soft SPI4 IP Core User’s Guide
Chapter 1. Introduction .......................................................................................................................... 4
Quick Facts ........................................................................................................................................................... 4
Features ................................................................................................................................................................ 4
Chapter 2. Functional Description ........................................................................................................ 6
Overview ............................................................................................................................................................... 6
Operational Description......................................................................................................................................... 6
SPI4 Transmitter - S4TX .............................................................................................................................. 7
SPI4 Transmit Data Protocol - S4TXDP ...................................................................................................... 7
SPI4 Transmit I/O - S4TXIO (TXGB) ........................................................................................................... 9
SPI4 Transmit Status - S4TXSP ................................................................................................................ 11
SPI4 Receiver - S4RX................................................................................................................................ 14
SPI4 Receive Data Protocol - S4RXDP ..................................................................................................... 15
SPI4 Receive Status Protocol - S4RXSP................................................................................................... 18
SPI4 Receiver I/O - S4RXIO (RXGB) ........................................................................................................ 21
Calendar and Status RAM Access...................................................................................................................... 22
Start-Up Procedures ........................................................................................................................................... 23
Receive Direction Start-Up......................................................................................................................... 23
Dynamic Mode Start-up and Recovery (SMSR) FSM................................................................................ 23
Static Mode Start-up and Recovery (SMSR) FSM..................................................................................... 23
Transmit Direction Start-Up........................................................................................................................ 24
Signal Descriptions ............................................................................................................................................. 24
Chapter 3. Parameter Settings ............................................................................................................ 33
Global Tab........................................................................................................................................................... 36
User Data Interface .................................................................................................................................... 36
Generation Options .................................................................................................................................... 36
Transmit Tab ....................................................................................................................................................... 37
Transmit Data Path Options....................................................................................................................... 37
Transmit Line Side FIFO Thresholds ......................................................................................................... 37
Transmit User Side FIFO Thresholds ........................................................................................................ 37
Transmit Packing Enable ........................................................................................................................... 38
Receive Tab – LatticeECP .................................................................................................................................. 38
Receive Data Path Options........................................................................................................................ 38
Receive Tab – Lattice SC/SCM .......................................................................................................................... 39
Receive Data Path Options........................................................................................................................ 39
Status Tab........................................................................................................................................................... 40
Status Channel Options ............................................................................................................................. 40
Transmit Status Path Options .................................................................................................................... 40
Receive Status Path Options ..................................................................................................................... 40
Calendars Tab..................................................................................................................................................... 41
Transmit Calendar Options ........................................................................................................................ 41
Receive Calendar Options ......................................................................................................................... 41
Chapter 4. IP Core Generation............................................................................................................. 42
Licensing the IP Core.......................................................................................................................................... 42
Getting Started .................................................................................................................................................... 42
IPexpress-Created Files and Top Level Directory Structure............................................................................... 44
Instantiating the Core .......................................................................................................................................... 46
Running Functional Simulation ........................................................................................................................... 46
Synthesizing and Implementing the Core in a Top-Level Design ....................................................................... 47
Hardware Evaluation........................................................................................................................................... 48
Table of Contents