Siemens 6ED1050-1AA00-0BE8 Manuale Utente

Pagina di 372
 
LOGO! functions 
 
4.4 Special functions list - SF 
LOGO! 
Manual, 04/2011, A5E03556174-01 
263
 
Examples with Timing Diagrams 
The following examples show how the PWM instruction modulates a digital output signal 
from the analog input value: 
Example 1 
Analog input value: 500 (range 0 ...1000) 
Periodic time T: 4 seconds 
The digital output of the PWM function is 2 seconds high, 2 seconds low, 2 seconds high, 2 
seconds low and continues in that pattern as long as parameter "En" = high. 
(Q
0D[
$[
0LQ
4
VHF
VHF
VHF
VHF
VHF
VHF
VHF
 
 
Example 2 
Analog input value: 300 (range 0 ...1000) 
Periodic time T: 10 seconds 
The digital output of the PWM function is 3 seconds high, 7 seconds low, 3 seconds high, 7 
seconds low and continues in that pattern as long as parameter "En" = high. 
(Q
0D[
$[
0LQ
4
VHF
VHF
VHF
VHF
 
Calculation rule 
Q = 1, for (Ax - Min)/ (Max - Min) of time period T, when Min < Ax < Max 
Q = 0, for PT - [ (Ax - Min) / (Max - Min) ] of periodic time T. 
Note: Ax in this calculation refers to the actual value Ax as calculated using the Gain and 
Offset.