Repairing an AVR DDS Signal Generator

Background

As far as I can tell, the first use of an AVR to do direct digital synthesis of an analog signal was by Jesper Hansen in 2001.  Mindaugas Marozas picked up the idea to create a stand-alone function generator in 2006. In 2008, Mindaugas published an improved version, which has become the basis of many homebrew projects, as well as a number of Chinese clones. Georg Latzel, DL6GL, gives a very nice and detailed rundown of the theory of operation (in German).

What’s wrong?

In December 2017, I purchased one of these clones on eBay. Unlike the projects linked above, this one does not require an external three-voltage power supply (+5V for digital logic, -12V/+12V for the op-amp rails). Instead, it uses a single DC barrel connector for (what I thought) +12V, deriving +5V with a 78L05, and -12V with an ICL7660.

ICL7660 pinout
ICL7660 pinout (from the Intersil / Renesas datasheet)

Avid readers of the ICL7660 datasheet will already have spotted the problem: The ICL7660 is specified only up to +10V. 1 With a 12V supply, it worked fine for about half an hour, then gave up. Now, the 5V part of the circuit (AVR, display, buttons, high speed digital output) still works fine, but the analog output appears completely dead. On pin 5 of the ICL7660 (VOUT), I measured +0.2ish Volt instead of the expected – V+. At least, the ICL7660 is socketed.2

DDS board
The DDS board in question, with the display removed. Note that the ICL7660 is the only socketed chip. Also, note that it does say +12V above pin 8 of the ICL7660. If you bought the same board, and made the same mistake, this article is for you.

The Fix

Having replaced the ICL7760, I now get -9V at VOUT, for V+ = +9V, and the analog output works again.

And that’s all?

Fortunately, yes. I also bought a spare opamp, but I’m glad I didn’t need it. I still dread SMD desoldering.

Here are some nice pictures from the working signal generator:

The charge pump at work

ICL7660 charge pump capacitor voltages
ICL7660 charge pump capacitor voltages. For the first half of the cycle, CAP+ (yellow) is connected to V+, and CAP– (cyan) is connected to ground, charging the capacitor to V+. In the second half of the cycle, CAP+ is connected to ground instead, leaving CAP– at –(V+) to charge the charge reservoir capacitor at VOUT.

Some waveforms

AVR DDS: 1 kHz sine
AVR DDS: 1 kHz sine
AVR DDS: 1 kHz EGC waveform
AVR DDS: 1 kHz EGC waveform. This nicely shows of the ability to generate arbitrary waveforms through DDS, even though it is of very limited use.
AVR DDS: "noise"
AVR DDS: “noise”. Note that “noise” means a different, random 8-bit value output every 80us or so.
AVR DDS: 1 MHz high speed TTL
AVR DDS: 1 MHz high speed TTL. Note the 8 MHz and 16 MHz components visible in the high state.
AVR DDS: 8 MHz high speed TTL
AVR DDS: 8 MHz high speed TTL
  1. Using 12V would have required an ICL7760A, which our Chinese friends apparently considered to be too expensive. In small quantities, the price difference is about €0.90 from e.g. Reichelt.
  2. In fact, the ICL7660 is the only socketed chip on the entire board. Everything else is soldered SMD. Guess someone knew why…

Leave a Reply

Your email address will not be published. Required fields are marked *