Your encoder is likely just a bare phototransistor.  You might need a 10K
pull-up.     THat might be enough

The "classic" buffer is a comparator with a 10-turn pot used as a reference
and feedback to the positive side of the comparior to create hysteresis.
Feedback is important for stability.  Such a buffer will clean up even
something like a noisy 2-volt sine wave.

Also you should not expect "instant" switching if this is a raw
phototransistor.  There is a mechanical system involved.  The dark blade
that blocks the light takes time to cover the entire hole.   You would hope
they made the hole really small compared to the width of the dark line on
the encoder disk.   It is a mechanical system.

You can test this idea:   Run the motor at different speeds and see if the
slope duration changes with motor speed.  If so then it is a mechanical
artifact.   But if the rise time is constant then it must be the trun-on
time for the transistor which should be constant and not depend on motor
speed.       But even more likely is that it is some of both.  A plot would
show this.

Set the buffer to turn on at maybe 80% of peak and off at maybe 50%

On Wed, Nov 18, 2020 at 7:06 AM Gene Heskett <ghesk...@shentel.net> wrote:

> Greetings all;
>
> Working on getting the BS-1 working.
> ATM. PID.a-feedback is disconnected from from the A encoder, and hitting
> the [] keys to run the motor, the feedback from the encoder is the
> opposite sign of the PID.a input cmd.
>
> 1. Is this the correct state? Or do I need to swap encoder A/B leads?
>
> 2. Does anybody have a cmos buffer board I can put between the encoders
> leads and the bob's input?
>
> I have apparently damaged the encoders output stages, and hooking its
> leads up to the bobs inputs results in the rising edge of the signal
> looking like its charging a large capacitance.  Falling edge is fine.
> Quadrature is excellent.
>
> However as the motor speeds up, it eventually reaches a point where it
> fails to make it to a logic 1 and the whole thing goes nuts. So I need
> the equ of a 74HCT245 to buffer it and bring it to where it can do a
> rail to rail swing. Disconnected from the bob, it does do a rail to rail
> swing with a rise or fall time in the very low microsecond range.
>
> Thanks all.
>
> Cheers, Gene Heskett
> --
> "There are four boxes to be used in defense of liberty:
>  soap, ballot, jury, and ammo. Please use in that order."
> -Ed Howdershelt (Author)
> If we desire respect for the law, we must first make the law respectable.
>  - Louis D. Brandeis
> Genes Web page <http://geneslinuxbox.net:6309/gene>
>
>
> _______________________________________________
> 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