background image

iCE40 SPRAM Usage Guide 

 

Technical Note 
 
 

© 2016 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. 

 

TN1314-1.0 

4.4.

 

Cascading Memories 

Each SPRAM block is 256 kb, supporting configuration that are 16K x 16. These memories are cascaded to form larger 
memory based on the user requirements. The memories can be cascaded in two ways: 

 

Address Cascading or  

 

Data Cascading. 

The following sections provide examples of how each cascading type is achieved, and the connection of the signals 
required. User can instantiate the RAM primitive and connect them using this as guidance to create larger memory 
blocks. 

Auto cascading is supported while inferring a RAM. Any additional logic required will be implemented in the device 
fabric for creating larger memories.  

 

Address Cascading (or Depth Cascading) 

4.4.1.

Address/Depth cascading is useful when the memories are required to have the capacity of storing “more” words while 
keeping the data width the same. In this case additional user logic is needed to decode the address. 

Figure 4.1

 shows an example of the depth cascading of a 32K x 16 SPRAM. Additional logic is required that will guide 

the data to the correct memory block using Muxes and Demuxes. The rest of the signals (that are not shown), should 
be connected to both the memory blocks without any other logic requirements. 

Single Port RAM

Primitive

SB_SPRAM256KA

ADDRESS [13:0]

DATAIN [15:0]

WREN

MASKWREN [3:0]

CHIPSELECT

CLOCK

STANDBY

SLEEP

POWEROFF

DATAOUT [15:0]

Single Port RAM

Primitive

SB_SPRAM256KA

ADDRESS [13:0]

DATAIN [15:0]

WREN

MASKWREN [3:0]

CHIPSELECT

CLOCK

STANDBY

SLEEP

POWEROFF

DATAOUT [15:0]

1

0

1

0

DATAOUT [15:0]

1

0

ADDRESS [14:0]

DATAIN [15:0]

WREN

MASKWREN [3:0]

CHIPSELECT

CLOCK

STANDBY

SLEEP

POWEROFF

ADDRESS [14]

ADDRESS [13:0]

 

Figure 4.1. Address/Depth Cascading Example for 32K x 16 SPRAM using Primitive 

Summary of Contents for iCE40 SPRAM Series

Page 1: ...iCE40 SPRAM Usage Guide Technical Note TN1314 Version 1 0 June 2016...

Page 2: ...ons and GUI Options 4 Power Save States for SPRAM 6 3 3 1 Normal State 6 3 2 Standby State 6 3 3 Sleep State 6 3 4 Power Off State 6 Use Cases for User Primitive SB_SPRAM256KA 7 4 4 1 Instantiating Me...

Page 3: ...r 256 kb memory blocks available that is total 1024 kb of Single Port memory Single Port RAM Primitives 2 The iCE40 devices offer four embedded memory blocks of SPRAM Each of these blocks can be confi...

Page 4: ...DATAIN 15 0 D 15 0 Data Input 16b 0000000000000000 The Data Input bus is used to write the data into the memory location specified by Address input port during the write cycle MASKWREN 3 0 WEM 15 0 M...

Page 5: ...us the MASKWREN has to map to WEM as follows MASKWREN 3 WEM 15 MASKWREN 3 WEM 14 MASKWREN 3 WEM 13 MASKWREN 3 WEM 12 MASKWREN 2 WEM 11 MASKWREN 2 WEM 10 MASKWREN 2 WEM 9 MASKWREN 2 WEM 8 MASKWREN 1 WE...

Page 6: ...not change when the RAM is placed in Standby State It is to be noted that Standby State is referred to as Light Sleep state in the RAM datasheet The name STANDBY has been chosen to match and be consis...

Page 7: ...ROFF POWEROFF DATAOUT DATAOUT_A SB_SPRAM256KA ramfn_inst2 DATAIN DATAIN ADDRESS ADDRESS MASKWREN MASKWREN WREN WREN CHIPSELECT CHIPSELECT CLOCK CLOCK STANDBY STANDBY SLEEP SLEEP POWEROFF POWEROFF DATA...

Page 8: ...ogic required will be implemented in the device fabric for creating larger memories Address Cascading or Depth Cascading 4 4 1 Address Depth cascading is useful when the memories are required to have...

Page 9: ...gic is needed essentially for concatenating words from individual SPRAM blocks Figure 4 2 shows an example of the Width cascading of a 16k x 32 SPRAM The rest of the signals that are not shown should...

Page 10: ...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 t...

Page 11: ...d 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...

Page 12: ...7 th Floor 111 SW 5 th Avenue Portland OR 97204 USA T 503 268 8000 www latticesemi com...

Reviews: