|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbyucc.jhdl.base.Nameable
byucc.jhdl.base.Node
byucc.jhdl.base.Cell
byucc.jhdl.base.Structural
byucc.jhdl.Logic.LogicGates
byucc.jhdl.Logic.LogicStatic
byucc.jhdl.Logic.Logic
byucc.jhdl.Xilinx.Virtex.Modules.ramrom
Generic Ram or Rom generator
Ramrom generates a synchronous or asynchronous ram, a dual-ported ram, or a rom up to 256X64 in size. The size of the ram or rom with address size "a" and output size "o" is 2aXo. If it is a ram, the input must be the same size as the output, otherwise an exception is thrown. Passing true for the "synch" parameter gives you a synchronous ram (synchronous write, asynchronous read), otherwise it is asynchronous. The ram or rom can be initialized by passing in an array of longs. The default initialization of the memory cells is all zeros unless an init array is passed. The size of the init array can be no bigger than 2a, otherwise an exception is thrown. If it is smaller than 2a, then zeros are filled into the high order rom cells. If any init value represents a value larger than can be stored in the ram or rom, an exception is thrown.
If the address size is from 1-5, this module simply instantiates the appropriate ram or rom. If the address size is from 5 (for the dual-ported ram) to 8, it instantiates multiple rams or roms and uses muxes to select the appropriate output. Also, the rams make use of LUTS to generate the appropriate write-enable signal for each of the rams. Any size address that isn't between 1 and 8 causes an exception to be thrown.
CLB count:
Slice count: The slice count and placement will be about the same as the XC4000 CLB count
Field Summary | |
static CellInterface[] |
cell_interface
|
Fields inherited from class byucc.jhdl.Logic.Logic |
ABOVE, ALIGN_BOTTOM, ALIGN_CENTER, ALIGN_LEFT, ALIGN_LSB, ALIGN_MSB, ALIGN_RIGHT, ALIGN_TOP, BELOW, DOWN, EAST_OF, LEFT_OF, MAX_PACK, NORTH_OF, ON, ONTOP, ONTOP_OF, RIGHT_OF, SOUTH_OF, TOLEFT, TORIGHT, UNCONSTRAINED, UP, WEST_OF |
Fields inherited from class byucc.jhdl.Logic.LogicGates |
tech_mapper |
Constructor Summary | |
ramrom(Node parent,
Wire a,
Wire o,
int[] contents)
|
|
ramrom(Node parent,
Wire a,
Wire o,
int[] contents,
java.lang.String name)
|
|
ramrom(Node parent,
Wire a,
Wire o,
long[] contents)
|
|
ramrom(Node parent,
Wire a,
Wire o,
long[] contents,
java.lang.String name)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire o,
boolean synch)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire o,
boolean synch,
int[] contents)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire o,
boolean synch,
int[] contents,
java.lang.String name)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire o,
boolean synch,
long[] contents)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire o,
boolean synch,
long[] contents,
java.lang.String name)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire o,
boolean synch,
java.lang.String name)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire dpra,
Wire spo,
Wire dpo)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire dpra,
Wire spo,
Wire dpo,
int[] contents)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire dpra,
Wire spo,
Wire dpo,
int[] contents,
java.lang.String name)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire dpra,
Wire spo,
Wire dpo,
long[] contents)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire dpra,
Wire spo,
Wire dpo,
long[] contents,
java.lang.String name)
|
|
ramrom(Node parent,
Wire d,
Wire we,
Wire a,
Wire dpra,
Wire spo,
Wire dpo,
java.lang.String name)
|
Method Summary | |
static int |
compute()
No computation necessary in this class, so compute always returns a zero |
protected boolean |
defaultSimulationModelIsBehavioral()
Default simulation model is behavioral |
BV |
getMemoryElement(int addr)
Return the given memory position |
BV |
getMemoryElement(int addr,
BV data)
Return the given memory position |
BV[] |
getMemoryRange(int sIndex,
int elements)
Return the given memory range |
BV[] |
getMemoryRange(int sIndex,
int elements,
BV[] data)
Return the given memory range |
int |
getMemoryWidth()
Returns the memory width |
long |
getSize()
Returns the memory size |
boolean |
loadMemoryFile(java.lang.String filename)
|
void |
reset()
Resets the output to zero |
void |
writeMemoryElement(int addr,
BV value)
|
void |
writeMemoryRange(int addr,
int elements,
BV[] values)
|
Methods inherited from class byucc.jhdl.base.Node |
addObservable, addSimulatorCallback, checkAll, delete, getBuildingFlag, getChildren, getChildrenEnumeration, getInstanceName, getParent, getParentCell, getRelatives, getSystem, getWires, optimize, orphanAllowed, printAllChildren, printTree, removeSimulatorCallback, setDefaultClock |
Methods inherited from class byucc.jhdl.base.Nameable |
caseSensitivity, caseSensitivity, disableNameClashChecking, getFullName, getFullNameNoTestBench, getHierNameNoTestBench, getInstanceNo, getInstanceNumber, getLeafName, getLeafName, getRelativeName, getUserName, getUserName, hasUserSpecifiedName, isDescendantOf, setInstanceNumber |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static CellInterface[] cell_interface
Constructor Detail |
public ramrom(Node parent, Wire a, Wire o, int[] contents)
public ramrom(Node parent, Wire a, Wire o, int[] contents, java.lang.String name)
public ramrom(Node parent, Wire a, Wire o, long[] contents)
public ramrom(Node parent, Wire a, Wire o, long[] contents, java.lang.String name)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire o, boolean synch)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire o, boolean synch, java.lang.String name)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire o, boolean synch, int[] contents)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire o, boolean synch, int[] contents, java.lang.String name)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire o, boolean synch, long[] contents)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire o, boolean synch, long[] contents, java.lang.String name)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire dpra, Wire spo, Wire dpo)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire dpra, Wire spo, Wire dpo, java.lang.String name)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire dpra, Wire spo, Wire dpo, int[] contents)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire dpra, Wire spo, Wire dpo, int[] contents, java.lang.String name)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire dpra, Wire spo, Wire dpo, long[] contents)
public ramrom(Node parent, Wire d, Wire we, Wire a, Wire dpra, Wire spo, Wire dpo, long[] contents, java.lang.String name)
Method Detail |
public BV[] getMemoryRange(int sIndex, int elements)
MemoryInterface
getMemoryRange
in interface MemoryInterface
sIndex
- the starting indexelements
- how many entries to get
public BV getMemoryElement(int addr)
MemoryInterface
getMemoryElement
in interface MemoryInterface
addr
- the memory address to get
public long getSize()
MemoryInterface
getSize
in interface MemoryInterface
public int getMemoryWidth()
MemoryInterface
getMemoryWidth
in interface MemoryInterface
public BV[] getMemoryRange(int sIndex, int elements, BV[] data)
LargeMemoryInterface
getMemoryRange
in interface LargeMemoryInterface
sIndex
- the starting indexelements
- how many entries to getdata
- where to stick the results
public BV getMemoryElement(int addr, BV data)
LargeMemoryInterface
getMemoryElement
in interface LargeMemoryInterface
addr
- the memory address to getdata
- where to stick the results
public boolean loadMemoryFile(java.lang.String filename)
loadMemoryFile
in interface LargeWritableMemory
public void writeMemoryRange(int addr, int elements, BV[] values)
writeMemoryRange
in interface LargeWritableMemory
public void writeMemoryElement(int addr, BV value)
writeMemoryElement
in interface LargeWritableMemory
public void reset()
reset
in interface Clockable
reset
in class Structural
protected boolean defaultSimulationModelIsBehavioral()
defaultSimulationModelIsBehavioral
in class Structural
public static int compute()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |