public class Fpga
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
Fpga.BITVECTOR
Defines an numeric variable in VHDL as BIT_VECTOR(
|
static interface |
Fpga.ClockedInput
Defines that an input pin of the Fpga or of an module should be clocked immediately.
|
static interface |
Fpga.GetterVhdl
Defines that an Operation is existing in the module class to access data from RECORD instance (associated to a PROCESS).
|
static interface |
Fpga.IfcAccess
Defines a sub module in another module which is only responsible to implement an interface
as access point to the containing module.
|
static interface |
Fpga.STDVECTOR
Defines an numeric variable in VHDL as STD_LOGIC_VECTOR(
|
static interface |
Fpga.VHDL_PROCESS
Defines an numeric variable in VHDL as STD_LOGIC_VECTOR(
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
sVersion
Version, history and license.
|
Constructor and Description |
---|
Fpga() |
Modifier and Type | Method and Description |
---|---|
static void |
checkDbg(boolean cond) |
static void |
checkTime(int time,
int ztime,
int min)
Check the time.
|
static boolean |
checkVector(java.lang.Class<?> inClass,
java.lang.String var,
int nrBits)
Checks the size of a vector adequate to its annotation
|
static int |
concatbits(int high,
int bitPos,
int low)
Concatenate two bit vectors
|
static boolean |
getBit(int vector,
int bit)
Gets one bit from a vector.
|
static int |
getBits(int vector,
int msb,
int lsb)
Returns in VHDL vector(6 DOWNTO 2) if msp=6 and lsb=2.
|
static int |
getBitsShL(int vector,
int nrBits,
boolean low)
Shifts a vector 1 to left and replaces the bit 0 with low value.
|
static int |
getBitsShR(boolean high,
int bitHigh,
int vector)
Shifts a vector 1 to right and replaces the ms bit with high value.
|
static void |
measTime(int[] tgroup,
int ixGroup,
int tdiff) |
static int |
setBit(int vector,
int bit,
boolean value)
Gets one bit from a vector.
|
static int |
setBits(int vector,
int dstMSB,
int dstLSB,
int value)
Replaces the dedicated bits with value.
|
public static final java.lang.String sVersion
setBits(int, int, int, int)
without 5th argument.
public static int setBit(int vector, int bit, boolean value)
vector
- variable which presents a Vhdl vectorbit
- bit number set in vector output in the return value, should be a simple const number.value
- the value to set to this bits. An ordinary expression of bool type.
On VHDL an automatic conversion to STD_VECTOR will be done if necessary.public static int setBits(int vector, int dstMSB, int dstLSB, int value)
vector
- the given vector, for the unchanged bits in return, current value.dstMSB
- most significant bit set in vector output in the return value, should be a simple const number.dstLSB
- last significant bit set in vector output in the return value, should be a simple const number.value
- the value to set to this bits, the same number of bits are used. An ordinary expression.public static boolean getBit(int vector, int bit)
vector
- variable which presents a Vhdl vectorbit
- the bit, from 0public static int getBitsShL(int vector, int nrBits, boolean low)
vector
- the previous state (z)nrBits
- valid number of bits to shiftlow
- It should present a boolean for a Vhdl: BITpublic static int getBitsShR(boolean high, int bitHigh, int vector)
high
- most significant bit to replace. It should present a boolean for a Vhdl: BITbitHigh
- bit position for high or number of bits to shift for vector. vector is used with (bithigh downto 1)vector
- public static int getBits(int vector, int msb, int lsb)
vector
- msb
- the msb bit itself inclusivelylsb
- the lsb inclusively.public static int concatbits(int high, int bitPos, int low)
high
- bitPos
- Position where high should be placed in result.
This should be exact the length of low, checked in assertion.low
- public static void measTime(int[] tgroup, int ixGroup, int tdiff)
public static boolean checkVector(java.lang.Class<?> inClass, java.lang.String var, int nrBits)
inClass
- var
- The field in this class.nrBits
- public static void checkTime(int time, int ztime, int min)
time
- current time of accessztime
- time of the accessed variablemin
- minimal difference.public static void checkDbg(boolean cond)