1974 - LatticeXP2: Why are padding bits required for every LatticeXP2 FPGA except the LatticeXP2-40 when it is programmed in Slave SPI mode?
The LatticeXP2 configuration memory is arranged in an array. The array size varies depending on the number of logic elements available in the FPGA. The LatticeXP2 array dimensions are as follows:
- LatticeXP2-5: 1938 rows, each 638 bits wide
- LatticeXP2-8: 2532 rows, each 772 bits wide
- LatticeXP2-17: 1658 rows, each 2188 bits wide
- LatticeXP2-30: 2252 rows, each 2644 bits wide
- LatticeXP2-40: 2545 rows, each 3384 bits wide
The SPI memory controllers usually require data to be transmitted in multiples of 8-bits. Therefore a certain amount of padding must be provided so that the SPI memory controller can transmit the data so that it aligns to the requirements of the LatticeXP2 device. Thus a SPI memory controller that sends 8-bits per transaction to a LatticeXP2-8 must break the 772 bit wide data into 8-bit chunks. The 772 bits is not evenly divisible by 8, so 4 additional padding bits must be provided to the SPI memory controller to align the data transmitted to the LatticeXP2-8 correctly.
The LatticeXP2_SSPI.pdf file provided in the documents section of the Lattice ispVM System Software describes the Slave SPI programming process in more detail.
Related Articles
5779 - iCE40 UltraPlus: Can iCE40 devices be configured in Master SPI or Slave SPI mode if the NVCM has already been programmed?
When the NVCM of an iCE40 device has already been programmed, it can no longer be configured in Master SPI mode (SPI serial Flash PROM). However, Slave SPI is still possible which could be an external device, such as a processor, microcontroller, or ...
7740 - How to enable SSPI programming in MachX03-9400 Development Board
Setup to enable SSPI in MachX03-9400 development board. Connect to JP2, MCLK, SI, SO, SS, 5V SPI, GND to USBN programming cable. Connect FTDI, do a JTAG chain scan, make sure JTAG can program. Connect USB programming cable. Set to Slave SPI ...
1422 - Can I configure the configuration SRAM memory with the Slave SPI Mode(SSPI)?
You can not configure the configuration SRAM memory directly with the Slave SPI Mode(SSPI), nor can you read back SRAM memory with the SSPI. But you can use the SSPI to configure the SRAM memory through a REFRESH instruction. The effect is the same ...
2313 - LatticeXP2: Is it possible to program the LatticeXP2 SRAM directly using slave SPI mode?
Solution: No, you cannot program SRAM in SLAVE SPI(SSPI) mode. SSPI can only be utilized to program and verify an encrypted or standard JEDEC file into embedded configuration Flash in background mode. It can be used to read the SRAM fuse cells in ...
105 - How can I determine if a LatticeXP2 FPGA configured from internal flash or from an external SPI flash?
The LatticeXP2 can be setup to operate in dual boot mode. Dual boot mode permits the LatticeXP2 to attempt to load a "working" configuration bitstream, and if that bitstream fails to properly configure the FPGA for a "golden" or "failsafe" bitstream ...