Bosch 6000 User's Guide Page 224

  • Download
  • Add to my manuals
  • Print
  • Page
    / 268
  • Table of contents
  • TROUBLESHOOTING
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 223
Chapter 6. Following
209
Transfer and
Assignment/
Comparison of Master
Cycle Position and
Number
The current master cycle position and the current master cycle number may be displayed with
the TPMAS and TNMCY commands, respectively. These values may also be read into numeric
variables (VAR) at any time using the PMAS and NMCY commands (e.g., VAR6=NMCY).
Very often, the master cycle number will be directly related to the quantity of product produced
in a manufacturing run, and the master cycle position can be used to determine what portion of
a current cycle is complete.
Position Sampling Period
Steppers – 2 millisec.
Servos –
system update
period
(depends on SSFR
& INDAX command values
– see SSFR command).
The master cycle number is sampled once per position sampling period (see note, left). If the
master cycle length (FMCLEN) divided by the master's velocity (VMAS) is less than the
position sampling period, then the sample (TNMCY or NMCY value) may not be accurate.
Details on using PMAS in conditional expressions is provided below in Using Conditional
Statements with
PMAS
.
Using Conditional
Statements with
Master Cycle Position
(PMAS)
The current master cycle position (PMAS) value may be used in comparison expressions, just
like other position variables such as PC, PM, PE, and FB. PMAS is a special case, however,
because its value rolls over to zero when the master cycle length (FMCLEN) is met or
exceeded. This means that PMAS values greater than or equal to the master cycle length will
never be reported with the TPMAS command, or with expressions such as (VAR1=1PMAS).
The other fact that makes PMAS special is that master cycle counting may be restarted after the
command containing the PMAS expression has been executed. Either the FMCNEW command or
the TRGFNcx1 command may be used to restart counting, each with a different effect on the
evaluation of PMAS.
The treatment of PMAS in comparison expressions depends on the command using the
expression, as described below. WAIT and GOWHEN are treated as special cases.
IF, UNTIL, and
WHILE
These commands evaluate the current value of PMAS in the same way that TPMAS does (i.e.,
PMAS values will never be greater than or equal to the master cycle length). With these
commands, avoid comparing PMAS to be greater than or equal to variables or constants which
are nearly equal to the master cycle length, because rollover may occur before a PMAS sample
is read which makes the comparison true. If such a comparison is necessary, it should be
combined (using OR) with a comparison for master cycle number (NMCY) being greater than
the current master cycle number.
Also, master cycle counting restart may be pending activation of a trigger, but this will not
affect the evaluation of PMAS for IF, WAIT, and WHILE. It is simply evaluated based on
counting currently underway.
WAIT and GOWHEN
These commands evaluate the current value of PMAS differently than TPMAS does, in such a
way that it is possible to compare PMAS to variables or constants which are greater than or
equal to the master cycle length and still have the comparison be reliably detected.
Effectively, PMAS is evaluated as if the master cycle length were suddenly set to its maximum
value (2
32
) at the time the WAIT or GOWHEN command is encountered. It eliminates the need to
OR the PMAS comparison with a comparison for master cycle number (NMCY) being greater than
the current master cycle number. Such multiple expressions are not allowed in the GOWHEN
command, so this alternative evaluation of PMAS offers the required flexibility.
This method of evaluation of PMAS allows commands which sequence slave events through a
master cycle to be placed in a loop. The WAIT or GOWHEN command at the top of the loop
can execute, even though the actual master travel has not finished the previous cycle. If it is
desired to WAIT or GOWHEN for a master cycle position of the next master cycle, the variable
or constant specified in the command should be calculated by adding one master cycle length to
the desired master cycle position.
Finally, master cycle counting restart may be pending activation of a trigger (TRGFNcx1),
and this will suspend the evaluation of PMAS for these commands. PMAS is not sampled, and
the comparison evaluates as false. During this time, if the pending status of master cycle
counting restart is aborted with FMCNEWØ, the GOWHEN condition is also cleared, and any
motion profile of any axis waiting on that PMAS comparison will be canceled. Otherwise,
when master cycle counting is restarted by a trigger, evaluation takes place as described above.
This allows GOWHEN to include waiting on a trigger without explicitly including it in the
GOWHEN expression.
Page view 223
1 2 ... 219 220 221 222 223 224 225 226 227 228 229 ... 267 268

Comments to this Manuals

No comments