2

I am trying to measure the voltage on an LED in an open circuit (awfully shown below) using an arduino, however the voltages are too high for its inputs.

I have tried:

  1. Using a voltage divider (~10K total resistance), however current flows and the LED lights up (which I do not want)
  2. Bumping up the total resistance of the divider to ~10M, the LED glows extremely dimly (which is fine), but now the arduino doesn't read the voltage correctly (due to noise or something?)

So now, I have decided to use some Zener diodes to drop the voltage before connecting with the arduino, is this (theoretically) going to work? Or is there some simpler/smarter way around this?

Also stumbled on this: Measure voltage with no current, but it seems a bit more complicated than using the diodes.

awful diagram

Any input is greatly appreciated.
Many thanks

Update: Thanks everyone for all the help, ended up using the pull-up as it was the simplest

Ohhai
  • 43
  • 4

3 Answers3

9

schematic

simulate this circuit – Schematic created using CircuitLab

Figure 1. Opto-isolator current monitor.

As jsotola suggests, you can use an opto-isolator but rather than connect in parallel you can connect in series to reduce power consumption and save another series resistor. This will decrease the voltage available to your 12 V LED by about 1.4 V or so but this is unlikely to be an issue.

Notes:

  • The opto-isolator LED has to carry the full current for your existing LED.
  • R2 may be omitted if an internal pull-up is used. That makes it a single-component solution.

@Trevor's solution is simpler and cheaper. Use this one if isolation between the circuits is an advantage.

Transistor
  • 168,990
  • 12
  • 186
  • 385
  • the OP said that the circuit is a "light", so it is possible that there is a fairly large current being drawn. the series connected opto-isolator may not be able to handle it. – jsotola Dec 16 '17 at 22:21
  • Thanks, @jsotola. He buried that information in the comments and I didn't see it. It should have been in the question but I addressed it anyway on the first bullet point. Oh well ... – Transistor Dec 16 '17 at 22:57
9

Perhaps I am missing something here, but from your comments you seem to only need to know when the LED is on, or to put it another way, when the switch is closed.

You can do that with a simple diode and a pull-up.

schematic

simulate this circuit – Schematic created using CircuitLab

Trevor_G
  • 46,364
  • 8
  • 68
  • 151
1

if you can replace the switch ...

schematic

simulate this circuit – Schematic created using CircuitLab

jsotola
  • 2,497
  • 2
  • 12
  • 21