After building a few noise machines, I wanted to build something more musical that still used the widely available CMOS logic chips but was controlled by an Arduino. My main inspiration was Elliot Williams’s Logic Noise series on hackaday.com.

Objectives:

  • Building an at least 8 step musical sequencer
  • A square wave oscillator as the main sound source
  • Representation of the sequence with a row of LEDs displaying the current step and providing visual feedback
  • The stability and accuracy of the tuning has to be acceptable for the human ear
  • It should have at least a 4 octave range
  • The player of the instrument should be able to change the octave range.
  • It should have a voltage controlled filter (low-pass) with a pleasant resonance.
  • An LCD screen has to be used for displaying the changed parameters, the current note selected and it should incorporate a menu where the user can set various options
  • For navigating in the menu, a rotary encoder with a debounce circuit should be built
  • Using as few as possible I/O pins of the Arduino
  • Using the simplest and smallest circuits possible
  • Using a single MCP4822 Dual-Channel 12-bit DAC to control the oscillator pitch and the filter cutoff
  • Using the DAC to create an adjustable ASDR filter envelope
  • Using the DAC to control the pitch of the oscillator

The main goal of this project was to build a simple, yet powerful analog synthesizer based around the “misuse” of the CD series logic chips that can run off of a 9V battery and combines it with the power of a small Arduino Nano.

First working version:

View this post on Instagram

A post shared by Demeter Szabolcs (@quidbop) on

This is my first project that can be called a synthesizer. The previous ones were just noise making machines that I made to learn the basics of synths. This one is able to play melodies with its square wave VCO which is digitally controlled by Arduino’s PWM through a DAC to smooth it, delivering a constant voltage to the vactrol that is controlling the VCO.

The Oscillator:

I have tried several oscillator designs before eventually choosing the first (and simplest) version. The oscillator is based around a single inverter of a Schmitt-Trigger Inverter chip with hysteresis. The inverter chip that is used is the CD40106UBE. If we apply 0V to the input of the inverter, it outputs the +5V supply voltage. If we apply 5V, it gives 0V output. If we connect the output directly back to the input we get an oscillator with a frequency somewhere around 4MHz. This is too high for human hearing so it has to be slowed down. By connecting the input of the inverter through a capacitor to ground (Figure 3.2), we get a square wave at the output with a frequency determined by the values of the capacitor and resistor. The hysteresis is crucial, since without it the output would stay at the voltage threshold.

The Filter:

This module is responsible for the filtering of the harsh square waves, so it doesn’t sound like an 2-bit synth. It is a simple second-order state-variable filter based on this one. Only the low-pass output is used.

It is controlled by the signal coming from the Arduino through the DAC. Two vactrols were used to provide simultaneous control of R4 and R8. In analog synth applications this is usually replaced by stereo (dual gang) potentiometers. In the case of higher order filters, pots with more terminals are needed.

Schematic of the CD4069 filter

Finished version:

View this post on Instagram

A post shared by Demeter Szabolcs (@quidbop) on