more spindle servo tuning questions

Moderators: TomKerekes, dynomotion

User avatar
TomKerekes
Posts: 2641
Joined: Mon Dec 04, 2017 1:49 am

Re: more spindle servo tuning questions

Post by TomKerekes » Mon Jul 01, 2024 4:57 pm

so on the step/response screen, a small 3 second move is accurate up to 1500rpm and 100 pounds of rotational mass?
Is that a question or a statement? Please post a plot.

That brings up a fun question I like to ask. Guess how much harder (moment of inertia) is it to spin a 1 inch cube of material vs a 2 inch cube of the same material? Hint: its a big number :)
Regards,

Tom Kerekes
Dynomotion, Inc.

turbothis
Posts: 325
Joined: Fri Mar 15, 2019 4:07 pm
Location: southern oregon

Re: more spindle servo tuning questions

Post by turbothis » Tue Jul 02, 2024 12:33 am

i love stuff like the cube demo. i run a lot of things thru chatbot these days as it explains and shows me a lot!

chatbot had a ton of math stuff but it did not copy/paste well....

The moment of inertia of the 2-inch cube is 32 times greater than that of the 1-inch cube, meaning it is 32 times harder to spin the 2-inch cube compared to the 1-inch cube of the same material. This significantly greater resistance is due to the cube's size (side length) affecting the moment of inertia exponentially, as indicated by the \( a^5 \) dependency.

turbothis
Posts: 325
Joined: Fri Mar 15, 2019 4:07 pm
Location: southern oregon

Re: more spindle servo tuning questions

Post by turbothis » Tue Jul 02, 2024 12:39 am

ok i did a move
Attachments
Capture.JPG

User avatar
TomKerekes
Posts: 2641
Joined: Mon Dec 04, 2017 1:49 am

Re: more spindle servo tuning questions

Post by TomKerekes » Tue Jul 02, 2024 5:05 pm

The moment of inertia of the 2-inch cube is 32 times greater than that of the 1-inch cube, meaning it is 32 times harder to spin the 2-inch cube compared to the 1-inch cube of the same material. This significantly greater resistance is due to the cube's size (side length) affecting the moment of inertia exponentially, as indicated by the \( a^5 \) dependency.
Correct. I work it out this way: The mass increases by 8 so that's cubed. The particles of mass are at double the radius so it takes double the torque to apply the same force to the particle. Also the double radius makes the particles move double the speed for the same RPM so need double the acceleration. So 3+1+1=5th order.

So regarding a lathe with something like a solid cylinder for stock the moment of inertial is linear with the length but 4th order with radius.

So the geometry of a 100lb rotational mass is important.

Regarding the Plot: With such low Jerk and Acceleration and with a relatively short move the velocity is only getting up to ~10,000 counts/s. No where near the 200,000 limit that is specified. If you would have plotted velocity you could have seen this. If you zip and attach the raw data then we can plot velocity or error or zoom to see things however we wish.

The TripsWPF is a tool we provide for plotting acceleration and velocity for a set of parameters. Here is a plot for your settings

Trips.png

Notice the Acceleration is triangular because it is completely Jerk limited and only ramps up to 30,000counts/sec2 before it needs to start ramping back down to avoid overshooting the target move size. Its like driving a car but only being allowed to move the accelerator or brake very very slowly, you wont spill your coffee, but will take a long distance to accelerate or stop. So the 50,000counts/sec2 of acceleration is never used.

For a Spindle Jerk limit is probably not very important. You might set it to infinity (1e7).

Notice the Output (green) peaks at about 400 DAC counts which is about 1/5th of the 2000 counts available. So you could probably accelerate several times faster that the 30,000counts/s2 in this test.

The output shows some oscillation which might mean it is borderline unstable. You might decrease P or increase D to try to stabilize it.

The Output has 50 DAC Count "spikes". I assume all the IIR Filters are cleared (you didn't show us). Without any Filters and a D gain of 50 each time the encoder changes by 1 count the output will jump 50 counts. Adding a 2nd order low Pass filter in the last stage at 500Hz and Q of 1.4 should reduce the spikes. The Amplifier might ignore the spikes but it is better to attenuate them.

Try a larger move to test higher velocities. This is difficult with very slow axes like that due to the 3.5sec plot limitation. But maybe with the higher acceleration and Jerk it may show us what we need.

HTH
Regards,

Tom Kerekes
Dynomotion, Inc.

turbothis
Posts: 325
Joined: Fri Mar 15, 2019 4:07 pm
Location: southern oregon

Re: more spindle servo tuning questions

Post by turbothis » Thu Jul 11, 2024 5:12 pm

jeez
so i was going to get back on this a bit

i have another basic newer desktop i was going to run the lathe on to check for exact same behavior (science). while swapping it dawned on me that the trouble i think started right when i got the custom screen done. :? i think it was running great with the "basic 3 axis" screen. now i was going to test this out and noticed my X axis drive wont power on. it seems dead from doing nothing. seems right on track for this....

do you have any recommended servo drives? lol
i feel there is a curse on this machine

User avatar
TomKerekes
Posts: 2641
Joined: Mon Dec 04, 2017 1:49 am

Re: more spindle servo tuning questions

Post by TomKerekes » Thu Jul 11, 2024 5:21 pm

the trouble i think started right when i got the custom screen done. :? i think it was running great with the "basic 3 axis" screen
The Screen having an effect on the Spindle Stability would be very strange. The obvious thing to do would be to switch back to to the basic screen.
do you have any recommended servo drives?
AMC Drives are extremely reliable.
Regards,

Tom Kerekes
Dynomotion, Inc.

Post Reply