"Step per click" in the Library "CommonBusEncoders"


i am fighting with my lack of knowledge of english
technical terms…please help… :slight_smile:

I am using a simple rotary encoder by RobotDyn:
which has a button switch (pressing the knob down) and 24steps per
rotation. And as far as I can decode the english terms it has 24 dents -
that is: it makes 24 times “click” when rotating the knob.

I want to use this library

which is referenced from here:
because the library has a debouncing algorithm build in and the rotary
encoder, which I want to use is known for bouncing.

In the tutorial.pdf, which comes with the library I found this
descriptive text:

Furthermore, this Library is designed for encoders that have detents (clicks). Some encoders have 4 steps
*per click, and others have 2 steps per click. This Library will be able to handle either one or a mix of them. *
The Library will return a code to the sketch only when the encoder clicks. This design has been made
because it is used to change discrete values (integers, letters of the alphabet, angle in degrees…).

…but what does this “2 steps per click” and “4 steps per click” mean? I searched the forum with
“encoder steps per click” but this leads to tons of informations about stepper motors…

As far as I had understood my encoder it does 24 clicks per turn which results in 24 steps…
On the other hand: If there are encoders out there, which do more then one step per click…how can one manage to do one step at a time then?
Most probably I got the whole thing wrong wired in my head…

Any help is very appreciated!

They mean transitions per click. Each of the two signals from an encoder changes (transistions) twice
per pulse.

For instance these encoders are usually 24 pulses per revolution, so 96 transistions per revolution (counting
both signals). The finest resolution you get from an encoder is a count of the transitions. You’d divide
by four to get a click count.

You thus don’t use the encoder count directly, but reduce its resolution before using the value.

Hi Mark,

thanks a lot for your explanations! THAT helps! :slight_smile:

So … “number of steps” is “sum of the number of raising and falling edges of all signals,
which are created by turning the knob for one dent/click”.

I think, the term “steps” is a little confusing in this context…

Thanks a lot! :slight_smile: