Multiple 12v inputs

i have multiple 12v input signals (~24) that will be changing on off state. i intend to output these via serial interface. my question is how do i reduce the input signal to 5v so i don't damage my board

Maybe just voltage dividers.

For extra safety, maybe opto-isolators.

Please always read the sticky post at the top of a forum section before you post a topic there. The section you posted in quite clearly says do not post anything here.

I will move your topic.

Hi, @btoothill
Welcome to the forum.

Opto-couplers would be the best as they provide voltaic and noise isolation.

What is the project?

Can you please tell us your electronics, programming, arduino, hardware experience?

Thanks.. Tom.... :smiley: :+1: :coffee: :australia:

Thanks. I'm not sure what i did wrong on the forum? sorry. as for my experience i have intermediate level experience in electronics and programming and no Arduino experience. My project is to gather signals from multiple on off switches on a truck doing various applications of material. each switch represents a nozzle turned on, there may me numerous 12v input switches turned on simultaneously. my goal is to take these switch states and send them to an AVL unit that will send the switch states via bit pairs to to a server. I do that now but the unit only has the capability to handle 7 inputs. I'm trying to expand that to approximately 25 via the Arduino. my intend is to output these vial the serial interface on the avl. I have the avl programmed to accept these messages

Thanks!!!

  • As mentioned, resistor dividers and Opto isolators first come to mind.
  • You could use transistor switches.
  • You could use a resistor and 5v zener combination.

you could perhaps use a optocoupler.
How to use:

How it looks like

1st pin 12V
2nd pin signal
3rd pin 5V
4th pin input pin


NOOOOO.........................................

This will work and not destroy the opto.

The values of the resistances depending on opto choice.

The other advantage of an opto is that we do not know how the 12V circuit is switched, gnd or supply switching, the opto circuit can be adapted to either configuration.

Tom.... :smiley: :+1: :coffee: :australia:

Welp, i tried my best... I am not a pro as you might be but i tried atleast.

1 Like

Lets try this question; Do you want a ready solution or work on it yourself?

1 Like

Hi @btoothill.

When you are creating a new forum topic, you must choose a category for the topic. The categorization of topics is useful to forum helpers, and to those searching the forum for information, because it allows us to focus our attention on the topics on a relevant subject matter.

When you were creating your topic, you chose the Development Tools > Uncategorized category. The description for that category is:

So clearly it was not appropriate to select that category, but you selected it anyway. One of the forum helpers had to move your topic to an appropriate category.

In the future, when creating a topic please take some time to pick the forum category that best suits the subject of your topic. There is an "About the _____ category" topic at the top of each category that explains its purpose.

This is an important part of responsible forum usage, as explained in the "How to get the best out of this forum" guide. The guide contains a lot of other useful information. Please read it.

Thanks in advance for your cooperation.

You posted in the "Uncategorised" forum section. There are several warnings there about not posting in that section. So why does that section exist? To catch those who do not read warnings and guides! They can then be encouraged to be more careful in future.

1 Like

Tom, would it not be simpler to connect the collector to the Arduino pin, the emitter to ground and use INPUT_PULLUP?

(I also don't like the fact that both resistors are labelled "R" which makes it ambiguous to refer to them, and could also be taken to imply they have the same resistance, which they probably shouldn't.)

In that config ON at the input will make a HIGH at the Arduino input.

Picky.. :grinning:

Tom.... :smiley: :+1: :coffee: :australia:

2 Likes

In your original config, yes. With my suggestion it would read LOW. :slight_smile:

But either is equally easy to deal with in the code.

thanks for the power advice!!!!

my real challenge is that i have at least 10 - 12v digital inputs (on/off switches). i need to output their states (high or low) via serial interface. They are going into an avl with an accumulator that will monitor the states of all the inputs and return them as bit pairs which i will then parce on the back end one they are received

That post contained no additional information. Everyone can scroll up and read what you posted before. No point in repeating yourself.

You have received some suggestions and some questions. Would you like to ask any further questions, or answer any questions, or give some new information, for example an explanation of "AVL" or "bit pairs".

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.