HELP with function generator using IC 555 timer!

praondevou

Joined Jul 9, 2011
2,942
the common of S1 to the inverting input of U2C.....
That's the problem. Put a resistor in series with the switches common and recalculate U2C feedback resistor or subtract the resistor's value from each of the 2.7k, 7.5k and 9.1k resistors connected to the switch. I tried it with 1k and it works.
Of course, 1k will give you 1.7k, 6.5k and 8.1k at the inputs, so try to find some values that you are comfortable with.
It's not a problem of the circuit itself but one of the simualtion software.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
Thank you a lot, it worked using the 1k resistor as you said. I was having this timestep problem more than a week now and i knew it was the simulation i just didnt know how.

If i want to get all the waves to a +/-5V pk to pk can i do that using U2C or should i use another amplifier after U2C?

Right now the triangular wave is at +/-2.5V
the square is at +/- 2.4 V
the sine is at +/- 2/8V
 

praondevou

Joined Jul 9, 2011
2,942
R10 = 5k96
R8 = 2k11
gives you 5V at the U2C output if you use the 1k on switch output.

Use potentiometers or the nearest values available.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
I am still trying to get all the waveforms to a +5/-5V output.
I tried changing the gain of U2C by changing the feedback resistor to increase the output but i am getting a problem where the positive peak of the sine and triangle waves level off at 3V.
Sine problem.png

This is the circuit, it is a bit modified from the last.
gain problem.png

The resistors R5 to R17 can be replaced by a pot, it is there to change the frequency, i just put the exact values for simulation purposes to see the distortion at the output for higher frequencies.

Help please, i do not know how to raise the gain of the waveforms to a +5V/-5V

View attachment BILL design mod4.zip
 

praondevou

Joined Jul 9, 2011
2,942
Sorry about the wrong resistor values. I read 5V total...

Your virtual ground is at 4.5V. I guess the simulation uses a voltage difference of 1.5V between the rails and the output signal. (max output voltage swing)

If you increase your V1 it should be ok. For +-5V you will need more than 13V for V1 if you continue to use the LM324.
Then you play around with the gain resistors of U2C.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
Yea, actually earlier today i increased it to 15V and i got the +/-5V at the output..just had to change some resistor values. The thing is that the 15V adds cost to the circuit as i will need a power supply addition.

So for now the 9V battery is good, once i breadboard it i will know how long the battery lasts for.

I have a question pertaining to the virtual ground though. In breadboarding the circuit i can connect it just as in the multisim schematic and it should work.

But after breadboarding the circuit has to go through Ultiboard to design a PCB.
The question i have here is that when transferring the circuit to ultiboard, the software gives a message that there is a large number (49 i believe) of virtual components that cannot be converted. Is this related to the components connected to the virtual ground?
 

praondevou

Joined Jul 9, 2011
2,942
Yea, actually earlier today i increased it to 15V and i got the +/-5V at the output..just had to change some resistor values. The thing is that the 15V adds cost to the circuit as i will need a power supply addition.
You could use an IC like the LT1054. it creates a negative voltage from a positive voltage. Came to my mind because I had it at hand, there are other ICs doing the same thing. You will need the IC plus 2 additional capacitors and you'll have about -9V from +9V input. Adds cost too, though.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
In breadboarding this circuit, the oscilloscope should be grounded at the output of U2D ( the virtual ground) or the actual ground of the circuit?
 

SgtWookie

Joined Jul 17, 2007
22,221
It depends upon what you're measuring. For most of the measurements, you should be referenced to the virtual ground (U2D out). However, keep in mind that your power supply will need to be isolated from earth ground; if it isn't, then connecting your O'scope probe to the virtual ground would short the output of U2d to the supply actual ground via the building wiring.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
Physically speaking, if i am using the power supply to test the circuit (instead of the 9V battery) what do you mean by isolating it from earth ground. All my earth grounds are connected to the -ve power supply.
 

praondevou

Joined Jul 9, 2011
2,942
Physically speaking, if i am using the power supply to test the circuit (instead of the 9V battery) what do you mean by isolating it from earth ground. All my earth grounds are connected to the -ve power supply.
I think what Sgt meant by "earth ground" is the buildings ground.

Oscilloscopes probe GND connection (the outer ring of the BNC connector) is usually connected to the buildings earth ground (inside the scope). So unless u have an isolated scope you need to keep this in mind.

If the output of your power supply is somehow referenced to the buildings ground (if it's a work bench power supply, it shouldn't), e.g. the output's minus is connected to building's ground, then connecting this to minus of your circuit and then the scope's probe ground to virtual ground of your circuit will short minus to virtual gnd, right?...

Confusing? :)
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
I understand the part where it would short the virtual ground to the building.

Pertaining to the power supply. It is a workbench power supply. I will ask tomorrow whether it is referenced to the buildings ground.

For the scope. If this is plugged into building it would be connected to the buildings earth ground right.

So if the power supply is not referenced to the buildings ground and the scope is connected to the buildings earth ground then...connecting the -ve of the power supply to the minus of my circuit and connecting the scope GND to the virtual ground should be right not so?

If the power supply is referenced to the buildings ground however, how can it be isolated??
Or how can i knw whether the scope is isolated or not?
The part i dont get is how a scope or power supply can be isolated.
 

praondevou

Joined Jul 9, 2011
2,942
So if the power supply is not referenced to the buildings ground and the scope is connected to the buildings earth ground then...connecting the -ve of the power supply to the minus of my circuit and connecting the scope GND to the virtual ground should be right not so?
Yes

If the power supply is referenced to the buildings ground however, how can it be isolated??
Or how can i knw whether the scope is isolated or not?
The part i dont get is how a scope or power supply can be isolated.
The low voltage workbench power supply outputs I work/worked with are all isolated from buildings earth connection. They have however a ground connection at the front, which I normally don't use. It wouldn't be very clever to have a laboratory DC power supply where it's "-" output is connected to buildings ground. If you post your power supply model, I'm sure we can tell you.

An oscilloscope can have galvanically isolated channels or it can be battery powered. Then it's probe inputs are isolated from buildings ground.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
Well i am using the 9V battery to test the circuit instead of the power supply now. So the source is isolated. As for the oscilloscope i believe it is connected to the buildings ground.
The output waveforms are good, its just that right now all the waveforms are not at the same amplitude.
I believe that is due to some of the resistors i had to use, which were not exactly equal to the multisim value.
Tomorrow i am going to try to use POTs to get a close enough value to some of the resistors i have in the multisim design.
 

Thread Starter

Narrin

Joined Oct 2, 2011
47
I am having a problem with the squarewave output from the 555 IC.
The square wave does not have a purely 50% duty cycle, probably a little higher. It also has a dc offset of around 0.4V
I am actually not using the CMOS 555 at the moment but tomorrow i will use them and see if it makes a difference. I wanted to know if adding capacitors at the control pins of the IC's will make any difference or what could really rectify the duty cycle and the offset.
 
Top