On 06/29/2017 03:59 PM, Les Newell wrote:

Do you have and raw-write encoder filter tweaking stuff in the hal file:

No. For testing purposes I am running the barest minimum needed to achieve motion using a config generated by pncconf.

After spending a lot of time playing with halscope I have some interesting findings. Most of what I thought was noise is actually phase variation in the encoder counts. There is a cycle that repeats every 4 counts. When zoomed out of course it just looks like random hash. I checked by monitoring the encoder counts and velocity at the same time. I could clearly see the cycle repeating every 4 steps in the encoder count.

I think it is time to put a scope on the encoder. it sounds like there may be a big duty cycle or phase angle error in that encoder. In other words, at constant speed, the 4 quadrature transitions are not evenly spaced, but at least one of them is out of time.
Now for the really weird bit. It didn't sink in before but the spikes are always positive, no matter what direction I am moving! in other words if I move in the positive direction the spikes show increasing velocity. If I move in the negative direction the spikes show decreasing velocity. I have a log that shows one spike reaching zero velocity for one encoder count. I have another log when moving in the other direction where the spike is nearly double velocity for one count. However in both cases the width of the encoder count is pretty much the same as nearby counts. I can't think of any way that electrical noise could give this result. If anyone wants to see the logs I'll upload them tomorrow.

Assuming the spikes happen fairly often, you should try setting up Halscope to display velocity and trigger on where you think a spike might reach, and then move the axis by hand for a while and see if the scope triggers.

Not easy. The screw is difficult to get to and I can only turn it about 1/4 turn at a time.
With a little hacking of Hal commands, you should be able to set up a roughly constant speed on the motor, running open loop. Or, even run closed loop and just hook the scope to the encoder signals.

I can't see it being pickup in the encoder cable. It's only about 18" long and doesn't run near any noisy wiring, apart from a couple of inches near the 7i29. It is the original screened cable fitted by the manufacturer of the encoder. Apart from that I don't see how noise could produce the results I am seeing.
OK, I did not know what your setup was there.

Jon

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to