Go Down

Topic: Lower the voltage (Read 282 times) previous topic - next topic

jucasan

I'm working in a project and trying to read an encoder. The input voltage for the encoder is 7-24V and most likely I'm going to use 12v.

The problem is the output voltage is the same than the input and 12v is too much for the arduino input.
How can I fix this?

actuator with encoder

thanks

Mikeb1970

Just use one of these options coupler isolators, they are designed for Arduino and can handle up to 24v

https://rover.ebay.com/rover/0/0/0?mpre=https%3A%2F%2Fwww.ebay.co.uk%2Fulk%2Fitm%2F272619003281

I hope this helps you,

Mike

avr_fred

A simple resistive divider network is all that you need. Three 33K resistors would be fine, all in series between the encoder output and ground. Tap at the top of the resistor connected to ground and you'll have approximately 4 volts out with 12 volts in.

jucasan

#3
Feb 10, 2018, 04:49 pm Last Edit: Feb 10, 2018, 05:53 pm by jucasan
Thank you guys,

I like the idea of the optocouple better. Seems to be more safe than the resistive diviser. Can't find any good diagram. it should be something like this?

wiring diagram

or

PC817

outsider

#4
Feb 10, 2018, 06:59 pm Last Edit: Feb 10, 2018, 07:01 pm by outsider
If the encoder has open collector outputs, you may only need pullup resistors to 3.3V, but?
If you do use optos, make sure they can reliably transmit your encoder's highest pulse rate, which is?

MarkT

What is the maximum speed of this encoder?  Standard photo-transistor output opto-couplers aren't
particularly fast so this might be an issue if its a high rate of pulses.
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

jucasan

The only information about the encoder on the website is this.

The chip built-in encoder, the signal has been a little wave processed, the accuracy of 400 pulses per second.

A plurality of photoelectric sensors built in, can be output Standard square wave, can be directly connect with microcontroller or PLC board, determine the motor reversing, speed control, stroke position control, synchronous operation paired synchronization and batch funcions.

Red line: DC7v-24v power input, needs a stable and less interference DC power supply
Green line: Pulse output, high level equal to the input voltage, low 0v, the standard square wave.
White line: Pulse output, high level equal to the input voltage, low 0v, the standard square wave.
Black wire: Negative pole of power supply

Hope this helps. unfortunately don't have a background in electronics to give more information.

Thanks

Go Up