4Mhz square wave generator

ZakWolf, Fri Feb 19 2016, 06:17AM

I CANNOT find anything. I dont know enough about logic ic's to find much of anything, Countless hours spent searching.

Goal:

Need a very stable 4Mhz square wave.

Feed crystal oscillator output into logic ic get square wave out... Does anyone know what chip i would beed to achieve that ? Would i need a buffer before? I plan on feeding the signal source into this Link2 intern to switch a MOSFET
Re: 4Mhz square wave generator
TwirlyWhirly555, Fri Feb 19 2016, 06:42AM

Nvm , you found the gate IC .

Should check links before I post : P
Re: 4Mhz square wave generator
Sulaiman, Fri Feb 19 2016, 07:16AM

why not use a crystal oscillator?
e.g. Link2
Re: 4Mhz square wave generator
ZakWolf, Fri Feb 19 2016, 07:39AM

Sulaiman wrote ...

why not use a crystal oscillator?
e.g. Link2

Thats what I want to do since I need the accuracy the crystal supplies. Maybe I dont fully know what that crystal you linked does... Do I supply a voltage and It generates 4MHz? Doesn't it need to be buffered before going into the gate drive Link2 or at least amplified ?
Re: 4Mhz square wave generator
Conundrum, Fri Feb 19 2016, 08:30AM

Use a high frequency sinewave oscillator and frequency multiply it with a nonlinear junction.
Re: 4Mhz square wave generator
Sulaiman, Fri Feb 19 2016, 09:00AM

The crystal oscillator that I linked to is a 3.3 v supply version, not a good choice to drive the gate driver ICs
a 5v squarewave output crystal oscillator is more suitable, e.g. Link2
Re: 4Mhz square wave generator
ZakWolf, Fri Feb 19 2016, 04:03PM

I was thinking something like this Link2 I read on sights people talking about "Integrated Crystal Oscillator Modules" I cannot find any...

Anyway this is a Voltage Controlled XO. I have no clue how to use this chip though.
Re: 4Mhz square wave generator
jdub1581hv, Fri Feb 19 2016, 04:15PM

again we are lloking at the same thing... I have a few 4.0mhz xtals.. but never used before..

Can anyone say how stable this might be?
Oscillator
Re: 4Mhz square wave generator
klugesmith, Fri Feb 19 2016, 06:11PM

jdub's circuit is for using a bare 2-terminal crystal (passive component). Change the crystal to change the frequency.
Sulaiman pointed to some crystal oscillator components, which are easier to use. Connect appropriate power voltage (3.3 or 5 volts) and get a corresponding logic signal out.
In both cases the frequency is fixed. Worst case frequency error of +/- 100 ppm (0.01%) is a pretty loose tolerance for crystal controlled oscillators.

Your 74LS624 is a voltage controlled oscillator chip. VCO, not VCXO. No crystal, and you can tune the frequency over a substantial range. How are you planning to measure the frequency, if you don't have an oscilloscope? You could divide it down into the audible range (e.g. with one CD4040 or CD4060) and listen with headphones or a small loudspeaker. Instrument-tuning apps on smartphones can convert a tone into a number. Or adapt an old auto service dwellmeter/tachometer, which I could send you for cost of postage.

It's time you learned more about logic IC's. Jump on in; they don't bite. Get a plug-in breadboard to play with -- apparently as popular now as they were decades ago. There are other forums to learn at.
Logic signal input/output compatibility can be checked by studying the DC specifications section of the data sheets. Before the Internet, people used to keep things called data books for that purpose. smile
Re: 4Mhz square wave generator
ZakWolf, Fri Feb 19 2016, 07:07PM

klugesmith wrote ...

jdub's circuit is for using a bare 2-terminal crystal (passive component). Change the crystal to change the frequency.
Sulaiman pointed to some crystal oscillator components, which are easier to use. Connect appropriate power voltage (3.3 or 5 volts) and get a corresponding logic signal out.
In both cases the frequency is fixed. Worst case frequency error of +/- 100 ppm (0.01%) is a pretty loose tolerance for crystal controlled oscillators.

Your 74LS624 is a voltage controlled oscillator chip. VCO, not VCXO. No crystal, and you can tune the frequency over a substantial range. How are you planning to measure the frequency, if you don't have an oscilloscope? You could divide it down into the audible range (e.g. with one CD4040 or CD4060) and listen with headphones or a small loudspeaker. Instrument-tuning apps on smartphones can convert a tone into a number. Or adapt an old auto service dwellmeter/tachometer, which I could send you for cost of postage.

