Absolutely agree. Code works as expected and is fast enough for manual rotation. Have not tested for faster resposne.

The encoder indeed has a detent that produces 4x pulses so yeah. It is not appropriate for that code.

Ioannis