|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthades.simulator.SimObject
hades.models.gates.GenericGate
hades.models.io.ClockGenWithAutoStop
ClockGenWithAutoStop: a clock generator which stops after a predefined number of clock cycles.
Properties include clock frequency, duty cycle, clock phase, and the number of clock cycles. Default is a symmetric 1 Hz clock signal which stops after 1000 cycles. Signals are expected to be StdLogic1164 objects.
UUUUUUUUUUUUUUUUU+ +-----+ +-----+ +-----+ +----------------+----+ +----+ +----+ + .... +--------- | | | | | | |< offset >|< period >|< >| | <#count cycles> dutycycle
Field Summary |
Fields inherited from class hades.models.gates.GenericGate |
t_delay |
Fields inherited from class hades.simulator.SimObject |
classloader, console, editor, name, parent, ports, propertySheet, simulator, symbol, versionId, visible |
Constructor Summary | |
ClockGenWithAutoStop()
ClockGenWithAutoStop: simple constructor. |
Method Summary | |
void |
configure()
configure: display a dialog window with options to specify instance name, clock period, clock duty-cycle, clock phase (offset), and the number of cycles to stop after. |
void |
elaborate(java.lang.Object arg)
elaborate: store a reference to our simulator, then schedule the events for the initial "U" phase, the first "1" phase, and the first wakeup. |
void |
evaluate(java.lang.Object arg)
evaluate: as the ClockGen has no input signals, this method should never be called. |
int |
getAutoStopCycles()
|
double |
getDutycycle()
|
double |
getOffset()
|
double |
getPeriod()
|
java.lang.String |
getToolTip(java.awt.Point position,
long millis)
construct a tool tip message (with the timing parameters) |
boolean |
initialize(java.lang.String s)
initialize a ClockGenWithAutoStop'erator from a String. |
void |
mousePressed(java.awt.event.MouseEvent me)
start or stop this ClockGenWithAutoStop |
double |
parse(java.lang.String s)
|
void |
setAutoStopCycles(int n)
set the number of cycles to stop after. |
void |
setAutoStopCycles(java.lang.String s)
|
void |
setDutycycle(double d)
|
void |
setDutycycle(java.lang.String s)
|
void |
setOffset(double d)
|
void |
setOffset(java.lang.String s)
|
void |
setPeriod(double d)
|
void |
setPeriod(java.lang.String s)
|
void |
setSymbol(Symbol s)
|
java.lang.String |
toString()
toString() - the usual info method |
void |
wakeup(java.lang.Object arg)
wakeup(): Called by the simulator as a reaction to our own scheduleWakeup()-calls. |
void |
write(java.io.PrintWriter ps)
write the integer version ID, the clock period (in seconds), the clock 1-value dutycycle, the clock phase (offset, in seconds), and the number of cycles to stop after. |
Methods inherited from class hades.models.gates.GenericGate |
copy, getDelay, scheduleEvent, scheduleEventAfter, scheduleOutputValue, scheduleOutputValueAfter, setDelay, setDelay |
Methods inherited from class hades.simulator.SimObject |
constructDynamicSymbol, getBindkey, getClassLoader, getDebug, getEditor, getExternalResources, getFullName, getName, getParent, getPort, getPorts, getPropertySheet, getResourceAsStream, getSimulator, getSymbol, getSymbolResourceName, getVersionId, isVisible, keyPressed, message, needsDynamicSymbol, needsExternalResources, setClassLoader, setConsole, setDebug, setEditor, setName, setParent, setPorts, setSimulator, setVersionId, setVisible, tearDown |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface hades.simulator.Simulatable |
message |
Constructor Detail |
public ClockGenWithAutoStop()
Method Detail |
public void setSymbol(Symbol s)
setSymbol
in class SimObject
public double getPeriod()
public double getOffset()
public double getDutycycle()
public int getAutoStopCycles()
public void setPeriod(double d)
public void setOffset(double d)
public void setDutycycle(double d)
public void setAutoStopCycles(int n)
public void setPeriod(java.lang.String s)
public void setOffset(java.lang.String s)
public void setDutycycle(java.lang.String s)
public void setAutoStopCycles(java.lang.String s)
public double parse(java.lang.String s)
public boolean initialize(java.lang.String s)
initialize
in class GenericGate
public void write(java.io.PrintWriter ps)
write
in class GenericGate
public void configure()
configure
in class GenericGate
public void mousePressed(java.awt.event.MouseEvent me)
mousePressed
in class SimObject
public void elaborate(java.lang.Object arg)
elaborate
in interface Simulatable
elaborate
in class GenericGate
public void evaluate(java.lang.Object arg)
evaluate
in interface Simulatable
evaluate
in class SimObject
arg
- an arbitrary object argumentpublic void wakeup(java.lang.Object arg)
wakeup
in interface Wakeable
arg
- - unsued argumentpublic java.lang.String getToolTip(java.awt.Point position, long millis)
getToolTip
in interface ContextToolTip
getToolTip
in class GenericGate
public java.lang.String toString()
toString
in class SimObject
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |