Hi I just picked up three rotary encoders from adafruit and they are unresponsive with the nkrkv/encoder node. The node deploys but the counters don’t move when handling the encoder. Has anyone else had this issue lately? Could it be these particular encoders? All my pins are set up properly so im not sure what the issue could be.
These are the encoders: https://www.adafruit.com/product/377
This is the node code that im trying to use. It is directly from the example experiment from the nkrkv/encoder library.
Hmm… They should. The library is made specifically for this kind of encoders. Are you sure your wiring is correct? Do you see digital port value switching if use a pair of simple
Thanks for your response! Checked the wiring and seems ok. Digital read pins both say “false” and don’t switch when I rotate the encoder. Oddly, I can get the encoder working in one direction with the escape-ford / encoder ky040 node. Very strange!
I think your encoder needs pull-up resistors.
in the example of arduino the pull-ups are configured, but in XOD they are not implemented, you can put external resistors or modify the code C++
// set pins as input with internal pull-up resistors enabled
@cesars Yes!! Thank you! Just added some 1k pull ups and works perfectly!
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.