Hysteresis on Buffered Comparator Input Signal

Discussion in 'The Projects Forum' started by OdysseusWorm, May 28, 2013.

  1. OdysseusWorm

    Thread Starter New Member

    May 28, 2013
    2
    0
    Hello, thanks for taking the time to read this.
    I am a newb and could use a tip if someone's already figured this out or knows a better way.
    I'd like to use an RC timer to switch a relay. I need hysteresis to prevent short cycling, but I can't have the hysteresis charging the cap back up. I ran the cap voltage through a buffer to protect it, which behaves perfectly at node 'a'. (besides the short cycling without hysteresis, the circuit does the right thing if node a is shorted to node c - straight comparison).
    The comparator op-amp also behaves correctly at node b.

    My problem is that is seems like the comparator input signal dons crazy-pants in the hysteresis pot (tho I made it a very large resistance to keep the op amps from 'fighting' each other). Erratic as heck, doesn't sink down all the way....

    Any ideas smarter than mine?
    Is there a clever way to put the hysteresis on the threshold pin instead?


    -the cap on the 'threshold' voltage is because I had the 12v supply rail switched by the relay coil itself (latches in running mode) and i didn't want the threshold voltage going nutso when the comparison resulted in killing 12 v. Just for debugging, I've got the 12v supply permanent to eliminate that cause.
    -I'm using LM324 quad op-amp for buffer and comparator, though I tried using a 311P comparator (buffered output) instead with same result.

    thanks very much for any tips, sorry if there's already a well-known solution.
     
  2. OdysseusWorm

    Thread Starter New Member

    May 28, 2013
    2
    0
    I read the material regarding op amps, comparators, and the schmitt trigger on this awesome website called allaboutcircuits, and found the answer.
    I didn't understand the feedback, which is what I was seeing destabilizing the circuit (you should've heard that poor little relay :).

    By leading the input signal to the inverted input and the hysteresis arrangement to the non-inverting input, the amplifier stabilized due to positive feedback, and the high output controllably bumped the threshold on the non-inverting input (thereby immediately saving the comparison from noise).
    Since the schmitt trigger now output a High when I needed a Low for the relay, i just inverted it at an unused channel of the 324 op amp.
    Maybe not elegant, but functional. :D
    I could even use the relay to kill the 12 v supply without causing another feedback issue (cause the relay is mechanically slow enough)! - I didn't like the drain on my truck battery.

    The fixed circuit is attached.
    - hope this helps some other newb like me.

    P.S: read the website.
     
Loading...