Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Encoder Wiring 4-wire Help

Status
Not open for further replies.

Iawia

Member
Hi All,

I have a question on wiring a 4-wire rotary encoder. I have searched diagrams for it and it seems like it is hooked up correctly. I cannot find a lot of information about the output voltage. Is it 5v? My input for can be between 5-24v, I have attempted to probe the output voltage with a meter and get ~1v. What am I doing wrong, can an LED (red dots in diagram) be driven by the output of the encoder? I am also fine with just probing with the meter. Thanks in advance.

1578208286223.png


Rotary Encoder
5-24v input
4-wire
TYPE LPD3806-360BM-G5-24C
Shaft 6mm
(No company name)
 
The outputs appear to be "Open collector" - imagine them as switches to the 0V / GND of the supply.

That allows you to use pull-up resistors to whatever logic supply voltage the electronics the encoders outputs feed - 5V, 12V or whatever, independent of the supply to the encoder itself - though they can also all work on the same voltage.

Without knowing the exact specification, I'd keep the current to 5mA or lower, so eg. no lower than 1K pull-up resistors for a 5V logic supply, or 2k2 if they connect to the 12V supply.

You could connect LEDs in series with the resistors for the 12V supply, but that will reduce the "high" voltage to about 10V - that may well still be OK to feed other logic circuits.

If it's running on a 5V logic supply, connect the LED in series with the 1K and add another resistor, eg. 4K7, from each output direct to 5V to ensure you get "clean" logic level.
(Use 22K direct to power with the 12V version to get the full 12V "high" level, if needed).

Edit - links added:


 
Last edited:
Some of them just put out pulses on A or B (not quadrature).
 
To get the bi-directional you need a quadrature device, (90°)
The spec sheet shows 5vdc - 24vdc open collector NPN output. 360p/rev.
Max.
 
Thank you guys for your responses.

@rjenkinsgb - So with all of that information I am not really sure how to physically alter my circuit to see the HIGH/LOW signals from the encoder. I forgot to mention the 'green rectangular' component in the diagram a 1k resistor. At this location (signal A/B) is where I am attempting to read the meter or fire the LED.

To get the 'High/Low' signal on A or B, how do you recommend physically altering the circuit? Sorry if this seems intuitive to everyone else here.

Should I:

A) Increase the resistance more than 1kOhm
B) Change the location of the LEDs
C) Add a transistor to the signal portion to open a drain
D) Something else

Updated Wiring Diagram
1578266968848.png
 

Attachments

  • 1578262927639.png
    1578262927639.png
    21.3 KB · Views: 526
Last edited:
If you are only connecting to LEDs, the simplest connection is just to change the resistors in your original diagram to 2k2, connect them to 12V rather than ground and reverse the LED polarity.

As it is, the LEDs will switch on when the encoder outputs are "off", allowing the 22K to pull the connection high.
If you try to connect to anything else, you will not get a good high/low level signal.

Think of the outputs as if you were wiring LEDs and resistors with a literal on-off switch connected to ground/negative.
Functionally you have two circuits like this, sharing the "battery" (12V power) and the power negative, which is encoder negative/gnd.

The A & B outputs are the top of the "switches" for each LED circuit.


**broken link removed**
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top