This project aims to generalize the Theremin form to create an extremely versatile musical instrument. Like existing Theremins, the device created in this project will have two antennas and will measure the distance between a performer's hands and the two antennas. Unlike existing Theremins, this device will not output a tone. Instead it will provided analog and digital values which can be processed by external modules. The design offers many different possibilities.
A single module containing a voltage controlled oscillator and some attenuation circuitry can be attached to generate the typical Theremin output. Different types of circuits can provide different sounds over different ranges.
Other modules might be added to change the way the instrument responds to the performer. A differentiator on the volume line would make the output volume proportional to the rate at which the peformer's hand moves rather than the distance between the performer's hand and the antenna. A non-linear circuit might adjust the response of the pitch antenna to pick out discrete pitches or to give the performer greater control in a specific range.
Since the outputs are not tones, the device is not limited to functioning as an instrument. The DC outputs can be used to control effects devices or synthesizers. The Theremin can be reprogrammed or external circuitry can be added to provide an interface with any digital device including computers and other electronic instruments.
The device uses inexpensive digital components and simple relaxation oscillators operating at frequencies of a few kilohertz. As a result, it can be built much more cheaply than existing analog theremins. I estimate that the final device will cost between 50 and 100 dollars without an enclosure.
The device software will be open source and a means will be provided to reprogram the device. This, combined with the DC and Serial outputs means that anyone can build and share modules and change the way the device behaves.
What Has Been Done
The Theremin prototype shown in the video was created over the course of a few days using the materials I had on hand. The antenna in the video is a long piece of wire that controls the frequency of a relaxation oscillator built using a 555-timer. The oscillator operates at roughly 4.3KHz and serves as the clock for a 12-bit binary counter (74HC4040). In order to reduce stray capacitance and noise, the oscillator was built on perfboard using wire wrapping and a few solder joints. This arrangement is not ideal, but it's far better than a breadboard.
The fifth bit output from the binary counter provides a square wave at roughly 130Hz. An MC9S12 microcontroller measures the period of the slower square wave using a 16-bit input capture interrupt. Eight consecutive measurements are collected and averaged to provide improved resolution and reduced noise at the cost of a slower refresh rate.
The resulting value is processed to remove offset and scale down to 10-bits. In addition, the prototype show finds the nearest 10-bit value known to correspond to a note in the 12-tone scale and brings the measured value closer to the known value to provide some discretization of pitch.
The prototype uses a Dragon-12 Demo board, which contains the microcontroller and a 10-bit ADC. A real-time interrupt occurs roughly every 30ms, and during the interrupt the current output value is written to the ADC, which provides an analog control value for a simple 555-timer-based voltage controlled oscillator. The output from the oscillator directly drives a speaker to produce a tone.
What Will Be Done
The prototype I built demonstrates the viability of my basic design, but it's far from being a musical instrument, and it certainly can't stand on it's own. These are the things I need to do to make an actual Theremin:
- Design a stable digital oscillator for the antennas and create a printed circuit board (PCB).
- Create a PCB for the microcontrollers, digital to analog converter (DAC), and power supplies.
- Write code to perform measurements with high resolution.
- Tweak oscillator frequencies and code to get measurement resolutions greater than 12-bits
- Design an interface bus for connecting modules.
- Write code to provide measurement data as DC values and through a Serial interface.
- Design and build an oscillator module to produce output sound.
- Debug and characterize the device.
What The Money is For
A Theremin works by measuring the very small capacitance between a performer's hands and the antennas. As a result, it is very sensitive to stray capacitance. PCB's are critical not just in the final design, but also in development and testing to provide circuits with minimal stray capacitance. A significant portion of the funding will be used to purchase equipment and supplies for etching PCB's.
The remaining funding will be used to purchase components for prototyping and testing and to purchase PCB layout software if necessary.
The lab notebook (at $5) contains information about experiments, test results, and design information. It serves to document most of the design process. An example can be seen here. The example covers some relaxation oscillator design considerations.
- (60 days)