WOLFRAM SYSTEM MODELER

AssignClockToSquareWaveHold

Generate a Boolean continuous-time square-wave output from a clocked Real input

Wolfram Language

In[1]:=
SystemModel["Modelica_Synchronous.RealSignals.Sampler.Utilities.AssignClockToSquareWaveHold"]
Out[1]:=

Information

This block creates a Boolean, continuous time, square-wave output. Whenever the clock of the input signal is active the Boolean output value changes.

Example

The following example samples a sine signal with a periodic clock of 20 ms period. After that a Boolean, continuous time, square-wave signal is generated that changes its value at every clock tick of the sampled signal:

   
model simulation result

Parameters (1)

y_start

Value: false

Type: Boolean

Description: Initial value of output signal

Connectors (2)

u

Type: RealInput

Description: 'input Real' as connector

y

Type: BooleanOutput

Description: Connector of Boolean output signal

Used in Examples (2)

AssignClockToSquareWaveHold

Modelica_Synchronous.Examples.Elementary.RealSignals

Example of an AssignClockToSquareWaveHold block for Real signals

TestClockedRealToSquare

Modelica_Synchronous.WorkInProgress.Tests