Main Content

latch

Save value of an expression

Syntax

Description

example

latch(x) saves the value of x when the test step is entered and returns that value of x. The latch(x) statement reevaluates the next time the step is entered. Use the latch operator in the test step of a Test Sequence or Test Assessment block.

Examples

expand all

Save the value of the torque in the variable latch_val.

latch_val = latch(torque)

Version History

Introduced in R2015a