[sdiy] Question how to improve rotary encoder feel
paula at synth.net
paula at synth.net
Fri Jun 9 23:25:10 CEST 2017
Eric,
ooo, counts on both edges... just thinking about it, one of the
interrupts would need to have the reverse logic of the other. I mean;
ENC A IRQ
Read ENCA and ENCB
if ENC A = ENC B clockwise
else anti clockwise
ENC B IRQ
read ENCA and ENCB
if ENC A != ENC B clockwise
else anti clockwise
but that's a VERY neat idea...
Paula
On 2017-06-09 16:46, Eric Brombaugh wrote:
> I've done something very similar to what Scott describes below. You
> can find high-resolution optical shaft encoders that are used for
> mechanical sensing at reasonable prices on ebay:
>
> http://www.ebay.com/itm/Rotary-Encoder-400P-R-6mm-Incremental-Optical-Shaft-Working-Measurement-5-24V-ED-/131969802647
>
> Similar to the dsPIC processors Scott mentioned, STM32 processors have
> a special mode on their timer peripherals that can decode and count
> the 2-phase signals from such encoders. By enabling counts on all
> edges you can get 4x the PPR resolution, so the example 400ppr encoder
> above yields 1600 counts/revolution. I've used that as a frequency
> control on digital radios - it's extremely smooth and provides very
> natural acceleration. The downside of course is that it's mechanically
> cumbersome.
>
> Eric
>
> On 06/09/2017 06:07 AM, Scott Gravenhorst wrote:
>>
>> Just spit-ballin' here...
>>
>> There are optical encoders that are used to detect motor speed and/or
>> shaft angular position. Obviously, these are designed to be connected
>> mechanically to a motor, but I see no reason a person with mechanical
>> skills couldn't adapt one to use with a knob. They have no detents,
>> so
>> they rotate freely and smoothly, even to the point of being able to
>> spin. Maybe a flywheel could be added to allow more spinning with a
>> given amount of force. I've no idea what these would cost tho, nor
>> the
>> resolution of counts per revolution. The only reason I know about
>> these is from reading about them in a dsPIC...MC (motor control) chip
>> datasheet. These chips have QEI peripherals in them to automatically
>> count the revolutions.
>>
>> -- ScottG
>> ________________________________________________________________________
>> -- Scott Gravenhorst
>> -- http://scott.joviansynth.com/
>> -- When the going gets tough, the tough use the command line.
>> -- Matt 21:22
>>
>> _______________________________________________
>> Synth-diy mailing list
>> Synth-diy at synth-diy.org
>> http://synth-diy.org/mailman/listinfo/synth-diy
>>
>
> _______________________________________________
> Synth-diy mailing list
> Synth-diy at synth-diy.org
> http://synth-diy.org/mailman/listinfo/synth-diy
More information about the Synth-diy
mailing list