It's time you learned more about logic IC's. Jump on in; they don't bite. Get a plug-in breadboard to play with -- apparently as popular now as they were decades ago. There are other forums to learn at.
Logic signal input/output compatibility can be checked by studying the DC specifications section of the data sheets. Before the Internet, people used to keep things called data books for that purpose. smile


Man this place has really gone down hill and you are a perfect example. Frist of all I do own a scope! secondly, I am over my head and I dont know very much about any of this class e RF amps but thats how you learn new things and this is a place to ask quesions. Im challanging myself and come here for support and this is what I get "Get a plug-in breadboard to play with -- apparently as popular now as they were decades ago. There are other forums to learn at." are you kidding me ?!?!

I have looked at the data sheets for the provided schematics and I have been doing a ton of research but I am by know means an expert.

Re: 4Mhz square wave generator
Sulaiman, Fri Feb 19 2016, 08:01PM

I'm not sure exactly what you are constructing
but with Class-E (or any resonant circuits) if you fix your clock frequency
then every other frequency dependant circuit will need to be tuned to the clock.
It will be easier if you have a variable frequency clock
which would allow 'tuning' by varying the clock frequency rather than adjusting capacitance or inductance
at least for one tuned circuit.

I also doubt that a fixed frequency is best because tuned circuits vary their resonant frequency when loads/environment changes.
So,
Is there a reason to operate at exactly 4 MHz ?
How accurate and stable do you NEED the frequency to be ?

I would go for a simple variable frequency oscillator and an accurate frequency meter
(or estimate frequency from your oscilloscope)
or something like this digital sig.gen./freq.counter Link2

