Modifier and Type | Class and Description |
---|---|
static class |
Sim.HistEnt |
static class |
Sim.Node |
static class |
Sim.Range |
static class |
Sim.Resists |
static class |
Sim.Thev |
static class |
Sim.Trans |
SimAPI.Analyzer
Modifier and Type | Field and Description |
---|---|
long |
curDelta
current simulated time
|
Sim.Node |
curNode
node that belongs to current event
|
Sim.Node |
groundNode
ground supply node
|
static double |
LARGE
A large number
|
static double |
LIMIT
R > LIMIT are considered infinite
|
static int |
MAX_ERRS |
long |
maxTime |
long |
nEvent
number of current event
|
static int |
NTTYPES
number of transistor types defined
|
int |
numAliases
number of aliased nodes
|
int |
numConsPunted |
int |
numEdges |
int |
numNodes
number of actual nodes
|
int |
numPunted |
Sim.Trans[] |
parallelTransistors |
Sim.Node |
powerNode
power supply node
|
static double |
SMALL
A small number
|
static java.lang.String[] |
states |
Sim.Trans |
tCap
list of capacitor-transistors
|
long |
tDecay
number of DELAY-units after which undriven nodes decay to X
|
int |
tReport |
int |
tUnitDelay
if nonzero, all transactions take this DELAY-units
|
static java.lang.String |
vChars |
boolean |
withDriven |
ALIAS, ALWAYSON, BROKEN, CROSSED, DEBUG_DC, DEBUG_EV, DEBUG_SPK, DEBUG_TAU, DEBUG_TAUP, DEBUG_TW, DECAY, DECAY_EV, DEP, DYNHIGH, DYNLOW, GATELIST, H_INPUT, HIGH, INPUT, INPUT_MASK, L_INPUT, LOW, MERGED, MIN_CAP, N_POTS, NCHAN, OFF, ON, ORED, ORLIST, PARALLEL, PBROKEN, PCHAN, PENDING, POWER, POWER_RAIL, R_HIGH, R_LOW, R_TYPES, REPORT_CAP, REPORT_DECAY, REPORT_DELAY, REPORT_TAU, REPORT_TCOORD, RESIST, resolutionScale, REVAL, STATIC, STOPONCHANGE, STOPVECCHANGE, TCAP, U_INPUT, UNKNOWN, USERDELAY, VISITED, WATCHED, WATCHVECTOR, WEAK, X, X_INPUT, X_X
Constructor and Description |
---|
Sim(int irDebug,
java.lang.String steppingModel,
boolean isDelayedX) |
Modifier and Type | Method and Description |
---|---|
void |
addHist(Sim.Node node,
int value,
boolean inp,
long time,
long delay,
long rTime)
Add a new entry to the history list.
|
void |
addPunted(Sim.Node node,
Eval.Event ev,
long tim)
Add a punted event to the history list for the node.
|
void |
backSimTime(long bTime,
int isInc)
Back the event queues up to time 'bTime'.
|
void |
backToTime(SimAPI.Node nd_) |
void |
buildConnList(Sim.Node n)
Build a linked-list of nodes (using nLink entry in Node structure)
which are electrically connected to node 'n'.
|
void |
clearCurNode() |
void |
clearReport() |
Sim.Node |
findNode(java.lang.String name)
find node in network
|
void |
finishNetwork() |
Config |
getConfig() |
long |
getCurDelta()
current simulated time
|
long |
getDecay() |
Sim.Node |
getGroundNode() |
double |
getLambda()
Get lambda value in nanometers
|
long |
getLambdaCM() |
long |
getMaxTime() |
Eval |
getModel() |
java.util.List<Sim.Node> |
getNodeList()
Return a list of all nodes in the network.
|
java.util.List<SimAPI.Node> |
getNodes() |
int |
getNumAliases() |
int |
getNumConsPunted() |
int |
getNumEdges() |
long |
getNumEvents() |
int |
getNumNodes() |
int |
getNumPunted() |
Sim.Node |
getPowerNode() |
int |
getReport() |
java.util.List<SimAPI.Trans> |
getShortedTransistors() |
int |
getUnitDelay() |
void |
initNetwork()
1 -> 1ns, 100 -> 0.01ns resolution, etc
|
int |
inputSim(java.io.Reader simReader,
java.lang.String fileName)
Load a .sim file into memory.
|
void |
loadConfig(java.net.URL parameterURL,
SimAPI.Analyzer analyzer) |
java.lang.String[] |
parseLine(java.lang.String line) |
static java.lang.String[] |
parseLine(java.lang.String line,
boolean expand,
SimAPI.Analyzer analyzer)
parse input line into tokens, filling up carg and setting targc
|
void |
printPendingEvents() |
void |
putCapacitor(java.lang.String net1,
java.lang.String net2,
double capacitance)
Put capacitor into the circuit
|
void |
putResistor(java.lang.String net1,
java.lang.String net2,
double resistance)
Put resistor into the circuit
|
void |
putTransistor(java.lang.String gateName,
java.lang.String sourceName,
java.lang.String drainName,
double gateLength,
double gateWidth,
double activeArea,
double activePerim,
double centerX,
double centerY,
boolean isNTypeTransistor)
Put triansitor into the circuit
|
void |
reInit()
Set the firstCall flags.
|
static void |
reportError(java.lang.String filename,
int lineno,
java.lang.String msg) |
void |
setAnalyzer(SimAPI.Analyzer analyzer) |
void |
setCurDelta(long curDelta)
current simulated time
|
void |
setDebug(int irDebug) |
void |
setDecay(long decay) |
void |
setModel(boolean rc) |
void |
setReport(int mask) |
void |
setUnitDelay(int unitDelay) |
boolean |
step(long stopTime,
java.util.Collection<SimAPI.Node> xInputs,
java.util.Collection<SimAPI.Node> hInputs,
java.util.Collection<SimAPI.Node> lInputs,
java.util.Collection<SimAPI.Node> uInputs) |
public static final double SMALL
public static final double LARGE
public static final double LIMIT
public static final int NTTYPES
public static java.lang.String vChars
public static java.lang.String[] states
public static final int MAX_ERRS
public Sim.Node powerNode
public Sim.Node groundNode
public int numNodes
public int numAliases
public Sim.Trans tCap
public Sim.Trans[] parallelTransistors
public int numEdges
public int numPunted
public int numConsPunted
public long maxTime
public long curDelta
public Sim.Node curNode
public long nEvent
public int tUnitDelay
public long tDecay
public int tReport
public boolean withDriven
public Sim.Node findNode(java.lang.String name)
public java.util.List<Sim.Node> getNodeList()
public java.util.List<SimAPI.Node> getNodes()
public Sim.Node getGroundNode()
getGroundNode
in interface SimAPI
public Sim.Node getPowerNode()
getPowerNode
in interface SimAPI
public int getNumNodes()
getNumNodes
in interface SimAPI
public int getNumAliases()
getNumAliases
in interface SimAPI
public int getNumEdges()
getNumEdges
in interface SimAPI
public int getNumPunted()
getNumPunted
in interface SimAPI
public int getNumConsPunted()
getNumConsPunted
in interface SimAPI
public long getNumEvents()
getNumEvents
in interface SimAPI
public java.util.List<SimAPI.Trans> getShortedTransistors()
getShortedTransistors
in interface SimAPI
public void clearReport()
clearReport
in interface SimAPI
public long getMaxTime()
getMaxTime
in interface SimAPI
public long getCurDelta()
getCurDelta
in interface SimAPI
public void setCurDelta(long curDelta)
SimAPI
setCurDelta
in interface SimAPI
public void clearCurNode()
clearCurNode
in interface SimAPI
public void reInit()
public void backSimTime(long bTime, int isInc)
backSimTime
in interface SimAPI
public void printPendingEvents()
printPendingEvents
in interface SimAPI
public boolean step(long stopTime, java.util.Collection<SimAPI.Node> xInputs, java.util.Collection<SimAPI.Node> hInputs, java.util.Collection<SimAPI.Node> lInputs, java.util.Collection<SimAPI.Node> uInputs)
public long getLambdaCM()
getLambdaCM
in interface SimAPI
public int getUnitDelay()
getUnitDelay
in interface SimAPI
public void setUnitDelay(int unitDelay)
setUnitDelay
in interface SimAPI
public void loadConfig(java.net.URL parameterURL, SimAPI.Analyzer analyzer)
loadConfig
in interface SimAPI
public void setAnalyzer(SimAPI.Analyzer analyzer)
setAnalyzer
in interface SimAPI
public Config getConfig()
public Eval getModel()
public static void reportError(java.lang.String filename, int lineno, java.lang.String msg)
public java.lang.String[] parseLine(java.lang.String line)
public static java.lang.String[] parseLine(java.lang.String line, boolean expand, SimAPI.Analyzer analyzer)
expand
- true to expand iterators. For example, the
string "out.{1:10}" expands into ten arguments "out.1", ..., "out.10".
The string can contain multiple iterators which will be expanded
independently, e.g., "out{1:10}{1:20:2}" expands into 100 arguments.public void putTransistor(java.lang.String gateName, java.lang.String sourceName, java.lang.String drainName, double gateLength, double gateWidth, double activeArea, double activePerim, double centerX, double centerY, boolean isNTypeTransistor)
putTransistor
in interface SimAPI
gateName
- name of transistor gate networksourceName
- name of transistor gate networkdrainName
- drain name of transistor gate networkgateLength
- gate length (lambda)gateWidth
- gate width (lambda)activeArea
- active area (lambda^2)activePerim
- active perim (lambda^2)centerX
- x-coordinate of center (lambda)centerY
- y coordinate of cneter (lambda)isNTypeTransistor
- true if this is N-type transistorpublic void putResistor(java.lang.String net1, java.lang.String net2, double resistance)
putResistor
in interface SimAPI
net1
- name of first terminal networknet2
- name of second terminal networkresistance
- resistance (ohm)public void putCapacitor(java.lang.String net1, java.lang.String net2, double capacitance)
putCapacitor
in interface SimAPI
net1
- name of first terminal networknet2
- name of second terminal networkcapacitance
- capacitance (pf)public int inputSim(java.io.Reader simReader, java.lang.String fileName) throws java.io.IOException
public void initNetwork()
SimAPI
initNetwork
in interface SimAPI
public void finishNetwork()
finishNetwork
in interface SimAPI
public double getLambda()
public void buildConnList(Sim.Node n)
public void addHist(Sim.Node node, int value, boolean inp, long time, long delay, long rTime)
public void addPunted(Sim.Node node, Eval.Event ev, long tim)
public void backToTime(SimAPI.Node nd_)
backToTime
in interface SimAPI