Friday, 4 July 2014

How does a Rotary Encoder work without connecting it to 5V


Like in this picture: enter image description here


I know we can hook 5v later externally to debounce but still, i heard it works without debounce circuit even if its bouncy. But how can it send signals if there are only output and gnd pins?



Answer



They're just mechanical contacts.


schematic


simulate this circuit – Schematic created using CircuitLab


Figure 1. Encoder wired to micro-controller with internal pull-ups.


The encoder is probably wired as shown (but I don't know why there are five wires on your diagram). What you can't see is that the internal pull-up resistors in the Arduino have to be enabled for this to work.


No comments:

Post a Comment

arduino - Can I use TI's cc2541 BLE as micro controller to perform operations/ processing instead of ATmega328P AU to save cost?

I am using arduino pro mini (which contains Atmega328p AU ) along with cc2541(HM-10) to process and transfer data over BLE to smartphone. I...