Function Block CTRL_PWM

The Function Block CTRL_PWM generates a Pulse Width Modulation.

Input IN

The control variable is specified via the input. The value must be between 0 and 255. 255 corresponds to 100 %.

Input PT

This input defines the cycle time for a pulse width. This corresponds to one on and one off switch. The input must be specified for correct function. The data type Time is expected, such as T#5m.

Input PT_MIN

The input defines the minimum cycle time of a pulse width. If this is exceeded, the second cycle will be proportionally extended. It is recommended to limit the maximum cycle with PT_MAX.

Input PT_MAX

The input defines the maximum total cycle time when expanding. This should correspond at least to the input PT. For this input to be calculated, PT_MAX must be defined and PT_MIN must extend the pulse width.

Input DIS

The input DIS disables the Pulse Width Modulation and the output Q is false.

Output Q

The output of type bool switches cyclically between true and false. Depending on the pulse width signal. The first cycle starts with true.