|
|||||||||||
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.Logic.Modules.Cordic
Generic width CORDIC unit which is technology independence. The CORDIC is parameterized with respect to wordsize, number of iterations, pipeline depth, angle type, and CORDIC function. Hardware to extend the domain of the CORDIC to +/-180 degrees can also be generated.
For an introduction to CORDIC processors, see Andraka, Ray. A survey of CORDIC algorithms for FPGA based computers.
The registers in the pipe can be stalled using a clk_en signal. clk_en can be passed in null for a perpetually enabled design. An exception will be thrown if clk_en is present when the CORDIC is unregistered.
There are two types of initial rotations hardware. The first is normal initial rotations, which takes operands in any quadrant of the Cartesian plane and returns the correct outputs. The second is small initial rotations. This mode allows inputs from any quadrant, but restricts the range of input and output angles to +/- 90 degrees. Positions in the left half of the Cartesian plane are represented with a negative magnitude for polar notation (output of VECTOR mode, input of ROTATIONAL mode). Rectangular inputs and outputs are unchanged in their representation.
Angles are formatted in fixed point notation according to the following table:
FRACTION | DEGREE | RADIAN | |
Normal | .sxxxx... | sxxxxxxx.xxxx... | sx.xxxx... |
Initial Rotations | s.xxxx... | sxxxxxxxx.xxxx... | sxx.xxxx... |
Small Initial Rotations | .sxxxx... | sxxxxxxx.xxxx... | sx.xxxx... |
Field Summary | |
static CellInterface[] |
cell_interface
|
static int |
DEGREE
|
static int |
FRACTION
|
static int |
RADIAN
|
static int |
ROTATIONAL
|
static int |
UNIFIED
The default simulation model is behavioral |
static int |
VECTOR
|
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 | |
Cordic(Node parent,
int cordicmode,
int angletype,
boolean registered,
int num_iter,
int pipe_depth,
boolean init_rots,
boolean small_ir,
Wire clk_en,
Wire vec,
Wire xin,
Wire yin,
Wire zin,
Wire xout,
Wire yout,
Wire zout)
Constructor for CORDIC unit |
Method Summary | |
boolean |
cellInterfaceDeterminesUniqueNetlistStructure()
When false, the default behavior of this method, each cell will list itself separately in a netlist, guaranteeing that the netlist will not have invalid data at the expense of a larger file-size. |
void |
clock()
Users define synchronous behavior in this method using standard JHDL constructs. |
static int[] |
compute(int width,
int num_iterations,
int cordicmode,
int angletype,
boolean init_rot,
boolean small_rt,
int x,
int y,
int z,
int v)
Compute implements the behavior of the CORDIC for behavioral modelling of the circuit |
void |
propagate()
Users defined propagatable behavior using standard JHDL constructs. |
void |
reset()
If you define a behavior, you must also define a reset method for resetting the synchonous part of your model. |
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
public static final int UNIFIED
public static final int ROTATIONAL
public static final int VECTOR
public static final int FRACTION
public static final int DEGREE
public static final int RADIAN
Constructor Detail |
public Cordic(Node parent, int cordicmode, int angletype, boolean registered, int num_iter, int pipe_depth, boolean init_rots, boolean small_ir, Wire clk_en, Wire vec, Wire xin, Wire yin, Wire zin, Wire xout, Wire yout, Wire zout)
parent
- Parent of this circuitcordicmode
- Cordic.UNIFIED,Cordic.ROTATIONAL, or Cordic.VECTOR. UNIFIED will do both
modes of operation, with the control signal passed on the vec wire
(1 for vector mode, 0 for rotational mode). Vector mode will do
rectangular to polar conversions, Rotational mode does polar to
rectangular conversions.angletype
- Cordic.FRACTION, Cordic.DEGREE, or Cordic.RADIAN to select which type of
angles to use in the CORDICregistered
- True to add registers to the CORDICnum_iter
- Number of iterations to build. The maximum is wordsize-1pipe_depth
- Number of iterations per pipeline register. 1 for
fully pipelined. This parameter has no meaning if registered = false.init_rots
- True to add initial rotation hardware to the CORDIC to
extend the domain to +/-180 degrees.small_ir
- True to constrain input and output angles to +/-90
degress when using initial rotations. Points in the left half plane
are represented with a negative magnitude.clk_en
- Clock enable wire for the registers.vec
- Control wire for Unified mode CORDICxin
- X inputyin
- Y inputzin
- Angle inputxout
- X outputyout
- Y outputzout
- Angle outputMethod Detail |
public boolean cellInterfaceDeterminesUniqueNetlistStructure()
Cell
cellInterfaceDeterminesUniqueNetlistStructure
in class Cell
public void reset()
Structural
reset
in interface Clockable
reset
in class Structural
public static int[] compute(int width, int num_iterations, int cordicmode, int angletype, boolean init_rot, boolean small_rt, int x, int y, int z, int v)
width
- Wordsize of the CORDICnum_iterations
- Number of iterationscordicmode
- Cordic.UNIFIED, Cordic.ROTATIONAL, or Cordic.VECTOR. See constructor for
details.angletype
- Cordic.FRACTION,Cordic.DEGREE,or Cordic.RADIAN. See constructor for details.init_rot
- True for additional hardware to extend the domain of the
circuit to +/-180 degrees.small_rt
- True to constrain input and output angles to the range
+/- 90 degrees. Points in the left half plane are represented with a
negative magnitude.x
- X input.y
- Y input.z
- Angle input.v
- Control signal for unified mode.
public void propagate()
Structural
propagate
in interface byucc.jhdl.base.Propagateable
propagate
in class Structural
public void clock()
Structural
clock
in interface Clockable
clock
in class Structural
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |