Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »


Like all other operators, Variable operators have various attributes that may be specified in their Operator Properties dialog. In addition to these properties, Variable operators have several other settings that are inherited from the common signal that they reference. Recall that several Variable operators may reference the same signal---attributes of this common signal apply to all Variable operators that reference it. Why are there attributes associated with the common signal (i.e., with the set of Variable operators) rather than with an individual operator? Asked another way, why aren't all attributes simply set from each Variable operator's property sheet?

 
Consider a schema with a state-transition diagram containing three states. Suppose that each state's associated sub-schema document had an output-only, module-scope Variable operator that referenced the same parameter signal, call it fParam_m. By definition, the output of each Variable operator must be the same, namely the value of the fParam_m signal. But how is the value of fParam_m assigned if the Variable operators that reference the signal are all output-only and not computed within the schema? The answer is that the value of fParam_m will remain constant at its initial value. This initial value setting is a property that must be common to all variable operators that reference the signal. Specifying the initial value in the property sheet of each individual operator would be error prone, as different values could be set for the same signal.

 

Figure 5.6. Variable Settings Dialog.

The common Variable operator attributes are specified in the Variable Settings dialog (see Figure 5.6). Access to the dialog depends on the scope of the Variable operator. Variables of Local scope pertain to the single schema document in which they exist. As such, their common properties are stored within the schema document and the Variable Settings dialog is accessed from the Schema menu (select the Local Variable Settings item). Variables of Module and Global scope pertain to multiple schema documents linked to a common hardware interface configuration. As a result, their common properties are stored within the hardware interface file and the Variable Settings dialog is accessed from the module drop-down menu in the hardware interface file view. For Variable operators with Module scope, select the Module Variable Settings item from the drop-down menu; for Variable operators with Global scope, select the Global Variable Settings item.

 
Consider a schema having a Variable operator with module scope that references a signal named fSignal_m. Suppose the schema were linked to two modules in a hardware interface file, say "Module A" and "Module B". Since the Variable operator is of module scope, it represents a distinct signal within each module. That is, fSignal_m in "Module A" is not the same variable as fSignal_m in "Module B". As such, they can be assigned different initial values (among other attributes) in the Module Variable Settings dialog for each module.

  • No labels