Rockwell Automation 8520-GUM 9/Series CNC Grinder Operation and Programming Manual Documentation Set User Manual

Page 72

Advertising
background image

Chapter 2
Operating the Control

2-52

Paramacro Variables in CALC Operations
Any paramacro variable can be accessed through the CALC function.
Include a # sign followed by the paramacro variable number. When the
calculation is performed the value of that paramacro variable is substituted
into the equation. You can not change the value of paramacro variables
with the CALC function. Local parameters are only available for the
currently active nesting level of the control (main program, or one of four
nested macro programs). You can not perform calculations that contain
any paramacro variables if the control is currently executing a program
block. The control must be in either cycle stop state, or E-Stop.

Example 2.4

Calling Paramacro Variables with the CALC Function

Expression Entered

Result Displayed

#100

Display current value of variable #100

12/#100*3

Divide 12 by the current value of #100
and multiply by 3

SIN[#31*3]

Multiply the value of #31 (for the current
local parameter nesting level) by 3 and
take the sine of that result

END OF CHAPTER

Advertising