blockSampleClocked

Sample the continuous-time, Real input signal and provide it as clocked output signal. The clock is provided as input signal

Extends from Modelica_Synchronous.RealSignals.Interfaces.SamplerIcon (Basic graphical layout of block used for sampling of Real signals).

Information

This block is similar to the Sample block. The only difference is that a clock signal is provided via a second input and the output is associated to this clock.

Note, it does not make much sense to vectorize this block, because then also the clock input is vectorized. Instead, if the input signal is a vector, use block SampleVectorizedAndClocked that has a vector Real input and output, as well as a scalar clock input.

Example

The following example samples a sine signal with a periodic clock of 20 ms period:

   
model simulation result

Connectors

TypeNameDefaultDescription
Modelica.Blocks.Interfaces.RealInputuConnector of continuous-time, Real input signal
Modelica.Blocks.Interfaces.RealOutputyConnector of clocked, Real output signal
Modelica_Synchronous.ClockSignals.Interfaces.ClockInputclockOutput signal y is associated with this clock input