Electronic – Crystal oscillator behaving strangely

crystaloscillator

I've made a 32kHz crystal oscillator using the CD4060B IC. The IC is powered by a 7805 voltage regulator which in turn is connected to a 12V SMPS.

enter image description here

I've probed the Q5 output (~1024Hz) using an optocoupled MSP432 and had the following waveform:

enter image description here

The large "off" period grows larger and eventually the oscillations stop.

I've noticed that when I placed my finger at the body of the 7805, I had stable 1024Hz oscillations for some seconds, then the "off" period started growing again until the wave collapsed. I thought it could be an overheating problem, so I added a heatsink to the 7805 and probed the current using a multimeter – still had the same result (the current drawn was at most 1.1mA).

Then I've placed much larger decoupling capacitors (220uF and 470uF) – still had the same results.

Then I connected the IC directly to the 12V SMPS and had the same result…

I also tried the original circuit, but with different feedback capacitors and resistor at the crystal filter (15pF, 33pF, 56pF, and 3.3Mohm) – still no improvement…

Finally I've powered the IC directly using the 5V pin from MSP432 and probed using the same optocoupled circuit. Then I had a stable and perfect ~1024Hz square wave.

Could this be a problem with my SMPS or is it a problem with the circuit? What could possibly indicate the fact that my finger at the body of 7805 created a "temporary stable" square wave? Why does it work with the MSP432 as the power source?

Thanks in advance.

Best Answer

I don't see anything inherently wrong with your circuit or your constant-current drive output circuit, except that you MUST connect unused inputs on the chip to a valid logic level (ground or +5 in this case). In particular, pin 12 (RESET) must be grounded or it will float around with leakage and capacitive pickup.

It's also possible the 470K is too high and your oscillator is barely able to maintain oscillation.