Last move of macro doesn't run

More
4 years 11 months ago #224858 by furynick
I tried a small macro to initialize a probe on my LinuxCNC 2.8.2, the last move of the macro isn't run (G0 Z0), Z axis stay at the position of G38.4.
Code:
O<probe_init> SUB   #5000 = 0.0   (PRINT,Probe init)   G90   G49   O100 IF [ #<_hal[tool-number]> NE 99 ]     (PRINT,Go to tool change position )     G53 G0 Z[#<_ini[CHANGE_POSITION]Z>]     G53 G0 X[#<_ini[CHANGE_POSITION]X>] Y[#<_ini[CHANGE_POSITION]Y>]     T99 M6     (PRINT,Tool changed, go to tool setter at X#<_ini[TOOLSENSOR]X> Y#<_ini[TOOLSENSOR]Y>;)   O100 ENDIF   G53 G0 Z[#<_ini[TOOLSENSOR]Z>]   G53 G0 X[#<_ini[TOOLSENSOR]X>] Y[#<_ini[TOOLSENSOR]Y>]   G38.2 Z[#<_ini[AXIS_Z]MIN_LIMIT>] F100   G91   G38.4 Z3 F15   G90   G53 G0 Z[#<_ini[TOOLSENSOR]Z>]   (PRINT,Initial tool height: #5063) M2 Is there anything I have to add at the end of the macro to "flush" pending commands ?

Please Log in to join the conversation.

More
4 years 11 months ago #224861 by furynick
Forget it, I forgot ENDSUB !

Please Log in to join the conversation.

Time to create page: 0.074 seconds
Powered by Kunena Forum