| Both sides previous revisionPrevious revisionNext revision | Previous revision |
| help:scripting [2022/07/14 16:51] – [File operations] danil | help:scripting [2026/05/12 10:35] (current) – [Global variables] danil |
|---|
| |
| For more information about these and other Workcraft startup options see [[:help:cli|Command line interface]] document. | For more information about these and other Workcraft startup options see [[:help:cli|Command line interface]] document. |
| |
| |
| ===== Functions and variables ===== | ===== Functions and variables ===== |
| </WRAP> | </WRAP> |
| |
| | ==== Global variables ==== |
| |
| | * ''args'' -- array of command line parameters passed to Workcraft; these can be iterated over as follows: ''for each (arg in args) {...}'' or accessed as ''args[0]'', ''args[1]'', etc. |
| ==== Global variables ==== | |
| * ''args'' -- command line parameters passed to Workcraft; these can be iterated over as follows: ''for each (arg in args) {...}'' | |
| * ''framework'' -- the Workcraft framework singleton | * ''framework'' -- the Workcraft framework singleton |
| * ''workspaceEntry'' -- the current work | * ''workspaceEntry'' -- the current work |
| * ''setWorkingDirectory(path)'' -- set ''path'' as the working directory <wrap info>since **v3.3.7**</wrap> | * ''setWorkingDirectory(path)'' -- set ''path'' as the working directory <wrap info>since **v3.3.7**</wrap> |
| * ''getWorkingDirectory()'' -- get the working directory <wrap info>since **v3.3.7**</wrap> | * ''getWorkingDirectory()'' -- get the working directory <wrap info>since **v3.3.7**</wrap> |
| | |
| | ==== Editor functions ==== |
| | |
| | * ''select(ref, ...)'' -- select the nodes passed as a list of references <wrap info>since **v3.5.1**</wrap> |
| |
| ==== File operations ==== | ==== File operations ==== |
| | |
| * ''load(fileName)'' -- load a model from the work file ''fileName'' (or import from external file and determine the model type by the extension) and return its work | * ''load(fileName)'' -- load a model from the work file ''fileName'' (or import from external file and determine the model type by the extension) and return its work |
| * ''import(fileName)'' -- import a model from the file ''fileName'' and return its work (the model type is determined by the ''fileName'' extension) <wrap important>deprecated since **v3.3.8** in favour of model-specific functions, as //import// is a reserved keyword in JavaScript ES6</wrap> | * ''import(fileName)'' -- import a model from the file ''fileName'' and return its work (the model type is determined by the ''fileName'' extension) <wrap important>deprecated since **v3.3.8** in favour of model-specific functions, as //import// is a reserved keyword in JavaScript ES6</wrap> |
| * ''importCircuitVerilog(vFileName)'' -- import a Circuit from the given //Verilog netlist (*.v)// file ''vFileName'' and return its work <wrap info>since **v3.3.8**</wrap> | * ''importCircuitVerilog(vFileName)'' -- import a Circuit from the given //Verilog netlist (*.v)// file ''vFileName'' and return its work <wrap info>since **v3.3.8**</wrap> |
| | * ''importCircuitVerilog(vFileName, topModuleName)'' -- import a Circuit ''topModuleName'' (can be skipped for auto detection) with its dependencies from the given //Verilog netlist (*.v)// file ''vFileName'' and return its work <wrap info>since **v3.3.9**</wrap> |
| * ''importFstSg(sgFileName)'' -- import an FST from the //State Graph (*.sg)// file ''sgFileName'' and return its work <wrap info>since **v3.3.8**</wrap> | * ''importFstSg(sgFileName)'' -- import an FST from the //State Graph (*.sg)// file ''sgFileName'' and return its work <wrap info>since **v3.3.8**</wrap> |
| * ''importStgG(gFileName)'' -- import an STG from the //Signal Transition Graph (*.g)// file ''gFileName'' and return its work <wrap info>since **v3.3.8**</wrap> | * ''importStgG(gFileName)'' -- import an STG from the //Signal Transition Graph (*.g)// file ''gFileName'' and return its work <wrap info>since **v3.3.8**</wrap> |
| |
| ==== Configuration ==== | ==== Configuration ==== |
| | |
| * ''setConfigVar(key, val)'' -- set the config variable ''key'' to value ''val'' | * ''setConfigVar(key, val)'' -- set the config variable ''key'' to value ''val'' |
| * ''getConfigVar(key)'' -- return the value of config variable ''key'' | * ''getConfigVar(key)'' -- return the value of config variable ''key'' |
| Config variables are saved in ''config.xml'' file (located under ''~/.config/workcraft/'' in Linux or ''~\AppData\Roaming\workcraft\'' in Windows). The variable name you pass to ''setConfigVar/getConfigVar'' functions can be derived from ''config.xml'' file and should include its dot-separated path in the XML tree. For example, ''%%setConfigVar("CircuitSettings.clearPin", "RN");%%'' sets the variable ''clearPin'' under ''CircuitSettings'' group to a string ''%%RN%%''. | Config variables are saved in ''config.xml'' file (located under ''~/.config/workcraft/'' in Linux or ''~\AppData\Roaming\workcraft\'' in Windows). The variable name you pass to ''setConfigVar/getConfigVar'' functions can be derived from ''config.xml'' file and should include its dot-separated path in the XML tree. For example, ''%%setConfigVar("CircuitSettings.clearPin", "RN");%%'' sets the variable ''clearPin'' under ''CircuitSettings'' group to a string ''%%RN%%''. |
| </WRAP> | </WRAP> |
| | |
| ==== Command execution ==== | ==== Command execution ==== |
| | |
| * ''execFile(fileName)'' -- execute JavaScript file ''fileName'' | * ''execFile(fileName)'' -- execute JavaScript file ''fileName'' |
| * ''runCommand(work, className)'' -- apply the command ''className'' to the model ''work'' as a background task | * ''runCommand(work, className)'' -- apply the command ''className'' to the model ''work'' as a background task |
| * ''statStg(work)'' -- advanced complexity estimates for the STG ''work'' | * ''statStg(work)'' -- advanced complexity estimates for the STG ''work'' |
| * ''statCircuit(work)'' -- advanced complexity estimates for the Circuit ''work'' | * ''statCircuit(work)'' -- advanced complexity estimates for the Circuit ''work'' |
| | * ''statCircuitRefinement(work)'' -- refinement dependencies for the Circuit ''work'' <wrap info>since **v3.3.8**</wrap> |
| |
| ==== Synthesis commands ==== | ==== Synthesis commands ==== |
| |
| * Logic synthesis of Circuits from STGs using Petrify backend | * Logic synthesis of Circuits from STGs using Petrify backend |
| * ''resolveCscConflictPetrify(work)'' -- resolve complete state coding conflicts in the STG 'work' using Petrify | * ''resolveCscConflictPetrify(work)'' -- resolve complete state coding conflicts in the STG ''work'' using Petrify |
| * ''synthComplexGatePetrify(work)'' -- logic synthesis of the STG ''work'' into a complex gate Circuit work using Petrify | * ''synthComplexGatePetrify(work)'' -- logic synthesis of the STG ''work'' into a complex gate Circuit work using Petrify |
| * ''synthGeneralisedCelementPetrify(work)'' -- synthesis of the STG ''work'' into a generalised C-element Circuit using Petrify | * ''synthGeneralisedCelementPetrify(work)'' -- synthesis of the STG ''work'' into a generalised C-element Circuit using Petrify |
| |
| * Logic synthesis of Circuits from STGs using MPSat backend | * Logic synthesis of Circuits from STGs using MPSat backend |
| * ''resolveCscConflictMpsat(work)'' -- resolve complete state coding conflicts in the STG 'work' using MPSat | * ''resolveCscConflictMpsat(work)'' -- resolve complete state coding conflicts in the STG ''work'' using MPSat |
| * ''synthComplexGateMpsat(work)'' -- logic synthesis of the STG ''work'' into a complex gate Circuit work using MPSat | * ''synthComplexGateMpsat(work)'' -- logic synthesis of the STG ''work'' into a complex gate Circuit work using MPSat |
| * ''synthGeneralisedCelementMpsat(work)'' -- synthesis of the STG ''work'' into a generalised C-element Circuit work using MPSat | * ''synthGeneralisedCelementMpsat(work)'' -- synthesis of the STG ''work'' into a generalised C-element Circuit work using MPSat |
| * Commands specific for Circuit models | * Commands specific for Circuit models |
| * ''checkCircuitBinateImplementation(work)'' -- check the Circuit ''work'' for correct implementation of its binate functions <wrap info>since **v3.2.5**</wrap> | * ''checkCircuitBinateImplementation(work)'' -- check the Circuit ''work'' for correct implementation of its binate functions <wrap info>since **v3.2.5**</wrap> |
| * ''checkCircuitCombined(work)'' -- combined check of the Circuit ''work'' for conformation to environment, deadlock freeness, and output persistency | * ''checkCircuitCombined(work)'' -- combined check of the Circuit ''work'' for all essential properties (conformation to environment, output persistency, deadlock freeness) |
| * ''checkCircuitConformation(work)'' -- check the Circuit ''work'' for conformation to environment | * ''checkCircuitConformation(work)'' -- check the Circuit ''work'' for conformation to environment |
| * ''checkCircuitCycles(work)'' -- check if the Circuit ''work'' is free from cyclic paths | * ''checkCircuitCycles(work)'' -- check if the Circuit ''work'' is free from cyclic paths |
| |
| * Commands specific for STG models | * Commands specific for STG models |
| * ''checkStgCombined(work)'' -- combined check of the STG ''work'' for consistency, deadlock freeness, input properness, output persistency, and mutex implementability | * ''checkStgCombined(work)'' -- combined check of the STG ''work'' for all essential properties (consistency, output determinacy, input properness, mutex protocol, output persistency, absence of local self-triggering, deadlock freeness, delay insensitive interface) |
| * ''checkStgConformation(work, data)'' -- check the STG ''work'' for conformation to the STG specified by file name ''data'' <wrap info>since **v3.3.0**</wrap> | * ''checkStgConformation(work, data)'' -- check the STG ''work'' for conformation to the STG specified by file name ''data'' <wrap info>since **v3.3.0**</wrap> |
| * ''checkStgConsistency(work)'' -- check the STG ''work'' for consistency | * ''checkStgConsistency(work)'' -- check the STG ''work'' for consistency |
| * ''checkStgCsc(work)'' -- check the STG ''work'' for CSC | * ''checkStgCsc(work)'' -- check the STG ''work'' for CSC |
| * ''checkStgDeadlockFreeness(work)'' -- check the STG (or Petri net) ''work'' for deadlock freeness | * ''checkStgDeadlockFreeness(work)'' -- check the STG (or Petri net) ''work'' for deadlock freeness |
| * ''checkStgDiInterface(work)'' -- check the STG ''work'' for DI interface | * ''checkStgDiInterface(work)'' -- check the STG ''work'' for delay insensitive interface |
| * ''checkStgHandshakeProtocol(work, data)'' -- check the STG ''work'' for following a handshake protocol as specified by ''data'', e.g. ''{req1 req2} {ack12}'' <wrap info>since **v3.3.0**</wrap> | * ''checkStgHandshakeProtocol(work, data)'' -- check the STG ''work'' for following a handshake protocol as specified by ''data'', e.g. ''{req1 req2} {ack12}'' <wrap info>since **v3.3.0**</wrap> |
| * ''checkStgInputProperness(work)'' -- check the STG ''work'' for input properness | * ''checkStgInputProperness(work)'' -- check the STG ''work'' for input properness |
| | * ''checkStgLocalSelfTriggering(work)'' -- check the STG ''work'' for absence of local self-triggering |
| * ''checkStgMutexImplementability(work)'' -- check the STG ''work'' for implementability of its mutex places | * ''checkStgMutexImplementability(work)'' -- check the STG ''work'' for implementability of its mutex places |
| * ''checkStgNormalcy(work)'' -- check the STG ''work'' for normalcy | * ''checkStgNormalcy(work)'' -- check the STG ''work'' for normalcy |
| * ''checkStgOutputDeterminacy(work)'' -- check the STG ''work'' for output determinacy | * ''checkStgOutputDeterminacy(work)'' -- check the STG ''work'' for output determinacy |
| * ''checkStgOutputPersistency(work)'' -- check the STG ''work'' for output persistency | * ''checkStgOutputPersistency(work)'' -- check the STG ''work'' for output persistency |
| * ''checkStgPlaceRedundancy(work, data)'' -- check the STG (or Petri net) 'work' for redundancy of places in space-separated list ''data'' <wrap info>since **v3.3.0**</wrap> | * ''checkStgPlaceRedundancy(work, data)'' -- check the STG (or Petri net) ''work'' for redundancy of places in space-separated list ''data'' <wrap info>since **v3.3.0**</wrap> |
| * ''checkStgReachAssertion(work, data)'' -- check the STG ''work'' for REACH assertion ''data'' <wrap info>since **v3.3.0**</wrap> | * ''checkStgReachAssertion(work, data)'' -- check the STG ''work'' for REACH assertion ''data'' <wrap info>since **v3.3.0**</wrap> |
| * ''checkStgSignalAssertion(work, data)'' -- check the STG ''work'' for signal assertion ''data'' <wrap info>since **v3.3.0**</wrap> | * ''checkStgSignalAssertion(work, data)'' -- check the STG ''work'' for signal assertion ''data'' <wrap info>since **v3.3.0**</wrap> |
| |
| * Generic commands applicable to all models | * Generic commands applicable to all models |
| | * ''transformModelAnonymise(work)'' -- anonymise the model ''work'' by randomly renaming its nodes |
| * ''transformModelCopyLabel(work)'' -- transform the model ''work'' by copying unique names of the selected (or all) nodes into their labels | * ''transformModelCopyLabel(work)'' -- transform the model ''work'' by copying unique names of the selected (or all) nodes into their labels |
| * ''transformModelStraightenConnection(work)'' -- transform the model ''work'' by straightening selected (or all) arcs | * ''transformModelStraightenConnection(work)'' -- transform the model ''work'' by straightening selected (or all) arcs |
| * ''transformCircuitContractComponent(work)'' -- transform the Circuit ''work'' by contracting selected single-input/single-output components | * ''transformCircuitContractComponent(work)'' -- transform the Circuit ''work'' by contracting selected single-input/single-output components |
| * ''transformCircuitContractJoint(work)'' -- transform the Circuit ''work'' by contracting selected (or all) joints | * ''transformCircuitContractJoint(work)'' -- transform the Circuit ''work'' by contracting selected (or all) joints |
| * ''transformCircuitDetachJoint(work)'' -- transform the Circuit ''work'' by detaching selected (or all joints) | * ''transformCircuitDetachJoint(work)'' -- transform the Circuit ''work'' by detaching selected (or all) joints |
| * ''transformCircuitDissolveJoint(work)'' -- transform the Circuit ''work'' by dissolving selected (or all) joints | * ''transformCircuitDissolveJoint(work)'' -- transform the Circuit ''work'' by dissolving selected (or all) joints |
| * ''transformCircuitInsertBuffer(work)'' -- transform the Circuit ''work'' by inserting buffers into selected wires | * ''transformCircuitInsertBuffer(work)'' -- transform the Circuit ''work'' by inserting buffers into selected wires |
| * ''transformCircuitToggleZeroDelay(work)'' -- transform the Circuit ''work'' by toggling zero delay of selected inverters and buffers | * ''transformCircuitToggleZeroDelay(work)'' -- transform the Circuit ''work'' by toggling zero delay of selected inverters and buffers |
| * ''transformCircuitOptimiseZeroDelay(work)'' -- transform the Circuit ''work'' by discarding redundant zero delay attribute for selected (or all) inverters and buffers <wrap info>since **v3.2.5**</wrap> | * ''transformCircuitOptimiseZeroDelay(work)'' -- transform the Circuit ''work'' by discarding redundant zero delay attribute for selected (or all) inverters and buffers <wrap info>since **v3.2.5**</wrap> |
| | * ''transformCircuitMutexProtocolEarly(work)'' -- transform the Circuit ''work'' by setting early protocol for selected (or all) mutex components <wrap info>since **v3.5.1**</wrap> |
| | * ''transformCircuitMutexProtocolLate(work)'' -- transform the Circuit ''work'' by setting late protocol for selected (or all) mutex components <wrap info>since **v3.5.1**</wrap> |
| |
| * Commands specific for reset insertion in Circuit models <wrap info>since **v3.2.2**, change in **v3.2.3**</wrap> | * Commands specific for reset insertion in Circuit models <wrap info>since **v3.2.2**, change in **v3.2.3**</wrap> |
| * ''insertCircuitResetActiveHigh(work)'' -- insert active-high reset into the Circuit ''work'' | * ''insertCircuitResetActiveHigh(work)'' -- insert active-high reset into the Circuit ''work'' |
| * ''insertCircuitResetActiveLow(work)'' -- insert active-low reset into the Circuit ''work'' | * ''insertCircuitResetActiveLow(work)'' -- insert active-low reset into the Circuit ''work'' |
| * ''tagCircuitForceInitAutoAppend(work)'' -- append force init pins as necessary to complete initialisation of the Circuit ''work'' | * ''tagCircuitForcedInitAutoAppend(work)'' -- append force init pins as necessary to complete initialisation of the Circuit ''work''\\ <wrap important>//tagCircuitForceInitAutoAppend(work)// before **v3.4.0** -- deprecated</wrap> |
| * ''tagCircuitForceInitAutoDiscard(work)'' -- discard force init pins that are redundant for initialisation of the Circuit ''work'' | * ''tagCircuitForcedInitAutoDiscard(work)'' -- discard force init pins that are redundant for initialisation of the Circuit ''work''\\ <wrap important>//tagCircuitForceInitAutoDiscard(work)// before **v3.4.0** -- deprecated</wrap> |
| * ''tagCircuitForceInitClearAll(work)'' -- clear all force init input ports and output pins in the Circuit ''work'' | * ''tagCircuitForcedInitClearAll(work)'' -- clear all force init input ports and output pins in the Circuit ''work''\\ <wrap important>//tagCircuitForceInitClearAll(work)// before **v3.4.0** -- deprecated</wrap> |
| * ''tagCircuitForceInitInputPorts(work)'' -- force init all input ports in the Circuit ''work'' (environment must initialise them) | * ''tagCircuitForcedInitInputPorts(work)'' -- force init all input ports in the Circuit ''work'' (environment must initialise them)\\ <wrap important>//tagCircuitForceInitInputPorts(work)// before **v3.4.0** -- deprecated</wrap> |
| * ''tagCircuitForceInitProblematicPins(work)'' -- force init output pins with problematic initial state in the Circuit ''work'' | * ''tagCircuitForcedInitProblematicPins(work)'' -- force init output pins with problematic initial state in the Circuit ''work''\\ <wrap important>//tagCircuitForceInitProblematicPins(work)// before **v3.4.0** -- deprecated</wrap> |
| * ''tagCircuitForceInitSequentialPins(work)'' - force init output pins of sequential gates in the Circuit ''work'' | * ''tagCircuitForcedInitSequentialPins(work)'' - force init output pins of sequential gates in the Circuit ''work''\\ <wrap important>//tagCircuitForceInitSequentialPins(work)// before **v3.4.0** -- deprecated</wrap> |
| | * ''setCircuitDriverInitToOne(work, ref, value)'' -- set ''value'' as //Init to one// attribute for driver ''ref'' (input port or output pin) in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''getCircuitDriverInitToOne(work, ref)'' -- get //Init to one// attribute for driver ''ref'' (input port or output pin) in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''setCircuitDriverForcedInit(work, ref, value)'' -- set ''value'' as //Forced init// attribute for driver ''ref'' (input port or output pin) in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''getCircuitDriverForcedInit(work, ref)'' -- get //Forced init// attribute for driver ''ref'' (input port or output pin) in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''constrainCircuitInputPortRiseOnly(work, ref)'' -- constrain input port ''ref'' in Circuit ''work'' as rise only <wrap info>since **v3.4.0**</wrap> |
| | * ''constrainCircuitInputPortFallOnly(work, ref)'' -- constrain input port ''ref'' in Circuit ''work'' as fall only <wrap info>since **v3.4.0**</wrap> |
| | * ''constrainCircuitInputPortAny(work, ref)'' -- clear constrains from input port ''ref'' in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''getCircuitDriverSetFunction(work, ref)'' -- get //Set function// of driver ''ref'' in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''getCircuitDriverResetFunction(work, ref)'' -- get //Reset function// of driver ''ref'' in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| |
| * Commands specific for loop breaking and scan insertion in Circuit models <wrap info>since **v3.2.3**</wrap> | * Commands specific for loop breaking and scan insertion in Circuit models <wrap info>since **v3.2.3**</wrap> |
| * ''tagCircuitPathBreakerClearAll(work)'' -- clear all path breaker pins in the Circuit ''work'' | * ''tagCircuitPathBreakerClearAll(work)'' -- clear all path breaker pins in the Circuit ''work'' |
| * ''tagCircuitPathBreakerSelfloopPins(work)'' -- path breaker output pins within self-loops in the Circuit ''work'' | * ''tagCircuitPathBreakerSelfloopPins(work)'' -- path breaker output pins within self-loops in the Circuit ''work'' |
| | * ''setCircuitPinPathBreaker(work, ref, value)'' -- set ''value'' as //Path breaker// attribute for pin ''ref'' in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| | * ''getCircuitPinPathBreaker(work, ref)'' -- get //Path breaker// attribute for pin ''ref'' in Circuit ''work'' <wrap info>since **v3.4.0**</wrap> |
| |
| * Commands specific for DFS models | * Commands specific for DFS models |
| * ''transformDfsContractComponent(work)'' -- transform the DFS ''work'' by contracting selected components | * ''transformDfsContractComponent(work)'' -- transform the DFS ''work'' by contracting selected components |
| * ''transformDfsMergeComponent(work)'' -- transform the DFS ''work'' by merging selected components | * ''transformDfsMergeComponent(work)'' -- transform the DFS ''work'' by merging selected components |
| * ''transformDfsWagging2Way(work)'' -- transform the DFS ''work'' by by applying 2-way wagging to the selected pipeline section | * ''transformDfsSplitComponent(work)'' -- transform the DFS ''work'' by splitting selected components <wrap info>since **v3.5.2**</wrap> |
| * ''transformDfsWagging3Way(work)'' -- transform the DFS ''work'' by by applying 3-way wagging to the selected pipeline section | * ''transformDfsWagging2Way(work)'' -- transform the DFS ''work'' by applying 2-way wagging to the selected pipeline section |
| * ''transformDfsWagging4Way(work)'' -- transform the DFS ''work'' by by applying 4-way wagging to the selected pipeline section | * ''transformDfsWagging3Way(work)'' -- transform the DFS ''work'' by applying 3-way wagging to the selected pipeline section |
| | * ''transformDfsWagging4Way(work)'' -- transform the DFS ''work'' by applying 4-way wagging to the selected pipeline section |
| | |
| | * Commands specific for FSM and FST models |
| | * ''transformFsmContractState(work)'' -- transform the FSM/FST ''work'' by contracting selected states |
| | * ''transformFsmSplitState(work)'' -- transform the FSM/FST ''work'' by splitting selected states <wrap info>since **v3.5.2**</wrap> |
| | * transformFsmMergeState''(work)'' -- transform the FSM/FST ''work'' by merging selected states |
| |
| * Commands specific for Petri net and (if explicitly stated) for derived models | * Commands specific for Petri net and (if explicitly stated) for derived models |
| * ''transformStgSelectAllSignalTransitions(work)'' -- select all transitions of selected signals in the STG ''work'' | * ''transformStgSelectAllSignalTransitions(work)'' -- select all transitions of selected signals in the STG ''work'' |
| * ''transformStgSignalToDummyTransition(work)'' -- transform the STG ''work'' by converting selected signal transitions to dummies | * ''transformStgSignalToDummyTransition(work)'' -- transform the STG ''work'' by converting selected signal transitions to dummies |
| | * ''transformStgSplitTransition(work)'' -- transform the STG ''work'' by splitting selected transitions <wrap info>since **v3.5.2**</wrap> |
| |
| * Commands specific for WTG models | * Commands specific for WTG models |
| // Mirror signals and untoggle transitions of STG model | // Mirror signals and untoggle transitions of STG model |
| inStgWork = load("in.stg.work"); | inStgWork = load("in.stg.work"); |
| transformStgMirrorSignal(inStg); | transformStgMirrorSignal(inStgWork); |
| outStgWork = convertStgUntoggle(inStg); | outStgWork = convertStgUntoggle(inStgWork); |
| save(outStgWork, "out.stg.work"); | save(outStgWork, "out.stg.work"); |
| exit(); | exit(); |
| exit(); | exit(); |
| } | } |
| tagCircuitForceInitClearAll(work); | tagCircuitForcedInitClearAll(work); |
| tagCircuitForceInitInputPorts(work); | tagCircuitForcedInitInputPorts(work); |
| tagCircuitForceInitAutoAppend(work); | tagCircuitForcedInitAutoAppend(work); |
| insertCircuitResetActiveLow(work); | insertCircuitResetActiveLow(work); |
| if (checkCircuitReset(work) != true) { | if (checkCircuitReset(work) != true) { |