Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Square wave oscillator

  1. Nov 20, 2008 #1
    1. The problem statement, all variables and given/known data

    The assignment is to create a square wave oscillator using an op-amp in Multisim. The wave's frequency should be 1 kHz and the duty cycle 60%.

    2. Relevant equations

    f = 1 / (R*C)
    R1 < R
    R1 < Rf

    I guess.

    3. The attempt at a solution

    Here's what I've done:

    http://img156.imageshack.us/img156/8494/sqwavegenaj6.png [Broken]

    (It's such a basic textbook example.) I don't know why the wave form looks like that. The problem is those unnecessary "bumps" that should be flat:

    http://img403.imageshack.us/img403/4951/osczh4.png [Broken]

    Am I doing something wrong (very probable) or what?
    Last edited by a moderator: May 3, 2017
  2. jcsd
  3. Nov 20, 2008 #2
    just had a look, you may want to think about where you are placing the Cap in your circuit, what purpose does in play on the output from the signal Gen. Also, Placing a 10 Volt signal injection into a 5v Op amp will drive the output to Saturation? think about what is the appropiate signal input.
  4. Nov 21, 2008 #3
    So the input signal should be 5V? And I even tried removing the capacitor, but it didn't seem to have any effect in the output signal.

    I would really appreciate it if someone could even show me the right direction to go from here.
  5. Nov 21, 2008 #4
    Well at the moment, The cap where it is now, looks like its acting as a DC filter, Redesign the circuit so the cap works as a reservoir so it store an amount of charge to effect the output, this hopefully will give you your 40:60 Duty cycle. It does work, although its very limited on how far you can push the duty cycle limits. I used a version of crocclips to simulate the circuit.
  6. Nov 23, 2008 #5
    I just don't get it. Every website that tells about square wave generators have these kind of pictures:

    Where's the input signal? I even tried this but:
    http://img117.imageshack.us/img117/4063/oscqp1.png [Broken]

    Attached Files:

    Last edited by a moderator: May 3, 2017
  7. Nov 24, 2008 #6
    well its almost there, Have a look at the Op Amp inputs, the polarity is different on your design, and the input is in the wrong place. Try in parallel with the cap.
  8. Nov 25, 2008 #7
    I finally got it! I removed the AC power source since this is an oscillator, not a square wave inverter. I changed the DC voltage to 15 V and added a -15 V source to the pin 4. Works perfectly. Thanks.
  9. Nov 27, 2008 #8
    cool. good to hear.
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook