Skip to Main Content Skip to Search
Product Documentation

setSignal - Assign signal to signal name

Syntax

OBJ = setSignal(OBJ, SIGNALNAME, SIGNALOBJ)
OBJ.SIGNALNAME = SIGNALOBJ

Description

OBJ = setSignal(OBJ, SIGNALNAME, SIGNALOBJ) maps the SIGNALOBJ to SIGNALNAME and returns the object TestCase OBJ.

OBJ.SIGNALNAME = SIGNALOBJ is an alternative syntax.

Examples

Assign a signal using setSignal().

 testCase = systest.TestCase('Test Case 1')
 signal = systest.signals.Signal('Constant')
 testCase = setSignal(testCase, 'In1', signal)

Assign a signal using "dot" field assignment.

 testCase = systest.TestCase('Test Case 1')
 signal = systest.signals.Signal('Constant')
 testCase.In1 = signal

How To

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS