DMM-TECH Analog Tunning
Moderators: TomKerekes, dynomotion
Re: DMM-TECH Analog Tunning
Hi Tom,
Sorry for lacking info on last post, was trying to post from phone before work.
Dont know why(maybe just needed a reboot) but now iam getting a green plot,even tho its very odd. I also just ried increasing the Velocity from 300000 to 400000. And got a very strange movement. Axis starts out fine then slows waydown reverses and does same thing. Attached is screen shot of both Velocity settings.
Thanks,
Troy
Sorry for lacking info on last post, was trying to post from phone before work.
Dont know why(maybe just needed a reboot) but now iam getting a green plot,even tho its very odd. I also just ried increasing the Velocity from 300000 to 400000. And got a very strange movement. Axis starts out fine then slows waydown reverses and does same thing. Attached is screen shot of both Velocity settings.
Thanks,
Troy
- Attachments
-
- Zaxis1StepDirDrive2000,2000.zip
- (603 Bytes) Downloaded 295 times
-
- Zaxis1Drive2000,2000StepDir.zip
- (447.09 KiB) Downloaded 347 times
- TomKerekes
- Posts: 2676
- Joined: Mon Dec 04, 2017 1:49 am
Re: DMM-TECH Analog Tunning
Hi Troy,
Not quite sure about the first plot. Seems like excessive drift as there shouldn't normally be corrections of 1000 counts. Possibly noise or loss of either steps to the drive or encoder counts back to KFLOP/Kanalog. Your plot misses what happens at the end of the move back.
Regarding the second plot I think the step pulses are getting dropped because of the high rate. When moving at 400000 steps/sec that works out to only 2.5us pulses. By default the KFLOP Step Pulse size is 1.92us. Which only leaves 0.58us between pulses. So the DMM probably misses lots of pulses. Are you changing the KFLOP Pulse timing? See the Pulse Width section here.
I think I found a DYN4 manual and found this specification:
It seems they support Quadrature input mode. I suggest you use that as it eliminates all the pulse width and direction setup time issues and can work at high rates as only one edge is required to step instead of a pulse.
Not quite sure about the first plot. Seems like excessive drift as there shouldn't normally be corrections of 1000 counts. Possibly noise or loss of either steps to the drive or encoder counts back to KFLOP/Kanalog. Your plot misses what happens at the end of the move back.
Regarding the second plot I think the step pulses are getting dropped because of the high rate. When moving at 400000 steps/sec that works out to only 2.5us pulses. By default the KFLOP Step Pulse size is 1.92us. Which only leaves 0.58us between pulses. So the DMM probably misses lots of pulses. Are you changing the KFLOP Pulse timing? See the Pulse Width section here.
I think I found a DYN4 manual and found this specification:
It seems they support Quadrature input mode. I suggest you use that as it eliminates all the pulse width and direction setup time issues and can work at high rates as only one edge is required to step instead of a pulse.
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.
Re: DMM-TECH Analog Tunning
Hay Tom,
So i tried to use Quadrature mode and just got growling. Then i switch back to Step/Dir mode and got very rough movement in one direction and would continue in that direction when axis should be returning back to start with much more growling of motor.
So after chasing my tail and checking wiring i think i have a faulty drive. Did several tests with each motor and encoder on both drives and have eliminated the cables,motors and encoders.
At one point the Z axis drive started giving good green plots, then i let it sit idle for about 2 or 3 minutes and plots started to get worse on each test movement and motor started to growl, particularly in one direction. This also happened when i would connect the X axis to Z axis drive.
So i switched to the X axis drive and kept same configs in Kmotion, results where 100 times better, literally, at one point i was getting an error of .0003". When i started it was around .0015".
But even the X axis Drive had issues when set resolution of 8000(Gear Number 2000 and Line Number 2000). The good test below was drive resolution set to 2000.
Here is a plot showing things going to crap for no reason.This is a average of how the bad plots would look,some made no sense at all... Here is a good one... Also attached is plot file. Did not really try any fine tunning yet, but still got good results.
Will do some more sanity tests tomorrow to double check everything i did. Will post back.
Thanks,
Troy
So i tried to use Quadrature mode and just got growling. Then i switch back to Step/Dir mode and got very rough movement in one direction and would continue in that direction when axis should be returning back to start with much more growling of motor.
So after chasing my tail and checking wiring i think i have a faulty drive. Did several tests with each motor and encoder on both drives and have eliminated the cables,motors and encoders.
At one point the Z axis drive started giving good green plots, then i let it sit idle for about 2 or 3 minutes and plots started to get worse on each test movement and motor started to growl, particularly in one direction. This also happened when i would connect the X axis to Z axis drive.
So i switched to the X axis drive and kept same configs in Kmotion, results where 100 times better, literally, at one point i was getting an error of .0003". When i started it was around .0015".
But even the X axis Drive had issues when set resolution of 8000(Gear Number 2000 and Line Number 2000). The good test below was drive resolution set to 2000.
Here is a plot showing things going to crap for no reason.This is a average of how the bad plots would look,some made no sense at all... Here is a good one... Also attached is plot file. Did not really try any fine tunning yet, but still got good results.
Will do some more sanity tests tomorrow to double check everything i did. Will post back.
Thanks,
Troy
- Attachments
-
- Zaxis1Drive500,500StepDir.zip
- (366.74 KiB) Downloaded 460 times
Re: DMM-TECH Analog Tunning
Hi Tom,
Ok, now that i have the Z axis mount reworked and filters on drives, as i mentioned on the CNCzone post, iam ready to try Analog mode again.
Attached is just a base movement so far on X axis under Analog Closed Loop.
This is a test move of 1.0" (20320 counts). I didnt move further as i was worried about runaway. Because the movement is unstable.
When axis is not moving i can manually turn ballscrew and move table about .01" before servo will start to hold. On the Axis screen of Kmotion the Position shows about 70 to 80 when i turn ballscrew by hand.
What is your recommendation on what i should adjust next.
Thanks,
Troy
Ok, now that i have the Z axis mount reworked and filters on drives, as i mentioned on the CNCzone post, iam ready to try Analog mode again.
Attached is just a base movement so far on X axis under Analog Closed Loop.
This is a test move of 1.0" (20320 counts). I didnt move further as i was worried about runaway. Because the movement is unstable.
When axis is not moving i can manually turn ballscrew and move table about .01" before servo will start to hold. On the Axis screen of Kmotion the Position shows about 70 to 80 when i turn ballscrew by hand.
What is your recommendation on what i should adjust next.
Thanks,
Troy
- Attachments
-
- V1XaxisAnalogDrive1000.zip
- (263.8 KiB) Downloaded 310 times
- TomKerekes
- Posts: 2676
- Joined: Mon Dec 04, 2017 1:49 am
Re: DMM-TECH Analog Tunning
Hi Troy,
It doesn't look like the axis is unstable. I suspect the motion profile is excessively aggressive which is completely different from servo instability. Bigger moves involve higher speeds and accelerations which are probably not possible. Its like me thinking my car is capable of 1000MPH but so far have only tested it in the parking lot.
The Velocity setting is 300000/20320 = 14.8ips = 886ipm ??
The test move is only running at about half that. See below:
Acceleration (148 in/sec^2 = 0.4G) and Jerk (1480 in/sec^3) are very high.
You might read this.
Afterward you should be at the point of adding D Gain in the process described here
HTH
It doesn't look like the axis is unstable. I suspect the motion profile is excessively aggressive which is completely different from servo instability. Bigger moves involve higher speeds and accelerations which are probably not possible. Its like me thinking my car is capable of 1000MPH but so far have only tested it in the parking lot.
The Velocity setting is 300000/20320 = 14.8ips = 886ipm ??
The test move is only running at about half that. See below:
Acceleration (148 in/sec^2 = 0.4G) and Jerk (1480 in/sec^3) are very high.
You might read this.
Afterward you should be at the point of adding D Gain in the process described here
HTH
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.
Re: DMM-TECH Analog Tunning
Hi Tom,
The Velocity setting is what i was able to achieve in CL Step/Direction mode. It was very fast. But in Analog it wants to runaway real easy. Thats why i only did a 1" (20320) move.
m_murray gave me his settings from his 4th axis(Analog mode), just got done trying them and info in your link and i got decent results. But Velocity and Jerk is not as fast and output plot is not as smooth.That said iam still getting about 797ipm, if i figured it right.
Why would the Step/Dir be faster and output look smoother?
He got the IR filters and settings from his other axis that a previous owner used for tunning. Dont know why, but it worked for him and seems to be working for me. Can you make sense of it? Maybe there is something in the filters i need to change for my setup?
Attached is files and screen shots.
Thanks again,
Troy
The Velocity setting is what i was able to achieve in CL Step/Direction mode. It was very fast. But in Analog it wants to runaway real easy. Thats why i only did a 1" (20320) move.
m_murray gave me his settings from his 4th axis(Analog mode), just got done trying them and info in your link and i got decent results. But Velocity and Jerk is not as fast and output plot is not as smooth.That said iam still getting about 797ipm, if i figured it right.
Why would the Step/Dir be faster and output look smoother?
He got the IR filters and settings from his other axis that a previous owner used for tunning. Dont know why, but it worked for him and seems to be working for me. Can you make sense of it? Maybe there is something in the filters i need to change for my setup?
Attached is files and screen shots.
Thanks again,
Troy
- Attachments
-
- V2XaxisAnalogDrive1000.zip
- (377.72 KiB) Downloaded 331 times
Re: DMM-TECH Analog Tunning
Once you've got a rough tune, where commanded and actual position are roughly inline, I'd switch to the following error and output display, as it gives a more detailed overview of what's going on.
The key thing that stands out on that, is you're maxing out the output during the initial jerk limited acceleration. You probably want to reduce the jerk setting so the output isn't maxing out.
I personally wouldn't worry too much about the output being a bit spikey, provide the system is stable, and following error is good. I suspect most digital drives will have a certain amount of filtering on the analogue inputs, even in torque mode (I know the drives I use do), so the spikes will be filtered to a certain extent anyway.
The key thing that stands out on that, is you're maxing out the output during the initial jerk limited acceleration. You probably want to reduce the jerk setting so the output isn't maxing out.
I personally wouldn't worry too much about the output being a bit spikey, provide the system is stable, and following error is good. I suspect most digital drives will have a certain amount of filtering on the analogue inputs, even in torque mode (I know the drives I use do), so the spikes will be filtered to a certain extent anyway.
Re: DMM-TECH Analog Tunning
Hi Troy,
Thats great that the pole zero filter is working for you too! No idea why they are not used more often by others, they work great on my machine on all axes.
Feel free to tweak velocity/accell/jerk as you want. You can also play with P and I values, but I think you most likely wont need D gain with pole zero filters. You should be able to get the same performance as you were getting with step/dir. Keep in mind this is just a lathe, and only medium sized one. So crazy speeds are not a really big deal. Your normally cutting way less then 50 IPM on a lathe and rapids are short. Id be happy enough with 3-400 ipm on a lathe unless your doing huge production runs.
I dont think id worry about output not being smooth.
Thats great that the pole zero filter is working for you too! No idea why they are not used more often by others, they work great on my machine on all axes.
Feel free to tweak velocity/accell/jerk as you want. You can also play with P and I values, but I think you most likely wont need D gain with pole zero filters. You should be able to get the same performance as you were getting with step/dir. Keep in mind this is just a lathe, and only medium sized one. So crazy speeds are not a really big deal. Your normally cutting way less then 50 IPM on a lathe and rapids are short. Id be happy enough with 3-400 ipm on a lathe unless your doing huge production runs.
I dont think id worry about output not being smooth.
Re: DMM-TECH Analog Tunning
I eneded up reducing Jerk to 1.1+7 to remove small Output clip.
Something iam trying to do now is tighten up servo when it is not moving. I can still easily rotate ballscrew and show about 5 counts in the Axis Position window. When in Step/Dir i could not move it at all. What settings affect this?
I also did a quick test on Z axis by duplicating all settings of X axis to my Z axis(Channel2). Something i noticed is on the Configuration window the Microstepper Amplitude is grayed out and set to 20. On my X axis(Channel0) it is 250 and grayed out. Why is this different?
Troy
Something iam trying to do now is tighten up servo when it is not moving. I can still easily rotate ballscrew and show about 5 counts in the Axis Position window. When in Step/Dir i could not move it at all. What settings affect this?
I also did a quick test on Z axis by duplicating all settings of X axis to my Z axis(Channel2). Something i noticed is on the Configuration window the Microstepper Amplitude is grayed out and set to 20. On my X axis(Channel0) it is 250 and grayed out. Why is this different?
Troy
- TomKerekes
- Posts: 2676
- Joined: Mon Dec 04, 2017 1:49 am
Re: DMM-TECH Analog Tunning
Hi Troy,
That is probably good, but you might have increased the Max Output and Max Integrator Instead.I eneded up reducing Jerk to 1.1+7 to remove small Output clip.
If you hold off the axis by 5 counts the output should ramp up to the your max Integrator value of 800 DAC counts to try to eliminate the error. You might check on the Analog Screen that the DAC is commanded to + or - 800 counts. Or check with a voltmeter that ~4V is being commanded to the Drive. If you increase the Max Output and Max Integrator to 2047 then the full 10V should be commanded to the drive.Something iam trying to do now is tighten up servo when it is not moving. I can still easily rotate ballscrew and show about 5 counts in the Axis Position window. When in Step/Dir i could not move it at all. What settings affect this?
In your Output Mode all the grayed out parameters are not used and do not matter what they are set to. The displayed value is whatever was the last value set to that parameter.Something i noticed is on the Configuration window the Microstepper Amplitude is grayed out and set to 20. On my X axis(Channel0) it is 250 and grayed out. Why is this different?
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.