Introduction: Low Cost Waveform Generator (0 - 20MHz)

ABSTRATH
This Project comes from the necessity of getting a wave generator with a bandwidth over 10 Mhz and an harmonic distortion under 1%, all of this with a low cost price.
This document describes a design of a wave generator with a bandwidth over 10MHz , which produce:  sine, triangle, sawtooth, or square (pulse) waveforms with an harmonic distortion under 1%, duty-cycle adjustment, frequency modulation, TTL output and offset voltage. It is also presented the design of a frequency counter.


Step 1: Parts List

This is the main parts list.
The main part, MAX 038 is a discontinued part, but it still can be bought .

It is attached  an approximate budget.

Step 2: PCB Made

Make Ready the PCB for the serigraph.

It is double faced PCB. The chosen process is a chemical one, so the first thing we have to do is the serigraph of the layout with a laser machine, and after the chemical process.



Firstly, we begin  with the layouts in JPG format, due to it is a double faced PCB, we will have to turn over the PCB to do the serigraph by both sides, because we are going to use a laser machine. for this reason the PCB must have exactly  the  same size than the layout or at least one of the sizes,( depending on the direction in which we turn over the PCB).
After cutting  the PCB with the exactly measurements ( it is also possible to adjust the layout at the PCB ) the PCB is painted with black acrylic spray paint. ( it must be painted at least one day before)
The PCB must be placed at the left top corner, ( the 0,0 point of the machine must be exactly at this point) because when we turn over the PCB, it has to be exactly in the same place in order to make the holes coincide.

The layout dimensions are: 207,5mm  X 52 mm.

Step 3: PCB Made (Serigraph)

Serigraph.

The laser .machine will eliminate the paint in the parts where it is necessary that the acid attacks.

The laser machine parameters for this process are:
Speed 60. Power 30. Resolution points 1200, mood Raster.
We need to do the process twice in both sides of the PCB, in order to remove the paint correctly.

Step 4: PCB Made (paint Traces Removing)

Paint traces removing.

After the previous process, there are still traces of paint and they must be removed before the acid process , but after taking out the PCB from the laser machine we have  to wait at least one hours in order to get dry.  For this purpose we use a soft solvent such as turpentine or a substitute substance.

 
Once we have cleaned the PCB, it has to appear like the one of the picture

Step 5: PCB Made (acid Attack)

Acid attack

For this process we need the acid and another product in order to start the reaction and doing the process faster.

The necessary for this process  can be bought in an electronic shop. In general, the used acid is hydrochloric acid plus water, sold in supermarkets like a cleaner product (muriatic acid). Bigger the concentration faster will be the process. Apart from  the acid we need, as we said before, an accelerator product. The best one is sodium perborate sold in electronics shops and in supermarkets like a product to whiten  clothes ( at least in Spain), another product is oxygen water, but it  needs  a high level of concentration.

Step 6: PCB Made (rest Paint Removing)

Rest paint removing


After the acid process we remove the rest of the paint, using a strong solvent.

Step 7: Waveform Generator Schematic



Step 8: Waveform Generator Assembling. 1

Firstly we have to drill the PCB and we start to solder the components. We have to pay attention to the fact that it is a double faced PCB, so it has vias to connect both sides and most of the components are soldered by both sides in this circuit. We can see this in the pictures.

The emplacement of the components it is like the pictures show.

The resistors of 100K, the chip 1 (operational amplifier), the capacitors associated to  the chip 1 and the potentiometer of 220K, constitute the adjustment of the duty cycle , useful just to incline the wave. This circuit can generate  some distortion, for that it is usually commuted to the ground through the switch SW3.(type switch ON-ON). If we do not use this we can eliminate it, remembering to connect it to ground.

Step 9: Waveform Generator Assembling. 2

The capacitor of 1uF is not polarised, (see circuit explanation 3.2.1).
The connector of the range selection is connected to a rotary switch, in which the pin of the connector attached to the resistor 4K7 is connected to the common pin  (A) of the switch . This rotary switch is set for four switches, leaving one free ( high frequency selection, 27pF).
As it is commented in the circuit explanation, the parasite capacity can limit the bandwidth. In this design there are parasite capacities due to the use of transistors to the commutation of the capacitors, so the maximum frequency reached is 10MHz, but if we want to exceed this limit it is just  necessary to disconnect the  27pF capacitor or using a smaller one getting a bandwidth over 20MHz.




