The noise here is not electrical noise on the cables.  We assume the signal
is perfect square waves.    This is "quantization noise".

Here is what happens...   Say you have 50 slots on the spindle and the
motor is turning at 100 RPM.   This is 1.67 revolutions per second so 350
pulses per second.  Now let's say your PID algorithm samples the encoder
100 times per second.  On average, it will get 3.5 pulses, but the count
must always be a whole number so sometimes it gets 3 and sometimes 4.  Each
time, the PID sees this as an error and tries to correct it.
 Quantization noise is what happens when the measurement lacks enough
resolution.

Noise is defined as an error in the signal and there will always, on
average be 1/2 count of noise error in the signal, even if it is
electrically perfect.  If the typical number of counts is 100 per period
than a 1/2 count noise is only 0.5% but at low speed where you expect only
2 counts the 1/2 count error is 25%

The solution is to either add more counts per revolution or use a ten times
more complex control algorithm.

On Wed, Jul 21, 2021 at 3:36 PM John Dammeyer <jo...@autoartisans.com>
wrote:

> It's been a while since I did quadrature programming but if you have two
> sensors don't the two work together to validate signals because they can
> only change under certain conditions.  So noise can't totally screw things
> up.
>
> Now having said that of course I did change from US Digital on my DC
> Servos to CUI because they were impacted by noise and over time there were
> more counts in one direction than the other.  So a return to zero wasn't
> the original zero.
>
> So I'm probably all wet.  But 60 pulses per rev is a lot different from
> thousands.  Might be better to clean up the signals at the source before
> they are ever counted.
>
> John
>
>
> > -----Original Message-----
> > From: andy pugh [mailto:bodge...@gmail.com]
> > Sent: July-21-21 11:54 AM
> > To: Enhanced Machine Controller (EMC)
> > Subject: Re: [Emc-users] A new lathe encoder option.
> >
> > On Wed, 21 Jul 2021 at 19:49, Chris Albertson <albertson.ch...@gmail.com>
> wrote:
> >
> > > Could you solve the noise issue with a phase-locked loop?
> >
> > Yes, this would be a far better solution. But I didn't want to
> > re-write the encoder counter from scratch.
> >
> > Ideally you would use two PLLs, one for the pulses and one for the
> > index, to predict the pulse gap and extrapolate through it.
> >
> > --
> > atp
> > "A motorcycle is a bicycle with a pandemonium attachment and is
> > designed for the especial use of mechanical geniuses, daredevils and
> > lunatics."
> > � George Fitch, Atlanta Constitution Newspaper, 1912
> >
> >
> > _______________________________________________
> > Emc-users mailing list
> > Emc-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/emc-users
>
>
>
> _______________________________________________
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>


-- 

Chris Albertson
Redondo Beach, California

_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to