Jump to content

Recommended Posts

Posted

Hi all,

today I would like to share my experience with encoder on scs, the board version made by ilmenator (semper laudetur), attached to MBHP_CORE_STM32F4, midibox_NG project.

I noticed that sometimes, especially when fast rotating my encoder (I choosed a bourns PEC12R), midibox_NG detects more events than really executed, or worse, events in opposite verse.

Using an oscilloscope I saw many spikes on encoder pin, duration shorter than 1 ms.

Following suggestion on attached datasheet (I hope attaching this document is permitted, I did not find any rule against, but if so I will remove it immediately), second page, bottom right, I modified circuit with some patches.

Now it works perfectly, but I have some requests/suggestion to improve design

  • if anyone knows, please tell me if there is a NGC parameter to allow debouncing on encoder inputs, otherwise
  • for TK, please modify SCS scheme to suggest RC filter usage;
  • for ilmenator, please modify your board design and allow to connect necessary 4 resistances and 2 capacitors.

Thanks to anyone,

Regards,

Cristiano

PEC12R.pdf

Posted (edited)
24 minutes ago, latigid on said:

I'm not sure if software debounce affects encoder events?

You're right it doesn't affect it, SW debounce just let some times for the inputs to stabilize, in counterpart we loose reactivity, it's a balance to find depending on the hardware, and encoder quality of course ;)
Note: PEC12 and PEC16 are not equivalent(replacement), I also never get any trouble with the PEC16 which is bigger and more solid than the PEC12.
 

4 hours ago, FantomXR said:

Anyway: Improving the hardware should be better than software debouncing.

Alright! An interesting article.

https://hifiduino.wordpress.com/2010/10/20/rotaryencoder-hw-sw-no-debounce/

 

Edited by Antichambre

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...