Auto Programming
UG0451 User Guide Revision 7.0 21
5 Auto Programming
In auto programming mode, SmartFusion2 and IGLOO2 devices program themselves by downloading
the bitstream from an external SPI flash device. The system controller configures the MSS or HPMS
SPI_0 port for the SPI master mode when the dedicated FLASH_GOLDEN_N pin is asserted low upon
system reboot. An external SPI flash memory device programmed with a bitstream has to be connected
to the SPI_0 port. SPI_0 port requires serial flash devices supporting the RDID (9F), 24-bit read (0B),
and 32-bit read (0C). If RDID indicates a size greater than 2^24 the firmware switches to using the 0C
command, otherwise it uses 0B.
Note: FLASH_GOLDEN_N pin is not available in all packages. For more information, see Table 3, page 7.
5.1 Programming Interface Overview
MSS/HPMS SPI_0 port is used as the programming interface during auto programming. SPI_0 port is
located in a specific bank. See the pin tables of the respective devices for the bank numbers. These ports
are part of MSIOs. The bank must be powered up before programming the devices. The following table
provides description of the SPI_0 pins.
5.1.1 Design Implementation
In auto programming, an external SPI flash memory is preprogrammed and attached to the MSS/HPMS
SPI_0 port of a blank SmartFusion2 or IGLOO2 device.
The programming bitstream must be programmed at a location other than address 0x00 of the SPI flash
connected to the MSS/HPMS SPI_0 port. Address 0x00 is reserved for the SPI directory.
During auto programming, authentication system service is not available. Microsemi recommends
encrypting the golden bitstream with custom security. Custom security is enabled in the Libero SoC
software (see Security Policy Manager in the Libero Online Help). For more information about
authentication, see In-Application Programming, page 29.
When programming begins, if the system controller detects a corrupted bitstream, programming is
aborted. In this case, a valid bitstream must be programmed into the SPI flash and auto programming
needs to be reinitiated.
The following figure shows the recommended board configuration to support auto programming. The
target board must provide power to the VPP, VPPNVM, VDD, and VDDIOx (where x = SPI_0 interface
bank number) pins.
For the recommended voltage ranges and pin locations, see the SmartFusion2 and IGLOO2 Datasheet
and the corresponding package pin assignment table.
For information about the I/O states during auto programming, see State of SmartFusion2 and IGLOO2
Components During Programming, page 42.
Table 8 • MSS/HPMS SPI_0 Signals
Name Type Descriptions
SPI_0_SDI Input Serial data input
SPI_0_SDO Output Serial data output
SPI_0_CLK Output Serial clock. It is a serial programmable bit rate clock out signal.
SPI_0_SSO
1
1. Active low signal.
Output Slave select
FLASH_GOLDEN_N
1
Input If pulled low, the SPI_0 port is put into master mode, which indicates that the
device is to be reprogrammed from an image in the external SPI flash
attached to the SPI_0 interface.