Page 1 of 1

Problems with rotary encoder

Posted: Tue May 29, 2018 12:04 pm
by Deouss
I work on a project which is supposed to use 3 standard EC11 rotary encoders. I tried couple available libraries however encoders skip the steps or don't recognize rotation properly.
What is the best way to automate and simplify rot. encoding so there is no issues as above?
Is there maybe external circuit translating multiple encoders or some tricky wiring that works best?

Thanks

Re: Problems with rotary encoder

Posted: Tue May 29, 2018 12:29 pm
by ESP_Sprite
The ESP32 has a pulse counter, which can be configured to do up/down counting in the way you'd expect when using a rotary encoder.

Re: Problems with rotary encoder

Posted: Tue May 29, 2018 12:40 pm
by Deouss
Looks like a very good api ! I will try it
Great thanks!

Re: Problems with rotary encoder

Posted: Wed May 30, 2018 1:59 am
by Deouss
Just a small update - tested pcnt example from idf and it works amazingly well with normal EC11 encoder even without changing the parameters in the example. It is very convenient tool and saves a lot lot of coding work )
It has built in thresholds, direction and even events triggered at certain counter values! :)

Re: Problems with rotary encoder

Posted: Wed Jun 06, 2018 8:07 am
by fattore.saimon
Hi,
Here there is a project that can solve your problem: https://hackaday.io/project/27611-i2c-encoder

Re: Problems with rotary encoder

Posted: Sat Dec 15, 2018 11:03 am
by davidqvist
Deouss wrote:
Wed May 30, 2018 1:59 am
Just a small update - tested pcnt example from idf and it works amazingly well with normal EC11 encoder even without changing the parameters in the example. It is very convenient tool and saves a lot lot of coding work )
It has built in thresholds, direction and even events triggered at certain counter values! :)
Hi! Where did you find this example?

Re: Problems with rotary encoder

Posted: Sat Dec 15, 2018 5:03 pm
by Deouss
davidqvist wrote:
Sat Dec 15, 2018 11:03 am
Hi! Where did you find this example?

https://github.com/espressif/esp-idf/tr ... erals/pcnt