All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class byucc.jhdl.modgen.delay

java.lang.Object
   |
   +----byucc.jhdl.base.Nameable
           |
           +----byucc.jhdl.base.Node
                   |
                   +----byucc.jhdl.base.Cell
                           |
                           +----byucc.jhdl.base.Structural
                                   |
                                   +----byucc.jhdl.Logic.Logic
                                           |
                                           +----byucc.jhdl.modgen.delay

public class delay
extends Logic
implements MemoryInterface

General Description

Generic Delay Line

This delays a data word for a given number of cycles. The delay line can be stalled by setting clk_en=0. The delay can be for any number of cycles, and is specified at construction time. The input and output can each be up to 64 bits wide and must be the same width.

 

Implementation

All Technologies

This module uses rams to store the data and a 4-bit downcounter to access the various addresses on the rams. To get more than 16 delay cycles, the number of delay cycles needed is divided as evenly as possible into blocks of <= 16 cycles. These blocks are placed into cascading 16x1 rams. If each block is exactly the same size, a single downcounter is used to control the rams. If the blocks can't be divided evenly, some of the rams will store the information for one more cycle than the others and 2 downcounterss are used. To get more than 64 cycles of delay, this class recursively stacks 64-cycle versions of itself together and then has a delay line taking care of the remaining cycles at the end.

Xilinx XC4000

CLB count:


Fill in the fields below and press compute

Input Width (default 1):

Number of Delay Cycles (default 0):

Number of CLB's if implementing delay line:

Number of CLB's if implementing flip flops:


CLB placement:

The orientation of the CLBs is as follows: The downcounter(s) are placed in a column on the left hand side, either two CLBs high or four CLBs high, depending on whether only one downcounter was used or two. To the right of the downcounters are the rams holding the data. Here is the height of the CLB stack according to the number of delay cycles:
1-16 cycles: 2 CLBs high
17-32 cycles: 4 CLBs high
33-48 cycles: 6 CLBs high
48-64 cycles: 8 CLBs high

Author:
Tim Wheeler

Variable Index

 o cell_interface
 o cellname
The input is a generic width

Constructor Index

 o delay(Node, int, Wire, Wire, Wire)

Method Index

 o clock()
Clock is used in the behavioral model and is called once per clock cycle
 o compute()
No computation necessary in this class, so compute always returns a zero
 o defaultSimulationModelIsBehavioral()
Default simulation model is behavioral
 o getCellName()
 o getMemoryElement(int)
 o getMemoryRange(int, int)
 o getMemoryWidth()
 o getSize()
 o propagate()
Propagate is used only if the number of delay cycles = 0
 o reset()
Resets the output to zero

Variables

 o cell_interface
 public static CellInterface cell_interface[]
 o cellname
 public static final String cellname
The input is a generic width

Constructors

 o delay
 public delay(Node parent,
              int num_of_cyc,
              Wire in,
              Wire clk_en,
              Wire out)
Parameters:
parent - parent of the class (this)
num_of_cyc - the number of clock cycles of delay
in - input signal
clk_en - if low, the contents of the delay rams remain unchanged
out - output signal

Methods

 o getCellName
 public String getCellName()
Overrides:
getCellName in class Cell
 o getMemoryRange
 public BigInteger[] getMemoryRange(int sIndex,
                                    int elements)
 o getMemoryElement
 public BigInteger getMemoryElement(int addr)
 o getSize
 public long getSize()
 o getMemoryWidth
 public int getMemoryWidth()
 o reset
 public void reset()
Resets the output to zero

Overrides:
reset in class Structural
 o clock
 public void clock()
Clock is used in the behavioral model and is called once per clock cycle

Overrides:
clock in class Structural
 o propagate
 public void propagate()
Propagate is used only if the number of delay cycles = 0

Overrides:
propagate in class Structural
 o defaultSimulationModelIsBehavioral
 protected boolean defaultSimulationModelIsBehavioral()
Default simulation model is behavioral

Overrides:
defaultSimulationModelIsBehavioral in class Structural
 o compute
 public static int compute()
No computation necessary in this class, so compute always returns a zero


All Packages  Class Hierarchy  This Package  Previous  Next  Index