Welcome! Log In Create A New Profile

Advanced

xy drawing machine with marlin, coordinating the servo for the z axis

Posted by secondsky 
xy drawing machine with marlin, coordinating the servo for the z axis
December 29, 2014 06:07PM
Hi all i'm trying to use marlin to control a 2 axis drawing machine.
I would like to use two stepper for x and y axis, and a servo instead of the 3rd stepper for move up and down the pen (z axis), just like an on of.
I use the command M280 to control the servo, and it work.

In the beginning of each paths, i put in the gcode a command to raise the pen, then a little delay, then one to move the x-y axis, then a command to lower the pen.

The problem is that marlin execute the command to put the pen down during the x-v movement that should happen with the pen raised by the precedent command.

What can i do, to say him to do it just when the previous command has been performed?

Thanks
Re: xy drawing machine with marlin, coordinating the servo for the z axis
December 29, 2014 06:15PM
in marlin a lot of the M code commands are unbuffered leading to the behaviour you have seen,

there is an M code call M400 which you can place before your M280 which will make it wait until the move is complete before executing the M280 it's also probably not a bad idea to put it after the M280 as well




-=( blog )=- -=( thingiverse )=- -=( 3Dindustries )=- -=( Aluhotend - mostly metal hotend)=--=( Facebook )=-



Sorry, only registered users may post in this forum.

Click here to login