Showing posts with label Function Generator. Show all posts
Showing posts with label Function Generator. Show all posts

Wednesday, June 20, 2012

Versatile 200KHz Function Generator using ICL8038

ONE of the most useful facilities in the electronic experimenter’s workshop is an ability to generate a.c. test signals of various waveforms, frequencies and amplitudes. This is where this Function Generator project comes in, the “function” in the name referring to the waveform of its output signal. 

The Generator can be used for testing or driving many circuits, from below audio up to a couple of hundred kilohertz, and may even be used as a variable speed clock for logic circuit testing. It has sine, square and triangle-wave outputs plus a separate 0V to +5V squarewave output for logic driving. This may also be used with a “sync” input when, for example, inspecting low-level signals on an oscilloscope.

Circuit Detail:
The full circuit diagram is shown in Fig.1. Starting with the power supply, this is of the dual rail type. The very low output frequencies require d.c. coupling in the output circuit, which in turn makes a circuit using separate positive and negative supplies about a central 0V or ground much simpler to design.

Tuesday, August 17, 2010

OPAMP FUNCTION GENERATOR

Square, sine and triangle waves are produced using an LM348 and passive components. The LM348 is a quad operational amplifier IC package; that is, it contains four separate opamps all in the one IC. They are marked A, B, C & D in the schematic diagram.

Square Wave:
One opamp (LM348:D) is used. The voltage level to pin 13 is set by the resistor divider pair R1 and R2. The input to pin 12 depends on two things; firstly the potential of pin 14, and secondly, the voltage output of opamp C at pin 8. When the input at pin 13 is higher than the input at pin 12 the output goes low. If it is lower then the output goes high. Switching back and forth between the two states causes a square wave to be produced. The time constant (R4+R5)C2 determines the frequency.

Triangle Wave:
You can also consider that opamp D is set up as a bidirectional threshold detector with positive feedback provided by R3. R3 also gives hysteresis. The output provides a bias which tends to keep it in its existing state before allowing switching to take place. The inverting input is set up at about half the opamp output swing voltage by resistors R1 and R2. Accordingly the signal required from opamp C to cause switching is offset from this midpoint voltage by R11/(R11+R3) which is approximately2/3 the voltage from midpoint to swing limit and is symmetrical above and below the switching point.

Opamp C is set up as an integrator. It performs the mathematical operation of integration with respect to time. For a constant input the output is a constant multiplied by the elapsed time, that is, the output is a ramp. Since the input signal goes to the inverting input, a high input will produce a ramp down and a low input will produce a ramp up. The input signal is a square wave symmetrical about the midpoint potential. The current this potential produces through R4 and R5 is constant so the up and down ramps are of equal gradient and the resultant triangular wave is symmetrical. Any increase in the trimpot R5 reduces the current and the integration constant which lowers the gradient of the ramp. The switching levels havenot changed so the frequency reduces while the amplitude remains constant. In a similar way the current depends on the value of integration capacitor. Accordingly the integration constant and hence the frequency vary with the value of the capacitor. (Higher value, lower frequency since the capacitor takes longer to charge.) If C2, for example, is increased to say 680nF then the minimum frequency will be less than 1Hz. The output triangle wave does not require amplification but it does require buffering so that that loading does not affect the waveform generator circuit. It is buffered here with opamp A connected as a unity gain buffer. Unity gain is achieved by directly coupling back the output to the inverting input.

Sine Wave:
A pseudo or imitation sine wave is produced by a wave shaping circuit. A diode is a non-linear device. As the potential difference across it increases the current rises in the characteristic way published in all textbooks. This circuit 'joins together' this characteristic curve to produce an approximation to a sine wave. Two diodes have been joined together as a series pair in order to provide a higher amplitude than would be obtained using only a single diode. The shape of the pseudo sine wave could be improved at any particular frequency by filtering, but filtering will cause distortion at lower frequencies and loss of amplitude at higher frequencies. You can have perfect sine waves at particular frequencies by switching in appropriate filters at those frequencies. 

The sine wave is sensitive to loading and must be buffered. It is also low in amplitude and needs amplification. R9 & R10 set the gain of opamp B by forming a voltage divider between the source and the output. If the wave shaper voltage is 1 volt higher than the reference (at the non-inverting input) the opamp reduces the output voltage until the inverting input voltage set by the divider is equal to the non-inverting voltage. The ratio of the values of R10 to R9 give the gain. The gain here is about 2.

Schematic:


Final Assembly:
 

Components Required:

R4,   560Ω  Resistor
R7,   820Ω  Resistor
R8,   1kΩ  Resistor
R11,   8.2kΩ  Resistor
R6,   10kΩ  Resistor
R3,   15kΩ  Resistor
R1,   82kΩ  Resistor
R2,   100kΩ  Resistor
R9,   470kΩ  Resistor
R10,   1MΩ  Resistor
R5,   1MΩ  variable Resistor
D1-D4,   1N4004 Diode
IC1,    lm348
C1-C2,  47n ceramic capacitor


Thursday, April 1, 2010

Function Generator

The FunGen Function Generator design utilises the Exar 2206 IC to produce Sine, Triangle and Square waves with adjustable frequency. Its features include:
Output Waveforms: TTL Square Wave and selectable Sine or Triangle Wave
Output Amplitude: Square Wave: TTL Output, Sine/Triangle: 0Vp-p to approximately 6Vp-p.
Output Frequency: 25Hz to over 250kHz 

The design includes a buffered virtual ground circuit provided by an LM741, LM318 or similar Op Amp, which sets a fixed voltage half way between the input voltage and ground. This is then used as the virtual ground for the sine and triangle wave outputs from the "WAVE_OUT" connector, providing an output centred around 0V.

A 74HC04 or 74LS04 Hex Inverter is used to buffer the Square Wave output, decreasing the rise and fall time of the square wave output.

The amplitude and frequency adjustment pots are mounted on the board for easy adjustment. An ON/OFF switch, Waveform selector switch and Frequency range switch are also mounted on the board.

Schematic:



Components Required:
IC1,   XR2206 
IC3,   LM741 or LM318 Op Amp
IC2,   74xx04 Hex Inverter
IC4,   LM7812
IC5,   LM78L05
C1,   100uF (or 10uF) Capacitor
C2,C5,C6,C7,C10,  1uF Capacitor
C3,C4,   0.1uF Capacitor
C8,   0.22uF Capacitor
C9,   2.2nF Capacitor
D1,   1N4001 Diode
R4,   200Ω 1% Resistor
R1,R5,R7,   1kΩ Resistor
R2,R3,R6,   10kΩ Resistor
R8,R9,   100 Ω Resistor (optional)
pot1, pot3,   50kΩ Pot
pot2,   250kΩ Pot
two Sliding Switches
3mm or 5mm LED
two,   Dual Screw Terminal