A fundamental decision is whether to label the slave axis 'N', or whether to give it an addressable axis label such as 'V' or 'U'.
For conversation's sake, suppose we have a machine with a gantry Y axis, with the slave servo as axis #4. Axis #4, then, is paired with axis #2 to drive the gantry. Parameter 64 = 2 for pairing active; parameter 64 = 0 to turn pairing off.
Pros and cons if the slave axis is labeled 'N':
+) There is no chance of inadvertently moving the slave independently while paired, with an inappropriate G code command
+) There is no chance of the operator jogging the slave independently while paired, using 4th-axis jog panel buttons
+) The slave axis is automatically hidden from the DRO display and Part Setup screen
-) The slave axis will not hold position if pairing is turned off, e.g. during a squaring sequence
-) The slave axis cannot have its machine zero set or changed with M26
-) Because power is released from the slave axis when pairing is turned off, a resync may be required when it is turned back on.
A resync that occurs in the middle of a cycle (e.g. running the homing macro) causes that cycle to end prematurely.
Pros and cons if the slave axis is labeled 'V':
+) The slave will hold position even when pairing is turned off
+) The slave can be moved independently during auto squaring using its axis letter
+) The slave home can be set independently with M26
-) The slave home must be set with M26; it is not automatically set by M26/Y
-) Extra PLC logic is required to prevent the operator from jogging the slave axis independently while paired
Cons in either case:
-) The operator can move the slave axis independently, while paired, using the MPG handwheel unless PLC code is added to prevent this.
On the machine I was working on last week, the gantry has perhaps 0.150" - 0.200" possible movement between ends. The slave home sensor is positioned about 2.6" in (minus) from the Y+ limit/home position. The machine has some twist in the bridge, such that a small amount of servo torque (ca. 10%) is required just to hold the gantry square. It is unlikely that is going to get fixed any time soon.
Because releasing servo power during or after squaring allows the slave axis to spring away, labeling the slave axis 'N' on this machine was untenable.
The final homing macro I arrived at was:
Code: Select all
#101 = -2.6376 ; Expected Y axis machine position when slave home sensor trips
G10 P64 R2 ; Slave 4th axis to 2nd axis (Y)
G4 P0.5 ; Pause for slaving to take effect
M92/Z ; Home Z to plus switch
M26/Z ; Set Z home here
M92/X ; Home X to plus sensor
M26/X ; Set X home here
M92/Y ; Home slaved pair to Y+ sensor
M26/Y/V ; Set home on slaved pair here
M105/Y P-50008 F30 ; Move slaved pair until clear of slave home sensor
M106/Y P+50008 F1 ; Move very slowly plus until sensor trips again
#102 = #101 - #5022 ; Difference between stored position and this Y position is out-of-square amount
IF [ABS[#102] < 0.001] THEN GOTO 900
G10 P64 R0 ; Un-slave axes so Y can move independently
G4 P0.5
G1 G91 F10 Y#102 ; Move Y by the necessary correction amount
M26/Y L#23804 ; Reset Y home to match slave encoder
G10 P64 R2 ; Restore slaving
G4 P0.5
M92/Y ; Re-home slaved pair to Y+ sensor
M26/Y/V ; Set home on slaved pair here
N900
It does depend on the repeatability of the slave axis home sensor (the prox switch on INP8), because we just move until it trips, instead of looking for an encoder index pulse. On this machine, at least, moving to the prox sensor at 1.0 in/min seems to repeat within 0.001" or so, which is acceptable for the customer.
It would have made more sense, after the "G1 G91" correction move, to have reset the V home to match Y, with "M26/V L#23802". That would have eliminated the need for the subsequent M92 and M26. However, that did not work as expected. Unfortunately I did not make a detailed note of exactly how it failed to work....
If anyone else has addressed these challenges in a different way, I would like to hear about it.