encoder icon indicating copy to clipboard operation
encoder copied to clipboard

Wiring Schematic

Open Nick1787 opened this issue 9 years ago • 4 comments

Not really a code issue I apologize, but can you provide a basic wiring schematic? I have your code up and running but it doesnt seem to be working properly in getting values of the encoder. Im wondering if I have it wired incorrectly.

I realize it can be used on any pin, Im wondering if I have the wrong pins on the encoder going to ground or something.

Thanks

Nick1787 avatar Nov 23 '15 12:11 Nick1787

I agree. At least say in the example which piece goes to which pin. I mean the example shows A0, A1, and A2. But which is wired to Clk, DT, + or what? Thanks

mrmonteith avatar Jan 11 '16 23:01 mrmonteith

Hey, the ClickEncoder.h says

ClickEncoder(uint8_t A, uint8_t B, uint8_t BTN = -1, uint8_t stepsPerNotch = 1, bool active = LOW);

so the call

encoder = new ClickEncoder(A1, A0, A2);

With a 5 (3 wire encoder, 2 wire button) wire encoder you should wire as follows: Encoder A = A1 Encoder B = A0 Encoder Common = GND Encoder Button_1 = A2 Encoder Button_2 = GND

malleYay avatar Feb 22 '16 17:02 malleYay

Awesome thanks!

  • Nick

On Mon, Feb 22, 2016 at 12:06 PM, malleYay [email protected] wrote:

Hey, the ClickEncoder.h says

ClickEncoder(uint8_t A, uint8_t B, uint8_t BTN = -1, uint8_t stepsPerNotch = 1, bool active = LOW);

so the call

encoder = new ClickEncoder(A1, A0, A2);

With a 5 (3 wire encoder, 2 wire button) wire encoder you should wire as follows: Encoder A = A1 Encoder B = A0 Encoder Common = GND Encoder Button_1 = A2 Encoder Button_2 = GND

— Reply to this email directly or view it on GitHub https://github.com/0xPIT/encoder/issues/7#issuecomment-187270815.

Nick1787 avatar Feb 22 '16 17:02 Nick1787

also solves #6

pille avatar Jan 22 '18 18:01 pille