Variable Scope

Les…

Is there a way to make feedRate, pierceHeight, cutHeight and pierceDelay available in onInit(). They all seem to equal 0 in onInit().

Also noticed that the feedRate variable seems to map to Plunge Rate.

Thanks

Is there a way to make feedRate, pierceHeight, cutHeight and pierceDelay available in onInit(). They all seem to equal 0 in onInit().

I’m afraid those variables are only available after the first tool change.

Also noticed that the feedRate variable seems to map to Plunge Rate.

feedRate is the current commanded feed rate so it is equal to plungeRate when plunging.

Are they available inside the first OnToolChange() or only after OnToolChange() runs?

Actually, if I remember correctly they are first available in OnNewOperation. OnToolChange comes after that.