The other connector is to type waveform selection. We have to set the rotary switch to 3 switching The 5V pin is connected to the common pin of the rotary switch  (A) and A0 and A1 to the pins 1 and 2 , leaving the pin 3 free.

The MAX038 is an unlisted component, but it is possible buying it. It is not recommended buying it in China because although it is cheaper it does not work.

Step 10: Waveform Generator Assembling. 3

The BNC connector  is for the TTL output.
The bridges p1 and p2 replace the 47 ohms resistors, because the BNC connector has this impedance implemented.
The positive pin of the  electrolytic capacitor are connected in the squared footprint. They are placed according to the picture.
The potentiometer of 1K is for controlling the output level of the waveform.
The blue potentiometer of 4k7 controls  the gain , in order to chose the max output level.

Step 11: Waveform Generator Assembling. 4

The switch SW5 commutes the offset  voltage to Zero.
The potentiometer 4K7 is use to change the offset voltage.
The bridge p3 and the hole that is above  and an operational  amplifier work like a circuit follower , in order to send the signal to the frequency counter.

Step 12: Waveform Generator Assembling. 5

In this picture we can see the correct placement of the operational amplifiers.

Step 13: Power Supply Schematic

Step 14: Power Supply Assembling 1

The layout have the dimensions of : 63,4 mm X  7,9 mm.

Step 15: Power Supply Assembling 2

The components are placed like we can see in the picture.

Step 16: Power Supply Assembling 3

The unmarked wires supply voltage to a diode led, in order to know when the generator is turned on.

Step 17: Structure Box

The structure is made in plywood piece of wood of 5mm.
The design has been make with the program Rhinoceros by Zoe Carbajo.
It is mede with a laser machine. 

It is necessary to add  tolerances in the design, in order to do that the different parts join perfectly. It will depend of the material.

It has been attached a piece of adhesive aluminium paper ( usually used in plumbing)  in order to connect to ground, the metallic parts of the potentiometers and the switches. Thos ground is joined to the aluminium paper through the FM input BNC connector.

Step 18: PCB and Structure Box Assembling 1

It has been attached a piece of adhesive aluminium paper ( usually used in plumbing)  in order to connect to ground, the metallic parts of the potentiometers and the switches. Thos ground is joined to the aluminium paper through the FM input BNC connector.

Step 19: PCB and Structure Box Assembling 2

In the following we can see the place of the transformer, a connector for the supply wire and a switch. These two last components have been obtained from a power supply of a computer.

The two pins of  0V from the secondary of the transformer, must be joined, because our supply requires a middle power point. These go connected to the ground (middle pin of the connector)
The ground of the wire supply must be connected to the ground of the power supply as well

Step 20: Waveform Finished and Working

Comments

author
bmutlugil (author)2015-08-13

Hi,

Where can the MAX038 chip be bought, I can not buy a working one..

author
Armandx (author)bmutlugil2016-02-26

Ebay

author
swander (author)2013-11-04

Very cool. Is there a way to output this to a PC so as to use its display? CRT's are getting a little scarce in small sizes. Maybe mic jack? That obsolete IC can still be had for about $21 US.

author
Carlosrhrh (author)swander2013-11-04

If you need Know the frequency, I will try to upload a frequency counter as soon as possible.

author
nuninu (author)Carlosrhrh2015-04-08

I like your design and I'm building this project.
Could you upload a schematic of a frequency counter?

author
jmrt (author)2014-09-16

i checked the voltage on the vref it is still in the negative range. can you help me what is the problem?

author
Carlosrhrh (author)jmrt2014-09-17

i think that you must check first that the chip work correctly, because i bought 11 chips, and only worked one. (10 from china and the good one in england).
You can test with an easy circuit, like it is showing in the chip pdf.
you dont have to use this pin, you can use a voltage divisor instead. (see the circuit explanations for farther infor

author
Carlosrhrh (author)2014-09-16

hello jmrt.

The pin1 (REF) of the chip MAX038 it is a positive voltage, and it is an output.

All the designe of this project is based on the MAX038 PDF.

http://datasheets.maximintegrated.com/en/ds/MAX038...

author
jmrt (author)2014-09-15

hello. we did this project and our supply V- = -5v and
V+ = +5v. but why does the input voltage in pin1 is in negative??:( Vref= -3.5v)

pls help us. this is for our project study.. thank you!! :)

