PDA

View Full Version : Rotary Encoders parrallel wiring?



Tomlin
11-11-2008, 11:49 AM
Hi guys

I know this sounds crazy probably, but Im wondering:

Would it be possible to wire 2 Rotary Encoders to one rotary encoder input using the correct wiring scheme? Here's what I want to do:

On the LJ45 there's two Altimeter setting rotary encoders; one each on the two PFDs. Since the both do the exact same thing, couldnt I just parrallel wire them both and interface to the same input, especially since they both wont be used simultaneously.

I know that switches can be done this way (such as the STND button to set 29.92") but will it work for my above scenario?

thanks,

fweinrebe
11-11-2008, 12:17 PM
Hi,

what you can try is to feed the 2 encoders' outputs to some sort of high impedance component such as a buffer or a logical gate. Use an OR gate (an OR per channel) to bring the signals together. If you are using 5V on your encoders, you could use a TTL IC otherwise CMOS.

Since the inputs of the OR gates have a high impedance (resistance) they should not interfere with each other.

If you need more info on this idea let me know, I can draw you a rough sketch for the logical circuit.

[EDIT]: Additionally you would need a detector circuit that detects which encoder is turned, disable the other encoder's signal.

Tomlin
11-11-2008, 12:34 PM
Thanks Fritz. That's a lot more complicated that I thought...I was hoping that the wire leads would just be tied together where they meet at the input board. :-/

Im trying to save buying more rotary encoder input interfacing than required, but it may just be better to do just that.

Any other thoughts or ideas are welcomed.

Mike.Powell
11-11-2008, 12:52 PM
Would it be possible to wire 2 Rotary Encoders to one rotary encoder input using the correct wiring scheme?




Depending on the type of rotary encoder and the acceptable complexity of the solution, here are two approaches:

1) If you have rotary encoders with the detent located at the position where both switches in the encoder are open, you can simply wire the two encoders in parallel. This is called a "wired-OR". This approach requires that the input the encoders connect to will properly operate with an encoder having one detent per four transitions.

2) Use a micro controller to mediate between the two rotary encoders and the input connection for the encoders. The micro controller keeps track of state transitions of each encoder and produces a virtual encoder output that reflects the aggregate encoder activity.

Tomlin
11-11-2008, 12:55 PM
Depending on the type of rotary encoder and the acceptable complexity of the solution, here are two approaches:

1) If you have rotary encoders with the detent located at the position where both switches in the encoder are open, you can simply wire the two encoders in parallel. This is called a "wired-OR". This approach requires that the input the encoders connect to will properly operate with an encoder having one detent per four transitions.



How would we know which RE would fit the bill?

fweinrebe
11-11-2008, 01:45 PM
I like Mike's proposal (2) better because it will work on any type of Encoder. (1) is a bit dicy because what if the one encoder is left in such a position that the switch is close. Then the other encoder won't work.

Mike.Powell
11-11-2008, 02:43 PM
Finding a good rotary encoder starts with digging through spec sheets. A cursory glance through several was disappointing. I found only one that showed the position of the detent during the grey-code cycle. (http://www.bourns.com/pdfs/PEC12.pdf lower right corner of the first page)

Fritz raises a good point. There is no indication of how accurate the detent position is, or how well the encoder holds onto that accuracy as it ages.

fweinrebe
11-12-2008, 03:44 AM
Looking at that Grey code output table I marked the areas blue for the encoder to be at when not turning, for the other encoder to still work. If the one encoder is stuck somewhere in the white area, it will produce a 1 (5V) all the time. Using the OR method will then not work because with an OR the output will always be 1 in that case. There will be no pulses from the other encoder, just a 1 all the time.

1239

I can imagine a checklist item added to fix this:

BAROMETER KNOB ..................... Check Stop Position ;)

Tomlin
11-12-2008, 09:36 AM
Thanks for all the in depth explanations- I never imagined how complicated it could get!

Seems that the best way to go is just buy more input modules for RE needs.

Kennair
11-12-2008, 09:48 AM
Would it be possible to incorporate a simple changeover switch that mediates between the two encoders? As you say, you'll never want to use both at the same time, so could you simply flip a switch to put either one or the other into circuit? It's not as clean as simply rotating one or the other but it could be an intermediate fix.

Just a thought,

Ken

fweinrebe
11-12-2008, 10:00 AM
Ken,

yes it would. You just have to use a DPDT (Double Pole Double Throw) switch since the Rotary Encoders have two signal wires.

Another idea:
One can use a relay which has a DPDT switch. Connect a motor (Those small ones found in toys) to each rotary . When you turn the Rotary, the motor generates a voltage. That voltage can in turn switch on a transistor. The transistor can switch the relay on to switch on the rotary it detects is the one rotating. Thus disabling the other one.

Kennair
11-12-2008, 12:16 PM
Ken,

Another idea:
One can use a relay which has a DPDT switch. Connect a motor (Those small ones found in toys) to each rotary . When you turn the Rotary, the motor generates a voltage. That voltage can in turn switch on a transistor. The transistor can switch the relay on to switch on the rotary it detects is the one rotating. Thus disabling the other one.

What a novel approach Fritz. I'm astounded at the ingenuity offered here.

Ken.

fweinrebe
11-15-2008, 03:32 PM
Thanks Ken. Glad you liked the idea.

Here is another idea (Eric probably received his additional order of rotary encoders by now): I see it as a 3rd solution to this idea and we will probably see it in the future. Magnetic Rotary Encoders. A company by the name AustriaMicrosystems created a Magnetic Rotary Encoder. It is basically a magnet that rotates over an IC and the IC gives a 8 bit output of the position of the magnet. Since the magnet is not touching the IC, the lifespan of the encoder is larger than that of an optical or mechanic rotary encoder. It also measures the strength of the magnetic field, so this enable you to create an "Push-button" effect. One can probably use it for a pull effect as well. One can use your own magnet.

Now this is where it contributes to the parallel rotary encoder idea. The IC's can be daisy chained. I think that means you can have more than one encoder feeding data to the microcontroller. This could allow multiple encoders used for the same action.

More info here: http://www.austriamicrosystems.com/eng/Products/Magnetic-Encoders/Rotary-Encoders/AS5030