Hi,
I got a pair of wires from encoder, wire A and Wire A-. When encoder moves the voltage between wires changes state form +5V to -5V and so on.
I'm trying to optoisolate these signals and convert them to 0...5V TTL.
Optocoupler is HCPL2631, and signal at this point is given from signal generator.
No matter what I do the output of the optocoupler stays at 0,28V. Paraller to led of a optocoupler I have 1N4148 to limit the reverse voltage because the led in the opto can't handle it.
When +5V is supplied, A in higher potential than A-. I measured 10 mA current in the input, and 1,4x voltage over led in the opto. So led should be lit, and output from opto (between opto GND and pin 7) about 0V. This state seems ok.
BUT, when I change signal to -5V, A in lower potential than A-. The output from opto won't jump to 5V, as i want, but it stays close to 0V. Over the led inte opto is -0,7V voltage because 1N4148 opens and about 10 mA current flows trough the resistor (opposite direction than in +5V direction)
In picture higher wire is A and lower A-
What am I doing wrong? Electronics aren't my strongest point..
I got a pair of wires from encoder, wire A and Wire A-. When encoder moves the voltage between wires changes state form +5V to -5V and so on.
I'm trying to optoisolate these signals and convert them to 0...5V TTL.
Optocoupler is HCPL2631, and signal at this point is given from signal generator.
No matter what I do the output of the optocoupler stays at 0,28V. Paraller to led of a optocoupler I have 1N4148 to limit the reverse voltage because the led in the opto can't handle it.
When +5V is supplied, A in higher potential than A-. I measured 10 mA current in the input, and 1,4x voltage over led in the opto. So led should be lit, and output from opto (between opto GND and pin 7) about 0V. This state seems ok.
BUT, when I change signal to -5V, A in lower potential than A-. The output from opto won't jump to 5V, as i want, but it stays close to 0V. Over the led inte opto is -0,7V voltage because 1N4148 opens and about 10 mA current flows trough the resistor (opposite direction than in +5V direction)
In picture higher wire is A and lower A-
What am I doing wrong? Electronics aren't my strongest point..