author
robotmaker (author)2013-12-13

can asy make one much cheaper with a waveform generator ICL8038
IT GIVE SAWTOOTH,square,sine and other circuits can be added to easy,op amp circuits and more

author
Carlosrhrh (author)robotmaker2013-12-18

I know, but the MAX038 have a bandwidth of 20MHz or more, and the ICL8038 have only a bandwidth of 300KHz, so this is a low cost "high" waveform generator... :)

author
FabLabLeon (author)2013-11-07

Congrats!!

author
eltercerlugar (author)2013-11-06

Amazing job!!!!

author
MethewsEmbeddedSystems (author)2013-11-03

THANK YOU FOR THIS!
I just ordered the parts, this is an awesome design around an awesome chip !
I was looking around for a cheap and decent function generator for some time now and I don't have the time now to to deepen myself in making/designing a desent circuit for a diy function generator, but you did al the work for us !
You really helped me, thank you, its highly appreciated !

author

If you have some problem when you build it, only let me know and I will help you.

author
guds777 (author)2013-11-03

is it useful as a 220v 0-60 hz motor controller..

author
Carlosrhrh (author)guds7772013-11-04

It is not.

author
Edgar (author)2013-11-04

Nice!
Voted, and Blogged about it:
http://faz-voce-mesmo.blogspot.pt/2013/11/muahahaha-bolas-de-fogo-e.html

author
Edgar (author)2013-11-04

Nice! Like the Fabbing side of it, too. :)
Voted, and also Blogged about it, too useful to pass un-noticed:
http://faz-voce-mesmo.blogspot.pt/2013/11/muahahaha-bolas-de-fogo-e.html

author
Josehf Murchison (author)2013-11-04

I really like the box.

Good show.

Joe

author
pfred2 (author)2013-11-01

That is one expensive integrated circuit. I would hate to let the magic smoke out of that one!

author
Carlosrhrh (author)pfred22013-11-02

It is more expensive to buy a new one with this characteristics.
It cost to build about 100 euros.

author
hexidismal (author)Carlosrhrh2013-11-03

Good to know. The whole project is very interesting and an impressive end result. My only complaint about the article is that if you're going to hype something as 'low cost' right in the title, then saying how much it cost should be right in the project description. I went though every page of it trying to figure out exactly how 'low cost' is low cost'.. heh

author
Carlosrhrh (author)hexidismal2013-11-04

Hello. I already put a budget attached in the second step.

author
bben46 (author)hexidismal2013-11-04

Unfortunately, 'low cost' is a relative term. In this kind of thing, it's low compared to what a commercial product with similar specs would cost.. Look around the surplus market for that chip, you may get lucky and find one for a lot less.

author
Jakob2803 (author)hexidismal2013-11-03

Yeah the Max038 is obsolete now anyway like the XR2206, best not to make new designs using it.

author
SolidRaven (author)Carlosrhrh2013-11-03

That's not entirely true, it depends on which sort of performance you want. You could build a high-end 12 bit DDS version that would work quite well up to 10 MHz pretty cheaply using a low-end FPGA, DAC and a good output filter! Total cost would probably be somewhere around 30-40 Euro.

On the other hand, if you wish to go analog:
If you need a low distortion sine-wave oscillator nothing quite beats a Wien-bridge oscillator with a light-bulb is a good choice. For higher frequencies a Collpits-oscillator isn't a bad choice, but keeping it running over a wide frequency range of several octaves is problematic. But I should probably stop before I scare people away. :)

author
ajoyraman (author)2013-11-03

This is good work ! I am a fan of another obsolete part the Intersil 8038 which works well up-to 50 kHz. Unfortunately these analog IC's have disappeared.

author
aldente46 (author)2013-11-03

Thanks Carlosrhrh
I've had a MAX038 in my parts bin for many years waiting for me to get around to making it a project. Now that I've seen your efforts and your PCB artwork I have been inspired to finally go ahead with it. Aldente46

author
desmondtheredx (author)2013-11-02

I love it

author
Infinitevortex (author)2013-11-01

Awesome job! Looks very professional!

author

Thanks!