diode + mux question

Go To Last Post
9 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Freaks,

I am using a 74hc4051 mux/demux to switch GND's to diodes. The mux is controlled by three AVR ports. The diode drop is measured by the AVR ADC channel.

Here is my question:

I have connected the anode of the diode to the supply, resistor and the ADC input. When the output is selected (in this case Y1, there will be one more diode to Y2), I want GND to be applied to complete the diode circuit and measure the 0.7V with the ADC.I tried this and it is not working.I am getting zero volts at ADC input.

It is working the other way round, ie. when I connect the cathode to ground, I can use channel Y1 to apply the 5V + resistor path to the diode, to forward bias it and measure the 0.7V with the AVR.

So how do I connect this circuit? Since by default the output of the demux on a non selected channel is always zero, how do I switch ground to this diode to forward bias it and measure about 0.7V drop with ADC?

I also thought of raising my GND for the diode to about 0.7V so it will be higher than the default zero volts of the non selected demux channel, but that became too complicated. I would like to know if an easier fix exists.

Thanks.

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I think you're going to have to measure the voltage differentially, using two ADC inputs. Try splitting the dropping resistor into two equal-value units (e.g. instead of one 500k use two 250k), one in the cathode lead and one in the anode lead. This will cause the voltage measured to be around Vcc/2 even with voltage drops in the multiplexer. The benefit is that you don't need to worry if the mux behaves badly with inputs and outputs near the rails (Vcc and GND).

Mike

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks for the advice, Mike.

Actually I tried that idea but I don't remember what I got, I tried so many things in desperation. :) I will try it again.

Actually I was thinking what if I measured the drop across the second resistor (cathode) and GND and then subtract that from 5V and the drop across the other resistor to get the diode drop? I know my current is 10uA so I know the drop across the first resistor.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ok here is a stupid question: If a diode gets reverse biased and I measure the voltage as say 1.5V does that mean the diode is working? I have a clamp voltage (about 3.3V) which I measure on the ADC if the diode is dead or there is no diode.
In other words, if a diode measures a known reverse bias voltage (which is not the clamp value) is that a good enough test to ascertain that the diode is working (in the forward bias condition as well)?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Anybody?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Usually a diode gets shorted when it fails. So it conducts no matter how You connect it.

A normal (4148) working diode does not conduct in the reverse direction but there is one parameter You could measure. The capacitance of the diode changes rapidly when approaching the forward bias voltage.

Well ... to be exact the diode DOES conduct in the reverse direction as well. But the current is next to non-existent and it takes special equipment to measure that accurately.

I would, however, measure the forward bias voltage of the diode exactly as You tried to do. It is well known and it is propably the easiest to measure of the diode variables. The forward bias also is a very good indicator of the condition of the DUT.

I would do this this way:
1. have all anodes of the diodes connected togeter and measure the voltage with the ADC from there
2. have a pull-up resistor (27K...100K) to VCC from that common point
3. have the Y-side of the MUX connected to the cathodes of the diodes
4. have the pin 3 (the mux common) connected to ground

When a diode is selected by the S inputs of the 4051 one of the cathodes will be connected to ground while others are left floating. I cannot see any reason why this would not work.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

See Bob Pease's book Troubleshooting Analog Circuits. Chapter Six is all about diodes. Page 68 has a test circuit for testing diodes which you may be able to adapt to an AVR.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks, eskoilola and alwelch. I will take a look at the suggested idea and the book as well.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ok that worked. Thanks, eskiolola.

One last question: Is there a commonly used 16 channel analog mux similar to 74hc4051? I can use two 74hc4051 but it will be very clumsy code and hardware wise.

I found this analog mux:
[url]
http://www.analog.com/static/imp...
[/url]

Also this Maxim mux:
[url]
http://www.maxim-ic.com/quick_vi...
[/url]