Machsupport Forum
Mach Discussion => General Mach Discussion => Topic started by: c30232 on November 04, 2014, 05:29:07 PM
-
I would like to move un-slaved x and y at exactly the same time to an entered value. The movement is a gantry having two individual stepper drive screw actuators. I am using the below to move a single actuator and I have been able to modify it to move both actuators, however, when that occurs, the first actuator positions and the second actuator follows. But, I haven't figured out of to get simultaneous movement of x and y.
Distance = GetUserDRO(1001)
Code "g90 g0x" & distance
-
Code "G0 X" & distance & " Y" & distance
-
Thanks!!!
It seems to be perfect.
I have a follow up question. If I am lucky and both actuators (each from a different manufacturer) are "geared" exactly the same and thus could be slaved, can the x & a each have home switches to make certain the gantry always starts the day parallel?
I know steppers don't ever miss a step, but none of mine got that memo.
-
Yes, each of the slaved axis can home to their own switches.
-
I simulated the setup for x and a being driven independently. It seems to work well and I assume that it will work in real time. I have confirmed that each of the two actuators are "geared" differently. Will Mach allow the slaving of two ratios? It seems that the software allows it during screen setups, however, when I ran the configuration as x&a slaved the x data seemed to be dominate. That is, x moved correctly and a ran away. Is there a fix to run slaved?
-
Slaved axis must use the same steps/unit.
-
Thank you, I was hoping for the Silver Bullet. With any luck the screws will be the same and a pulley change will fix it. But, your script works, I just need to make certain the operator can't get them out of sync. The only real hurtle so far is in the jog mode. I can jog X-A, but I have not discovered how to jog X-A in incremental mode.