I am conditioning the input of a slowly drifting analog input sensor.

The sensor is a phototransistor that will sink a small amount of current when "dark" and 50x more current when "bright," but the ambient brightness will vary, so a pre-set "trigger threshold" is not good enough.

Based on this I have an incoming voltage with source impedance < 10 kOhm. I want to detect when the voltage falls "quickly" to less than half what it was before, within reasonable range for "previous" value (say, 1-2.5 Volts with 3.3V supply.) Let's say that a typical value of "quickly" is "10 millisecond fall time."

Would an opamp with a RC filter on the negative input, and a moderate feedback resistor to avoid overdriving it, plus a Schmidt trigger for conditioning the output, work alright? See the schematic in the picture.

(Note that the calculated corner frequency for the filter assumes a 0 Ohm source impedance, and the corner frequency will go down if source impedance is higher, which would be fine by me!)

enter image description here

  • \$\begingroup\$ (Assume the opamp has < 1 pF input capacitance and > 20 MOhm input resistance, e g doesn't affect the circuit enough to matter.) \$\endgroup\$ – Jon Watte Jun 13 at 5:18
  • 1
    \$\begingroup\$ What if you just DC block the output and feed it to a properly thresholded comparator? If the signal changes too slow, it will never be able to generate an AC negative edge fast enough to fall low enough to trigger the comparator. In essence, high-pass filter it. \$\endgroup\$ – DKNguyen Jun 13 at 5:23

The circuit you show is also called a "data slicer" and is used effectively in extracting data from the output of an FM demodulated signal used by several not-so-cheap 434 MHz RF transceiver circuits you see quite often.

enter image description here

Yours is a variation but probably doesn't need R102 because R101 will perform that function as far as I can tell but there's no harm including it I guess. I'd try it as shown above or one of the many variations I have linked. Simulation is your big friend here.

  • \$\begingroup\$ Thanks for the answer! My thinking for R102 is twofold: To set the threshold at "half the prevailing input," (for auto-gain) and to provide the bottom half of the gain feedback network with R103. The extra current through R103 puts the voltage across R102 higher than R101, but that's OK as that partially compensates for the source impedance of the input signal. As I keep asking myself everyday: What are the holes in that thinking? :-) \$\endgroup\$ – Jon Watte Jun 13 at 20:59
  • \$\begingroup\$ With my circuit and a little hysteresis, I think you’ll get a smoother and more reliable result but, why not use a sim and try out all the scenarios. Go on, bite the bullet! But only you know the precise nature of what you need and some of those subtleties are not easily passed on through the question maybe. \$\endgroup\$ – Andy aka Jun 13 at 21:04
  • \$\begingroup\$ What would provide the hysteresis in the circuit you show, to achieve "and a little hysteresis?" \$\endgroup\$ – Jon Watte Jun 15 at 18:39
  • \$\begingroup\$ You would need an extra two resistors as per the normal method around a comparator. \$\endgroup\$ – Andy aka Jun 15 at 19:30
  • 1
    \$\begingroup\$ R102 controls the negative feedback - hysteresis is positive feedback and a comparator data slicer would not use it because the hysteresis components will set the upper and lower thresholds for the switching. \$\endgroup\$ – Andy aka Jun 18 at 7:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.