A Function Generator In Its Purest Form

If you have a modern function generator on your bench it is quite likely to contain a direct-digital synthesis circuit that creates arbitrary waveforms using a microprocessor controlled DAC. If you have a cheap function generator it’s likely to contain a one-chip solution that generates approximations to sine and triangle waveforms through modifying a square wave with a set of filters.

These methods both produce adequate waveforms for most of your function generator needs, but they are both far from perfect for the purist. Both methods introduce some distortion, and to address this [michal777] has produced a generator that takes the process back to basics with all stages implemented using building block ICs and transistors. The circuit follows the same square-wave-modifying path as the cheaper integrated devices, but with significant attention paid to the design to ensure that it does as good a job as possible. It also makes for a fascinating dive into function generator design.

The generator hardware has been neatly fitted onto a PCB with a riser for a set of front panel controls. He shares a few pictures of previous designs. We particularly like one that appears to have been fitted into a redundant cooking pot.

We’ve brought you a few function generators over the years. If you’ve got one of the cheaper examples, we’ve even covered how you might improve it a little.

Hybrid Raspberry Pi + PIC32 = Oscilloscope and Function Generator

The PicBerry is a student final project by [Advitya], [Jeff], and [Danna] that takes a hybrid approach to creating a portable (and affordable) combination digital oscilloscope and function generator. It’s based on the Raspberry Pi, features an intuitive Python GUI, and can generate and measure simultaneously.

But wait! The Raspberry Pi is a capable little Linux machine, but meeting real-time deadlines isn’t its strong suit. That’s where the hybrid approach comes in. The Pi takes care of the user interface and other goodies, and a PIC32 over SPI is used for 1 MHz sampling and running a DAC at 500 kHz. The idea of combining them into PicBerry is to get the best of both worlds, with the Pi and PIC32 each doing what they are best at. The readings are sent in batches from the PIC32 to the Pi, where the plot is updated every 30 ms so that user does not perceive any visible lag.

The project documentation notes that improvements can be made, the speeds are a far cry from regular bench equipment, and the software lacks some typical features such as triggering, but overall not bad at all for under $50 of parts. In fact, there are hardly any components at all beyond the Raspberry Pi, the PIC32, and a MCP4822 digital-to-analog converter. A short demo video is embedded below.

Continue reading “Hybrid Raspberry Pi + PIC32 = Oscilloscope and Function Generator”