# How to step down a digital input of 12-30V, 50mA

A similar topic was posted before however I didn’t feel as if it answered my question fully. I’m looking to take a digital input from a controller that ranges from 12V to 30V max and 50mA max and step it down for the Arduino to read it safely at 5V. Im also not sure where the current comes into play in the digital input. Is 50mA too high?

In other posts it was suggested that I use a combination of resistors and zener diodes, I have also been looking around for voltage regulators but I am not getting anywhere. Any assistance on the best/cheapest way to go about this would be great.

EDIT: Attached is an image of the controller schematic.

That's an PNP open collector output, when it activates, it pulls OUT up to COM. What voltage do you have on COM? If your choice of voltage on COM is not restricted by some other requirements of the part, you could just put 5v on it, and probably a pulldown on the output, and it wouldn't need any level shifting.

If you must use a higher voltage on COM than 5v, just use two resistors as a voltage divider to shift the voltage down to 0~5v.

It's unclear to me why they're specifying sink current, though - that looks like it would be sourcing current, since it's pulling the output up towards the supply voltage, so it should source power, not sink it. It should be source current, I would think...

Do you have a link to the full data sheet?

As it looks to me, you have to connect COM to a positive power supply, If COM is not used elsewhere in the module, connect it to Vcc of the Arduino. Connect OUT to an digital input pin, and a pull down resistor (1k or more) to Gnd.

Step down an input from a controller? What? That picture you posted is an output. It relies on an external power supply. The voltage and current ratings are the maximum ratings.

Simply wire a 1k resistor from 5V to COM, and connect OUT to ground. Connect COM to the input on the Arduino.

You mean page 593? Much simpler to find that way. In any case, page 593 shows inputs. What are you trying to do?

The next page, 6-62 aka 594, shows the schematic of an output that you posted a photo of. What I said stands.

Hi,

Do you want to connect a CV-x100 OUTPUT to an ARDUINO INPUT?
OR
Do you want to connect an ARDUINO OUTPUT to a CV-x100 INPUT?

Which one?

Tom.....

What you have posted in post#1 is just an electronic switch.
It can turn something on/off. Or it might output data.
It's switching limitations, before it fries, are 30volt and 50mA.

If you want it to interface with an Arduino input, then polymorph's statement is correct.

"Simply wire a 1k resistor from 5V to COM, and connect OUT to ground. Connect COM to the input on the Arduino.

Leo..