12.
As soon as
JOB_DONE
returns TRUE, you can transfer additional pulse train jobs
by repeating the steps 1 to 6.
13.
By resetting of
SW_EN
(
SW_EN
= FALSE) the output is immediately stopped.
14.
With reading jobs, you can find the values to be read in the parameter
JOB_OVAL
in the instance DB at address 20.
As long as only one pulse train job is defined and currently being processed, there is the
possibility to attach a 2. pulse train job to the 1. pulse train job.
1.
Call the SFB 49:
n
SW_EN
= TRUE (edge 0-1)
n
JOB_VAL
= Enter a value for the
number of pulses
here.
n
JOB_ID
= 09h: Write
number of pulses
for the 2. pulse train job.
n
JOB_REQ
= TRUE (edge 0-1)
ð
n
From
JOB_VAL
the
number of pulses
for the 2. pulse train job is trans-
mitted.
n
JOB_DONE
is FALSE during the SFB run.
n
On error
JOB_ERR
= TRUE and the cause of the error is returned in
JOB_STAT
2.
To reset JOB_REQ, call SFB 49 again with the same parameters and JOB_REQ =
FALSE.
3.
Call the SFB 49:
n
SW_EN
= TRUE
n
JOB_VAL
= Enter a value for the
period duration
here.
n
JOB_ID
= 0Ah: Write
period duration
for the 2. pulse train job.
n
JOB_REQ
= TRUE (edge 0-1)
ð
n
From
JOB_VAL
the
period duration
for the 2. pulse train job is transferred.
n
JOB_DONE
is FALSE during the SFB run.
n
On error
JOB_ERR
= TRUE and the cause of the error is returned in
JOB_STAT
4.
To reset JOB_REQ, call SFB 49 again with the same parameters and JOB_REQ =
FALSE.
5.
Call the SFB 49:
n
SW_EN
= TRUE (edge 0-1)
n
JOB_ID
= 0Ch: Attach 2. pulse train job to the 1. pulse train job.
n
JOB_REQ
= TRUE (edge 0-1)
n
OUTP_VAL
: Enter the duty factor such as 50%.
ð
n
As long as the 1. pulse train job is still running, the 2. pulse train job is
attached. Otherwise you receive the error message 0461h as
return value
.
n
Via
STS_EN
you get the current status of the pulse train output. As long as
the required number of pulses is output,
STS_EN
returns TRUE.
STS_EN
returns FALSE if either the requested number of pulses has been output or
output with
SW_EN
= FALSE was terminated early.
n
On error
JOB_ERR
= TRUE and the cause of the error is returned in
JOB_STAT
Please note that a maximum of 2 pulse train jobs can be exe-
cuted directly after another!
Extend a running pulse
train job
VIPA System 300S
+
Deployment I/O periphery
Pulse width modulation - PWM > SFB 49 - PULSE - Pulse width modulation
HB140 | CPU-SC | 313-5BF23 | en | 19-01
144