Thanks for the prompt reply. I have a floating head switch so z homes to the surface plus some free travel and then trips. On the mach plasma screen I have added four extra DRO, Pierce height, Pierce delay, Cut height and z offset. Reading some of your old post and others, on plasma set up, I am trying to understand the code.
At the moment I have a macro adapted from one that I think was written by you (not sure):-
PierceHeight =GetUserDRO(1000)
CutHeight= GetUserDRo(1001)
PierceTime=GetUserDRO(1002)
Zoffset=GetUserDRO(1003)
Code “G28.1Z0”
While IsMoving( )
Wend
Code”G92 Z0” (set z to 0)
While IsMoving( )
Wend
Code”GO Z”&Zoffset ( Retract to top of material)
While IsMoving( )
Wend
Code”G92 Z0” (set z to 0)
While IsMoving( )
Wend
Code”GO Z”&PierceHeight
While IsMoving( )
Wend
DoSpinCW( ) (Turn torch on)
While IsMoving( )
Wend
Code”G4P”&Pierce Time (Pierce delay)
While IsMoving( )
Wend
Code”GOZ” &CutHeight (Go to cut height)
While IsMoving( )
Wend
End
If I run this macro step by step in the VB editor it appears to run OK but on the actual machine I get variable results in the cut height setting. Very new to macros and on a steep learning curve! Is the macro correctly structured?
Thanks for your help