Connect with us

mV voltage reference for a comparator

Discussion in 'General Electronics Discussion' started by beethovenj, Apr 1, 2014.

Scroll to continue with content
  1. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    Hi to all!

    Thanks for being there!

    Well, I need to design a small circuit and I have some doubts.

    I have multiple inputs and I need to detect if I got a signal in more than one input at the same time. The signals are pulses of 30 mV and 55 ns of width.

    I will use individual comparators for each input, and then add up all the outputs of the comparators and then use another comparator and check if it the result is more equal or more than two comparator outputs.

    My question is related with the Vref for the input comparators. Since it will be around 20-25 mV I am not sure if my solution is the best option:

    The idea would be to use a zener or a high stability voltage reference IC, and then a simple voltage divider with a trimmer in pararell the the R2 (grounded resistance) for fine tunning. Then I'll use a buffer to use this Vref with all the comparators.

    Is this an appropiate method for setting a stable mV Vref? or there are better ways of doing it?

    Thanks so much!
    Any recommendations will be very welcome,

    Thanks again.
     
  2. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,490
    2,832
    Jan 21, 2010
    One issue is that comparators normally give you an output that is either on or off. They're not something you can add in the mathematical sense that you seem to imply.

    Perhaps you can tell us what you need to do rather than how and we can be of more assistance.
     
  3. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    Thanks a lot for the reply:

    I'll describe a bit more in detail the application:

    It is a physics experiment. I have a detector with let's say 3 layers. Each layer has multiple cells. If a cell detects something generates a 30 mV 55ns pulse. The input of my system is the sum of each layer. Therefore in this example I would have 3 input signals. If there are two cells that detect something in the layer n.1, I would receive 60 mV in the input n.1. If there is 1 cell that detects something in the layer n.2, I would receive 30 mV in the input n.2 and so on.

    I need to check if there has been a detection in more than one layer at the same time. Therefore my final output can be a on/off signal.

    The way I thought of doing it is to use a comparator for each layer. If the layer 1 outputs 30 mV or more, its comparator will be on. Let's say I configure its output to give 0.5V if on. If the layer 2 has an output of 30mV or more, its comparator will be on too, so it will have another 0.5V. If I add the comparator outputs and I feed them to a last comparator with a Vref of 1 Volt, in case that two or more layers had detected something the last comparator will be ON, and therefore I will know that two or more layers had detected something at the same time...

    Sorry again for the long text! I repeated my self a bit, but maybe it is more clear now...

    If you have any recommendations for doing it in a more efficient way they will be welcome!

    What do you thing about doing the mV voltage reference with a voltage divider? Is there a more advanced/better way of doing it?

    Thanks again!:)
     
  4. Harald Kapp

    Harald Kapp Moderator Moderator

    11,444
    2,629
    Nov 17, 2011
    Your sequence of acquiring the signals is not well suited to the problem at hand. While it is possible to construct such a circuit, it may be much simpler to tackle the detection the other way round:

    You have 3 sensors (cells) which each is capable of outputting a 30mV / 55ns pulse, one for each layer. You can sum up the outputs of each sensor to a combined signal which is:
    0V if no sensor is active
    30mV if one sensor is active
    60mV if any two sensors are active
    90mV if all three sensors are active
    A summing amplifier using a fast operational amplifier can do this. It can also add gain, e.g. 50, so your output signal is 50*sum(sensor1+sensor2+sensor3). You will need a very fast amplifier because a pulse duration of 50ns is equivalent to 20 MHz.You can then compare the amplified sum signal to a reference of e.g. 2V using a standard comparator circuit. The isgnal of only one sensor is equivalent to 1.5V and will not trigger the comparator. The signal from 2 sensors is equivalent to 3V and will trigger the sensor.

    However, 50ns/20MHz is a challenge. In the analog domain, would it be possible to stretch the pulse to a longer duration, e.g. 500ns, by using a monostable multivibrator? Tht would depend on the minimum pause between pulses.

    You could also consider changing into the digital domain. Use a comparator for each sensor to create a clear digital 0/1 signal, 0 for no pulse, 1 for active pulse.
    You can then digitally test for the present of 2 simultaneous pulses by using a handfull of logic gates. A simple logic function is:
    Coincidence = (A and B) or (B and C) or (A and C) where A, B and C are the digital equivalents of the sensor outputs.

    In any case you will need something that registers the resulting output signal indicating coincidence because this signal will be only 50ns long, too,
     
    Last edited: Apr 1, 2014
  5. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    Thanks so much for the reply:

    I cannot elongate the pulses... if do that I would get a lot of false coincidences. If one sensor s1 detects something at time t1=0, and another sensor s2 detects something at t2=60ns I must not have a positive coincidence. Therefore I cannot make longer the pulses for my application. I must work with fast signals.

    Another thing is that the sensors do not work as you understood. I'll try using other terms:

    Each sensor has multiple cells. So just as an example (since I don't have the final numbers yet), lets say I have 3 independent sensors (I called them layers before), each sensor with 4 cells, and I need to know if at least two sensors had detected something at the same time.

    Each sensor can give an output of: 0 mV (no detection), 30 mV (1 cell), 60 mV, 90mV, or 120 mV(that means that the 4 cells of that sensor had detected something). And that for each sensor.

    Therefore, if I add all the outputs of the 3 sensors, and let's say I get a final result of 60 mV, I could not tell if two cells of one single sensor detected something or two different sensors detected something (one cell each). That is way I need a comparator or something with a threshold after each individual sensor... :)
     
  6. Arouse1973

    Arouse1973 Adam

    5,165
    1,087
    Dec 18, 2013
    Ok just do as Harald said but forget the gain at the front end and then add another summing stage. Then sum the outputs of each sensor into a suitable op-amp and add gain there if you need it.

    Adam
     
  7. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    Hi,

    Thanks for the reply Adam...

    I still don't see very clear the recommendation for the first stage, before summing anything.

    I thought of using comparators, but the first reply said it wasn't a good option. I will address the problem by parts, so the first part is this one:

    Let's talk about a single sensor. As I said before, this sensor can give 0 mV, 30mV, 60mV, 90mV and 120mV. I want to have an output of 0mV if the input is <20mV, and an output of -750 mV (NIM standard-15mA into 50 ohm for logic 1) if the input is >20mV.

    Do you recommend another approach than using a fast comparator with a 20mV reference?
     
  8. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,490
    2,832
    Jan 21, 2010
    So you don't care if each sensor outputs 30, 60, 90, or 120mV, just that two or more sensors are triggered simultaneously?

    If so, that says go to the digital domain and have an output that takes the sate of the majority of the inputs i.e. for 3 inputs, the output is asserted when two or more inputs are asserted.

    For this a comparator is fine. Yeah, you can use a 20mV reference, but it may be better to amplify the signal (by say 10 times) first so that it's 200mV, then compare it to a reference. You'll need a very fast op-amp (looking at 200MHz gain bandwidth at a minimum), or build this from discrete components.

    Following this you'll need a very fast comparator. The output of this can probably be sharpened up with some positive feedback, or you can use a schmitt trigger logic device.

    Then you need some logic which does the "majority" detection.

    The logic required is Q = A.B + B.C + C.A where Q is the output and A, B, and C are the inputs.
     
  9. Laplace

    Laplace

    1,252
    184
    Apr 4, 2010
    A peripheral consideration is the source impedance of the sensor signal along with the distance the 30mV pulse must travel to reach the comparator circuit. A wideband amplifier will lower the the signal impedance going into the comparator if it is too high. If the pulse travels more than a couple inches, then you may want to look at a coaxial transmission line.
     
  10. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,490
    2,832
    Jan 21, 2010
    Very good point. In fact it may be useful to buffer the output of the sensor as close as possible to the sensor itself. This will also help reduce noise.
     
  11. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    Thanks so much for the feedback to all you guys!

    About the cable, I'll use LEMO connectors and short cables, thanks for the note on that too.

    Steve, yes, as you said I don't care about the output level, I just care about the coincidences between different sensors, so the system has to work as you said.

    I will try with and without amplification. I want to simplify the design, with fast signals, the more components more options for problems.

    I've seen that the output of the sensors can have a 30mV offset, so I measured the real output and then, when there is no signal you get 30mV, then with 1 cell 75mV, 2 cells 90mV... so at least the signal is a bit higher than in the initial specs.

    Anyway, the idle 30mV has a +-10mV noise, which means that 40mV is still No detection, whilst the 75mV(1 cell has detected something) has again a +-10mV of noise.

    Therefore the new reference voltage should be around 60mV, and VERY stable!... and probably a schmitt trigger comparator as Steve said... I've never worked with fast pulses before... let's see what comes out!

    Do you think that this approach will work? (no amplification and relaying on a very stable Vref) or realistically I should add amplification and a schmitt trigger?

    Well... when I run the first tests I will find the real problems :)

    Thanks so much!
     
  12. Laplace

    Laplace

    1,252
    184
    Apr 4, 2010
    I really don't understand how a Schmitt trigger will be useful here. The Schmitt triggers that I'm familiar with operate as a comparator with positive feedback at logic-level low-frequency signal voltage and where the comparator reference voltage is not tightly specified. It would seem more useful to add a small amount of positive feedback to the comparator instead. With 10mV of input noise, try adding 11mV of positive feedback. Also, using a band-gap voltage reference with a voltage divider should give a stable enough 60mV comparator reference voltage.
     
  13. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    Thanks a lot... The bandgap voltage reference is helpful. I knew Vref ICs but I didn't know how they work and usually the lowest referece is around 2.4V... so the 1.22V is definetely better...

    ...I have to read about adding 11mV of positive feedback to a comparator... I don't get the point very much... (not much experience here!)... then I'll understand what you get doing that! :)

    Thanks!
     
  14. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,490
    2,832
    Jan 21, 2010
    It would be useful to square up the output of the comparator and to ensure you have good logic levels before doing the "majority" detection in logic.

    Of course an adder and another comparator (after the initial 3 comparators) could be used to keep it all analog.
     
  15. Laplace

    Laplace

    1,252
    184
    Apr 4, 2010
    While I won't claim to have much actual experience using comparators, I thought that they were supposed to have digital outputs or at least an open collector from which you could design an output stage that had good logic levels. Also with their high gain and high switching speed the output is very square, especially so with a small amount of positive feedback. I might connect the output from an op-amp into a Schmitt trigger, but never from a comparator. Does experience recommend otherwise?
     
  16. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,271
    Nov 28, 2011
    Comparator outputs can be clean, yes, but without hysteresis, a noisy input can cause multiple transitions on the output as it passes through the comparison voltage.

    A comparator with [a small amount of] positive feedback = a comparator with hysteresis = a Schmitt trigger.
     
  17. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,490
    2,832
    Jan 21, 2010
    A potential issue for the comparator is that the output will be slew rate limited. A Schmitt trigger inverter before the logic (should you use logic) will square up the output further and ensure you have correct logic levels.

    But sure, some positive feedback on the comparators would also be needed for very low level signals if they have significant noise or if the input signal is relatively slow in rising (relative to the noise frequencies).

    In this particular case, additional transitions as the signals go through the threshold are probably not going to cause problems as long as that noise can't generate a transition from a no-signal (or wrong-signal) state.
     
  18. beethovenj

    beethovenj

    7
    0
    Apr 1, 2014
    This is a screen shot of the oscilloscope:

    Those are my inputs (from one sensor)

    Would you still recommend a Schmitt trigger?
     

    Attached Files:

Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-