News for hackers. Stuff that matters.
Re:Show HN: Robot that copies artist's exact strokes to repl... by chrischen on Monday August 24, 2015 @10:01PM (#10114063)
The description says it's good for "low rotational speeds." It seems to have a very small step angle. Would it be fast enough to drive smooth 1:1 motion? For example, the current motor is really smooth if the movement area is small enough.
Re:Show HN: Robot that copies artist's exact strokes to repl... by tmuir on Tuesday August 25, 2015 @12:14AM (#10114570)
How are you creating your ramping? Most low end CNC controllers do constant-acceleration ramping. If you plot the velocity over time, it looks like a trapezoid. This is obviously easier computation for a microcontroller, but at the points you change from constant acceleration to constant velocity, you have spike in jerk, which is the derivative of acceleration. It is these points which are creating the jolts in the system.

A better ramping scheme is to use constant-jerk acceleration. If you plot velocity over time, the acceleration and deceleration segments look like the letter 'S', which is why this is also referred to as S curve ramping.

The gist of it is that an axis has some maximum acceleration it can achieve, Amax. Accelerating faster than Amax in a stepper motor means that the motor cant execute all of the steps you send it. To achieve constant jerk acceleration, you increase the acceleration constantly until you've reached Amax. Then you accelerate at constant acceleration for some time. Finally, you decrease your acceleration constantly until it reaches 0. Obviously, you want this ceasing of acceleration to coincide with achieving the desired velocity. You first find the two constant-jerk sections times, and then deduce the constant-acceleration section's time. The amount of jerk used is determined by how much extra time you're willing to spend in comparison to constant-acceleration ramping.

The downside is increased computation. Constant-acceleration ramping only needs to solve for time in a 2nd order equation, which is just the quadratic formula. Constant-jerk ramping must solve for time in a 3rd order equation, a much more computationally intensive task. This explains why its normally a feature only found in high end CNC controllers.

Re:Show HN: Robot that copies artist's exact strokes to repl... by bliti on Monday August 24, 2015 @10:07PM (#10114083)
I wish I could give you a definite answer. You are going to get a motor and test. Feel free to continue the conversation over email. Ill do my best to help.