Toggle

In this block, at each activation the output is toggled between quot;Firstquot; and quot;Secondquot; values. This action is useful for generating non periodic square wave signals.

    Toggle

Library

SignalGenerators

Description

In the Toggle block, at each activation the output is toggled between the first and the second values. This action is useful for generating non periodic square wave signals. This block is also useful to generate synchronous square waves with SampleClock activation.

Parameters

Toggle_0

NameLabelDescriptionData TypeValid Values

firstvalue

First value

First value to toggle the signal. Default: 1.

Matrix

secondvalue

Second value

Second value to toggle the signal. Default: -1.

Matrix

ot

Output/Parameters datatype

Datatype of the output. Default: 'double'.

String

'double'
'complex'
'int32'
'int16'
'int8'
'uint32'
'uint16'
'uint8'

Ports

NameTypeDescriptionIO TypeNumber

Port 1

explicit

output

1

Port 2

activation

input

1

Advanced Properties

NameValueDescription

always active

no

Time Dependency = standard mode activated

direct-feedthrough

no

zero-crossing

no

mode

no

continuous-time state

no

discrete-time state

yes