Specify attributes of signal
This object enables you to create workspace objects that you can use to assign or validate the attributes of a signal or discrete state, such as its data type, numeric type, dimensions, and so on.
You can use a signal object to:
Assign values to signal attributes that are left unassigned (have a value
of -1
or auto
)
by the signal source.
Validate signal attributes whose values are explicitly assigned by the
signal source. Such attributes have values other than
-1
or auto
.
Successful validation guarantees that the signal has the attributes that you
intended it to have.
You can create a Simulink.Signal
object in the MATLAB® workspace or in a model workspace.
Use signal objects to assign or validate signal or discrete state attributes by giving
the signal or discrete state the same name as the workspace variable that references the
Simulink.Signal
object.
For more information about using signal objects, see Use Simulink.Signal Objects to Specify and Control Signal Attributes and Data Objects.
Create a Simulink.Signal
object:
By using the Model Data Editor. See For Signals.
By using the Model Explorer. See Create Data Objects from Built-In Data Class Package Simulink.
Directly from a signal properties dialog box or the Property Inspector in a model. See Create Signal Object from Signal Properties Dialog Box.
By using the Simulink.Signal
function, described
below.
signalObj = Simulink.Signal
returns a
Simulink.Signal
object with default property values.
Simulink.Signal
ExamplesFor examples that show how to use Simulink.Signal
objects, see
Use Simulink.Signal Objects to Specify and Control Signal Attributes and Data Objects.
Simulink.CoderInfo
| Simulink.Parameter
| AUTOSAR.Signal
(AUTOSAR Blockset)