DSP Blockset
  Go to block:
    Search    Help Desk 
Sample and Hold    See Also

Sample and hold an input signal.

Library

Switches and Counters, in General DSP

Description

The Sample and Hold block acquires a new sample (scalar, vector, or matrix) from the signal input whenever it is triggered by the control signal at the trigger input (). The block holds the output at the sampled input value until the next triggering event occurs.

The triggering event at the top port is specified by the Trigger type pop-up menu, and can be one of the following:

The block's output prior to the first triggering event is specified by the Initial condition parameter. If the input is a vector, the Initial condition can be a vector of the same size, or a scalar value to be repeated across all elements of the output. If the block's input is an M-by-N matrix, the Initial condition can be a scalar to be repeated across all M*N elements of the output matrix, or a vector, ic, of length M*N, to be reshaped to matrix dimensions.

Dialog Box

Trigger type
The type of event that triggers the block's to sample the input signal.
Initial condition
The block output prior to the first triggering event.

See Also

Downsample
N-Sample Switch


[ Previous | Help Desk | Next ]