Robin2:
It was all going great up to this moment. This ain’t going to happen unless you get an old PC with a parallel printer port.
The reason people use Arduinos for CNC and 3D printing is because the USB system is incapable of the sort of precision you envisage. Have a look at this FTDI paper.
You did not answer my question about whether it would be possible to send a message to the Arduino describing a large number of steps, rather than just a single step.
Maybe you just need something more powerful than a 16MHz Arduino and offload the entire job to that.
…R
Thank you very much for your help. I took a look at the resource you linked. After reading it I think I understand the gist of your concerns. From what I have gathered from reading this the computer sends information in packets of sorts every 1millisecond, and in some cases every 1/8th of a millisecond. So trying to send all of my information at time intervals an order of magnitude or more faster than that would cause so much resolution loss that it would be completely useless. I am probably not understanding this 100% correctly but am I along the correct lines?
RayLivingston:
Seems to me the OP is so focused on one aspect of the “problem” he’s over-looking other, equally important, problems in the solution. Using serial communications to “time” step pulses will be anything but precise, and will, by itself, introduce significant timing errors that will also create jerk.
Even so, unless the robot, or whatever it is, is doing surgery, or is extremely large, or extremely fast, or expected to operate for decades unattended, jerk really is not a major problem, and certainly not something that will have any measurable affect on life of the machine. Many, if not most, ery large, VERY precised commercial machine tools also use linear acceleration, and have no problems with shortened lifetime as a result.
I think the OP needs to take a few steps away from the problem, and consider the negative side effects this “cure” is creating, which could well be worse than the “disease” itself…
Regards,
Ray L.
You bring up a lot of very good points! It is definitely looking like the serial pulse control is a no go to control individual stepper motor steps. I agree now after understanding a little better the way serial communication is done in terms of timing that it would completely counteract the problem I am trying to alleviate.
As I have touched on earlier in this thread, I understand that the current trapezoidal velocity profiles are ‘good enough’. I guess the main usefulness of jerk-free motion would only apply at extremely high speeds to prevent missed microsteps (maybe someday we will be able to 3d print at those speeds) and in terms of very minuscule print quality improvements due to reduced vibrations induced into the frame.
I will be including a discussion about how the modern control is sufficient for our current needs even with the infinite jerk spikes in my thesis. However wouldn’t you agree that if there was a computationally efficient and economical way to create continuous acceleration motion it would be better than the current methods? Even if it is at very low speeds, I have specified as a goal of my thesis to create continuous acceleration motion, which if it is reasonably possible I need to try.
After I am finished with the theoretical thesis work, controlling the stepper motors with continuous acceleration I will be turning my delta robot into a 3d printer for personal use and using a smoothieboard and its linear acceleration for 3d printing.
After concluding with all of your help (THANK YOU by the way) that the serial pulses will not work, I think the best course of action will be to purchase an arduino due. It comes with a 32 bit processor and 50+MHz clock speed which should be a monumental speed increase over an uno or a mega. Hopefully the computational speed will allow me to perform the calculations needed while also being able to send steps to the motors at a reasonable speed (ideally to create 200mm/s top speeds at minimum). I am already extremely proficient at the programming language arduino uses so I will not miss a step when transitioning to it. Along with this, it is compatible with the ramps 1.4 board and pololu stepper drivers of which I already own.
What do you guys think of this approach, do you see any holes? Lastly, is there an approach that you would suggest for generating the stepper motor pulses inside the arduino’s code? I will have a 6th order polynomial that I want each stepper motor shaft angle to follow. I am currently brainstorming ways of doing this without relying on grbl which uses the linear acceleration like everyone else.
Robin2:
You did not answer my question about whether it would be possible to send a message to the Arduino describing a large number of steps, rather than just a single step.
Currently thinking of a way to do this, I think you might be right about it being a good way to do it. Maybe have the computer generate the 6th order polynomials, they have a symbolic solution that is easily solved for each polynomial coefficient. Maybe the arduino due will be able to handle that with no problem.