zero level detector

Discussion in 'The Projects Forum' started by kahafeez, Dec 19, 2008.

  1. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    hi people, i was trying to apply this zero level detector on a breadboard. the circuit is simple. has no comlications bt it didnt work. can some one point out the mistake??? the output was sort of same as the input.... i didnt use any resistors....
     
    • prob.JPG
      prob.JPG
      File size:
      37.3 KB
      Views:
      122
  2. leftyretro

    Active Member

    Nov 25, 2008
    394
    2
    How were you measuring the output voltage? If you were using a scope be sure it's set for DC coupling or you will lose the ground reference.

    Lefty
     
  3. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    well i was using as a scope...... what is DC coupling..... i've no idea.... plz explain...
     
  4. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    You indicate that your input is +1v to 1v. That would be a straight DC level.

    Did you mean that your input is a +1v/-1v square wave?

    You have the inverting input grounded, and you also have the -V supply grounded. If you're actually trying to determine the zero crossing, you should have a -v supply.

    If your +V supply is 5v, the most you'll see out of the LM358 is +3.5v.

    You're running the opamp in open-loop mode. This is hard on the output, because it's operating in constant saturation, which creates heat and wastes power. You should consider using a comparator instead. Comparators are designed to be operated in open-loop mode.
     
  5. leftyretro

    Active Member

    Nov 25, 2008
    394
    2
    Many scopes have a switch that selects DC or AC coupling of the signal from the scope probe. If in the AC coupling mode then the input signal is passed through a capacitor inside the scope, and that lose the common reference voltage used by the circuit being measured. You need to use DC coupling to measure the output of that op amp.

    Lefty
     
  6. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    You are using a single supply and the input signal goes below 0V. This may destroy the op amp or cause latch up problems. You need to use a dual supply (positive-ground-negative) to make a zero crossing detector. Also, the LM358 is not designed to work as a comparator. It will work but with not very high frequencies due to low slew rate. You can use an op amp designed as a comparator, which is not internally compensated, for better results.
     
  7. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    yes its a square wave....

    i wanted a 0V lo and 5V hi square wave output of my input.... thats y the supply is 3.5V and gnd.....

    so what do i do to make it a close loop. i think i'll introduce a gain in the ouput. can u plz suggest me a schematic that gives 5V if input is above 0V and 0V when signal is below 0V
     
  8. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    plz suggest me a comparator that works for me....
     
  9. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    You said your input signal is between 0V and 5V, why you want 0V on the output when the input is less than 0V? Can you be more clear on what will you like to do?
     
  10. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    See the attached.
    [eta]
    I used a sinewave input to more clearly show when the output of the comparator toggled.

    The inverting input is held at ground reference. The noninverting input gets the sinewave input.

    R1 serves as a pull-up resistor for when the LM339's output is not conducting; as it is an open-collector circuit.

    R2 limits the current from the Zener through the comparator's output when it's conducting. Without the 5.1v Zener and R2, the output would fall to the negative rail. You could also use a 4.7v Zener.
     
    Last edited: Dec 19, 2008
  11. Audioguru

    New Member

    Dec 20, 2007
    9,411
    896
    Look at the datasheet for the LM358. Its max allowed negative input voltage is only 0.3V. If you didn't destroy it with -1V or -5V then it will be destroyed soon.

    The supply is 5V so the max output voltage of the LM358 without a load is +3.8V.
    It doesn't have any negative feedback so its gain is about 100,000.
     
  12. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    actually my requirement was shaping a wave.....

    see the attached image for explanation.....


    i used PLL for FSK demodulation.... now i need to give this wave to the 89c51.... so i wanted to shape it according to the input the 89c51 needed.... thats a 0V lo and 5V hi square wave.... the datarate is set equal for both the transmitter and receiver 89c51
     
    • req.JPG
      req.JPG
      File size:
      23.1 KB
      Views:
      46
  13. eblc1388

    Senior Member

    Nov 28, 2008
    1,542
    102
    You can use the following circuit for your signal conditioning purposes.

    [​IMG]

    You can save a hell lot of posts if you have said what you wanted in the first post.
     
  14. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    thanks eblc and evryone....

    lolz abt the comment..... here the Vcc is +5V right ????


    listen i also want to invert(180 degree phase shift) a square wave coming from an 89c51.... i can do this using a bjt bt my design requires split supply of +5 and -5V .... can u plz suggest me how to do this using a single supply opamp .... preferably with a 5V supply .... the datarate is 4.8kbps.... thanks people...
     
  15. eblc1388

    Senior Member

    Nov 28, 2008
    1,542
    102
    Yes. The "5" next to the voltage source means 5V.

    If by this time in your study you cannot invert a 0~5V square wave using just +5V and a NPN bjt, then I think you will be in serious trouble because this is one of the most basic skill in electronic.:eek:

    You don't even need to use an opamp. It can be built with just a single NPN and a few resistors.
     
  16. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    dude i'm nt that good at it .... though i've finished my degree n m doin my project .... bt i know i suck at electronics.... anyways m trying to learn after finishing my degree ....

    n i told u i made a bjt amp which automatically inverts the wave.... bt the bjt needs a +5 and a -5V supply n i need to cut it down to just one supply(preferably 5V) and ground....
     
  17. Audioguru

    New Member

    Dec 20, 2007
    9,411
    896
    The circuit does not have a negative supply. It has a single +5V supply that has its 0V terminal connected to the circuit's ground.
     
  18. kahafeez

    Thread Starter Active Member

    Dec 2, 2008
    150
    0
    O God this is so depressing..... yup u r rite n i suck at this .... :(
     
Loading...