Okay so I've further edited the PP like so. On the tool change 'event' if it's a drill operation then add an M0 pause command, And if it's a cut operation, but the cutType veriable was previously set to 'Spotting' then add another M0 pause.
Am I creating any issues with this approach? Also, is there a way to open a pop up message box to instruct the user?
Code:
function OnToolChange()
...
elseif string.match (toolName, 'Centre Spot') or
string.match (toolName, 'Center Spot') or
string.match(operationClass, 'DrillOperation') then
cutType = 'Spotting'
cutName = 'spot'
spindleNum = 2
toolNum = 0
post.Text (' M0 (********** TURN THE PLASMA CUTTER DOWN TO 10 AMPS FOR SPOTTING **********)\n')
else
if cutType == 'Spotting' then
post.Text (' M0 (********** SET PLASMA CUTTER TO APPROPRIATE AMPERAGE **********)\n')
end
...
end