many microcontrollers used to operate at 4 MHz - masses of info on the web
the 5v crystal oscillator that I linked to just needs 0v and +5v, and the output will drive the gate driver ic input directly.
I would not add any protection as the cost of an XTO on eBay makes it not worth the complication
e.g. Link2
(look for TTL or HCMOS'output to be safe, some crystal oscilllators give a distorted sinewave of about 1v)
Re: 4Mhz square wave generator
jdub1581hv, Fri Feb 19 2016, 09:41PM

klugesmith wrote ...

jdub's circuit is for using a bare 2-terminal crystal (passive component). Change the crystal to change the frequency.
Sulaiman pointed to some crystal oscillator components, which are easier to use. Connect appropriate power voltage (3.3 or 5 volts) and get a corresponding logic signal out.
In both cases the frequency is fixed. Worst case frequency error of +/- 100 ppm (0.01%) is a pretty loose tolerance for crystal controlled oscillators.

Your 74LS624 is a voltage controlled oscillator chip. No crystal is involved, and you can tune the frequency over a substantial range. How are you planning to measure the frequency, if you don't have an oscilloscope? You could divide it down into the audible range (e.g. with CD4040 or CD4060) and listen with headphones or a small loudspeaker. Or adapt an old auto service dwellmeter/tachometer, which I could send you for cost of postage.

It's time you learned a little about logic IC's. Jump on in; they don't bite. Get a plug-in breadboard to play with -- apparently as popular now as they were decades ago. There are other forums to learn at.

Cool, I am using the 4mh xtal and 7493ic as a divider -outputs: A=fo/2, B fo/4, C=fo/8, D = fo/16 Which should give me a 2mhz, 1mhz, 500khz, 250khz clocks to choose from..
Re: 4Mhz square wave generator
ZakWolf, Sat Feb 20 2016, 12:06AM

Sulaiman wrote ...

I'm not sure exactly what you are constructing
but with Class-E (or any resonant circuits) if you fix your clock frequency
then every other frequency dependant circuit will need to be tuned to the clock.
It will be easier if you have a variable frequency clock
which would allow 'tuning' by varying the clock frequency rather than adjusting capacitance or inductance
at least for one tuned circuit.

I also doubt that a fixed frequency is best because tuned circuits vary their resonant frequency when loads/environment changes.
So,
Is there a reason to operate at exactly 4 MHz ?
How accurate and stable do you NEED the frequency to be ?

I would go for a simple variable frequency oscillator and an accurate frequency meter
(or estimate frequency from your oscilloscope)
or something like this digital sig.gen./freq.counter Link2

many microcontrollers used to operate at 4 MHz - masses of info on the web
the 5v crystal oscillator that I linked to just needs 0v and +5v, and the output will drive the gate driver ic input directly.
I would not add any protection as the cost of an XTO on eBay makes it not worth the complication
e.g. Link2
(look for TTL or HCMOS'output to be safe, some crystal oscilllators give a distorted sinewave of about 1v)


Perfect, thats exactly the information I was looking for. I am working on a class e tesla coil. I can check the frequency witht he scope no problem. I want to drive the FET's like this guy is Link2 From reading the site he doesn't seem to have a class e drive arrangement, just the X Mhz signal feeding the IXDD614 MOSFET driver which outputs the square wave to the FQA11N90 gate. With that setup I would need the GDT's or to match impedance,further more i wouldn't need the classe e mosfet drive stage before the final class e circuit like Erik has.. Or am I missing something.

Its hard enough for me to grasp all this without the added effect of high frequency and resonance messing with everything.


1455926410 3114 FT175553 Proper 4mhz Classe Sstc 1
Re: 4Mhz square wave generator
jdub1581hv, Sat Feb 20 2016, 01:38AM

ZakWolf wrote ...


Perfect, thats exactly the information I was looking for. I am working on a class e tesla coil. I can check the frequency witht he scope no problem. I want to drive the FET's like this guy is Link2 From reading the site he doesn't seem to have a class e drive arrangement, just the X Mhz signal feeding the IXDD614 MOSFET driver which outputs the square wave to the FQA11N90 gate. With that setup I would need the GDT's or to match impedance,further more i wouldn't need the classe e mosfet drive stage before the final class e circuit like Erik has.. Or am I missing something.

Its hard enough for me to grasp all this without the added effect of high frequency and resonance messing with everything.


1455926410 3114 FT175553 Proper 4mhz Classe Sstc 1


I'm with ya man... The matching networks are a pain, and right when I think it's making sense, I go and confuse myself again.. Then again I may be going backwards in my process .. Adapting to what I have available..
My math is pretty good, but part reduction and circuit simplicity still trouble me.
Re: 4Mhz square wave generator
jdub1581hv, Sat Feb 20 2016, 01:42AM

Also, Perezx (member) has a nice feedback driven class e you could look up.. simpler than the pic you posted..
Re: 4Mhz square wave generator
Claude, Sun Feb 21 2016, 12:35AM

Reaching has a good simple 4Mhz class E audio modulated coil which I have built. Works very well. You don't have to add the audio modulation part if you don't want to.
Claude.
Re: 4Mhz square wave generator
ZakWolf, Sun Feb 21 2016, 12:43AM

So I lashed up a circuit with a 3.6Mhz crystal I have and used a Link2 74HC14N Hex Schmitt-Trigger. Flowed this schematic... I used random values 500k pot (Fres adjust) for R1, 10k for R2 and 240pF for C1&C2
1456014909 3114 FT175553 Osc32a


Scope Shot: The yellow trace is the Xtal ( 8 MHz is not accurate it was jumping all over the place but was most commonly at aroun 2.2 MHz)
Blue: square wave output at ~6v
1456015064 3114 FT175553 Newfile2


Looks like bad ringing.. stable up to about 4MHz limited by crystal probably... LM7805 with heavy filtering supplying Vcc. How to I go about calculating correct values? This produces square wave into the 100kHz range and up so if I get a high rated Xtal I should be able to achieve a 4Mhz zignal

How do I reduce the ringing ?

Edit: didnt have my POT in the right place, added the 1Mohm resistor across pins 1 and 2. Adjusting cap values I can get a range of different frequency's but the ringing is still an issue. I was able to achieve higher then 4Mhz with fixing my build
Re: 4Mhz square wave generator
klugesmith, Sun Feb 21 2016, 01:13AM

Hi Zak.
Nothing wrong with plugging in components at hand to see what happens.
But that circuit, with your reported values of R and C, is not a crystal oscillator. It's a tunable schmitt-trigger oscillator that would run, probably better, if you omit the crystal. Link2 R1 and the C on left side determine the frequency. To shift the tuning range to higher frequencies, put a smaller C over there (or both of your 240-pF C's in series).

The schematic image you posted tells how to choose values for a better shot at making it a _crystal_ oscillator. In that mode it would oscillate at 3.6 MHz +/- 0.01%, a frequency insensitive to modest changes in R and C values. The table in the schematic might give the impression that C and R2 determine the frequency. No! Frequency is set by the nominal value marked on the crystal package. Then you choose C and R2 values from the table to make a functional oscillator. You would have to extrapolate to pick likely values to work with a 3.6 MHz crystal. Or use values posted elsewhere in this thread for use with 4 MHz crystals (close enough). Good luck!

[edit] the ringing in your scope picture is probably an artifact of power and ground routing to the oscillator components and/or the scope probe. Can we see a picture? What's the nominal bandwidth (not the sampling rate) of the scope? Does it have a menu option to artificially reduce the bandwidth?


Re: 4Mhz square wave generator
ZakWolf, Sun Feb 21 2016, 01:28AM

klugesmith wrote ...

Hi Zak.
Nothing wrong with plugging in components at hand to see what happens.
But that circuit, with your reported values of R and C, is not a crystal oscillator. It's a tunable schmitt-trigger oscillator that would run, probably better, if you omit the crystal. Link2 R1 and the C on left side determine the frequency. To shift the tuning range to higher frequencies, put a smaller C over there (or both of your 240-pF C's in series).

