Hello Guest it is March 29, 2024, 10:15:22 AM

Author Topic: Superimposing an out of bounds axis on the Z axis in Mach4 Plasma  (Read 676 times)

0 Members and 1 Guest are viewing this topic.

I think I understand that the OB axis motor has the same setting and the Z axis motor and the OB axis can be controlled with jog commands but how is the OB axis superimposed on the Z axis?

Thanks for any explanation or coding examples.
« Last Edit: March 09, 2022, 09:39:13 AM by Tony Bullard »
Re: Superimposing an out of bounds axis on the Z axis in Mach4 Plasma
« Reply #1 on: March 09, 2022, 10:19:59 PM »
Hi,
I don't think an OB axis can be superimposed exactly. My understanding is that "Axis Overload' is employed. Thus tyhe Z axis motor is controlled by the Mach normally
but the 'overload component' adds or subtract a few steps to the Z axis.

Try searching for overload axis.

Craig
'I enjoy sex at 73.....I live at 71 so its not too far to walk.'
Re: Superimposing an out of bounds axis on the Z axis in Mach4 Plasma
« Reply #2 on: March 10, 2022, 08:30:53 AM »
Thank you Craig and that explains it well to to me.

It lead me to Axis Override. I setup a button to test the OB6 axis override of  the Z axis. It woks well with this code:
Code: [Select]
                --in button script
--left button down script

local inst = mc.mcGetInstance()

-- Set the axis 6 to be the override axis for the Z axis.
mc.mcAxisSetOverrideAxis(inst, mc.AXIS6, mc.AXIS2);

-- Set the Z axis jog accel percentage to 25%.
rc = mc.mcJogSetAccel(inst, mc.AXIS6, 25);

-- Set the jog rate to 20% of the Z axis maximum velocity.
        rc = mc.mcJogSetRate(inst, mc.AXIS6,20)

        -- Start Z axis jogging in positive direction
rc = mc.mcJogVelocityStart(inst, mc.AXIS6, 1);


--in button script
--left button up script

local inst = mc.mcGetInstance()
mc.mcJogVelocityStop(inst, mc.AXIS6); -- Stop the axis.
-- Remove axis 6 from the Z axis.
mc.mcAxisRemoveOverrideAxis( inst, mc.AXIS6, mc.AXIS2 );


You are a great asset to this forum. Thank you again.
Tony