Just type your expressions on the left. In this case, we have a pretty simple set:

Fanuc Programming Manual Pdf

#100 = 10
#101 = #100 * 2
#102 = [[#101 / 3] + 6]

Fanuc 15m Operator Manual Pdf

Now, put the debugger in Single Block by selecting the button just left of the Tortoise.
As you step through a block at a time, the variables values are show in the box right below the backplot:

Macro variable values are shown below the backplot…

This little window shows all the modal activity, for example, we’re in G00 – Rapids mode. The values of Macro Variables are also modes of sorts, so they’re shown too. You get to see values for the last n variables whose value changed, and they’re sorted by variable #. Note how it also gives you a little hint about what the variable does. For example, it says #100, #101, and #102 are “Volatile Common Variables”. “Volatile” means their values are not remembered when the controller is switched off, and as we saw from the table up near the top of this page, variables in this range are Common Variables. G-Wizard doesn’t have all the variable values, but is has an awful lot of them and it will try to use this information to help you understand what’s going on.

You can see the full list of what it understands by looking under Setup, Post, Variables:
This screen is useful for a number of purposes. You can immediately see the current value of any variable, for example (anyone see the bug in the screen above? GWE has made a mistake on one of the variables). You can change the value of any variable just by double clicking it too. And you can see the different groupings for the variables with the row of buttons right above the table. The groupings will help you narrow things down to a particular thing you’re looking for, such as a Work Offset variable.

Conclusion

Programming
That was a lot of information, but you’re now equipped to start parameterizing your g-code programs in ways that should make it possible to reuse the g-code in multiple situations instead of always having to rewrite the code for each individual situation. Good CNC programmers start to accumulate a library of useful g-code subprograms that are tested and ready to go the next time a similar task is at hand.

Exercises

1. Pull out your CNC controller manual and see what differences exist between your controller and what’s described here.

Fanuc Troubleshooting Manual

2. Use GWE to experiment with Macro Variables and Expressions until you’ve got a good grasp of them.

Fanuc Operators Manual Pdf

3. Modify one of your existing G-code programs to use some variables and expressions. Verify that it still produces the correct results when you’ve finished.

Next Article: Subprogram and Macros

5/5(5 votes )