The schematic image you posted tells how to choose values for a better shot at making it a _crystal_ oscillator. In that mode it would oscillate at 3.6 MHz +/- 0.01%, a frequency insensitive to modest changes in R and C values. The table in the schematic might give the impression that C and R2 determine the frequency. No! Frequency is set by the nominal value marked on the crystal package. Then you choose C and R2 values from the table to make a functional oscillator. You would have to extrapolate to pick likely values to work with a 3.6 MHz crystal. Or use values posted elsewhere in this thread for use with 4 MHz crystals (close enough). Good luck!

[edit] the ringing in your scope picture is probably an artifact of power and ground routing to the oscillator components and/or the scope probe. Can we see a picture? What's the nominal bandwidth (not the sampling rate) of the scope? Does it have a menu option to artificially reduce the bandwidth?




Awesome, Thanks for that I will try in a min. to omit the Crystal. My scope is a rigol DS1054z only had it a couple weeks so Im still learning how to use it
Re: 4Mhz square wave generator
ZakWolf, Sun Feb 21 2016, 01:59AM

Sorry for the double post but I wanted to add a new scope picture. A bit jittery


1456019801 3114 FT175553 Newfile3


This is the square wave without the crystal. Using 120pF and a 1Mohm pot to adjust frequency. I switched my probe to 1x and scope as well and that seem to have cleaned up the input. Was it looking so messy before because of the 10x setting? I know there is a capacitance in the probe at higher ranges right ?
Re: 4Mhz square wave generator
Sulaiman, Sun Feb 21 2016, 07:04AM

Check your user manual regarding your oscilloscope probes because

oscilloscopes usually have a direct input input impedance of around 1 MOhm // 15 pF
a x1 probe just adds to the capacitance, say 1 MOhm // 45 pF
a x10 probe has lower input capacitance, say 10 pF

so always use your probe in x10 mode, unless the signal is to low a voltage to see clearly on the 'scope.
to reduce high frequency loading of the circuit being 'scoped.

before using the probe on x10 you need to adjust it using the small screwdriver slot on the body of the probe where it plugs into the 'scope, see your manual for details.

Given the above, it is quite likely that your 'scope probe in

. x1 mode loaded the circuit enough to eliminate the spikes/ringing/overshoot
. x1 mode has a lower frequency response than your 'scope, e.g. 7 MHz so cannot 'see' the overshoot
. x10 mode may be showing overshoot that is not actually there as the probe has not been adjusted

these things come with experience, you will soon catch up !
Re: 4Mhz square wave generator
ZakWolf, Sun Feb 21 2016, 07:24AM

Sulaiman wrote ...

Check your user manual regarding your oscilloscope probes because

oscilloscopes usually have a direct input input impedance of around 1 MOhm // 15 pF
a x1 probe just adds to the capacitance, say 1 MOhm // 45 pF
a x10 probe has lower input capacitance, say 10 pF

so always use your probe in x10 mode, unless the signal is to low a voltage to see clearly on the 'scope.
to reduce high frequency loading of the circuit being 'scoped.

before using the probe on x10 you need to adjust it using the small screwdriver slot on the body of the probe where it plugs into the 'scope, see your manual for details.

Given the above, it is quite likely that your 'scope probe in

. x1 mode loaded the circuit enough to eliminate the spikes/ringing/overshoot
. x1 mode has a lower frequency response than your 'scope, e.g. 7 MHz so cannot 'see' the overshoot
. x10 mode may be showing overshoot that is not actually there as the probe has not been adjusted

these things come with experience, you will soon catch up !

Thanks Sulaiman, I know how to adjust the probes with a screw driver and I had them properly tuned.

So I will switch back to x10 and just add a load resister to help dampen the output more.

Is there a better (faster or more stable) tunable schmitt-trigger oscillator that I should use or is the SN74HC14N going to be ok to drive IXDD614CI.

EDIT:the 74ac14n is the faster version of the two
Re: 4Mhz square wave generator
Conundrum, Mon Feb 22 2016, 05:39AM

Yup. AC is faster.

Would you not be better off with a can oscillator with thermal feedback?
Re: 4Mhz square wave generator
Sulaiman, Mon Feb 22 2016, 05:30PM

An OCXO (oven controlled crystal oscillator) is overkill don't you think ?
Temperature changes will alter the inductance of air core inductors much more than the frequency of the crappiest crystal oscillator

Ultimately I suspect a pll solution will be best.