Toy Organ Using a 555 Timer

by MoRevolution in Circuits > Tools

167 Views, 0 Favorites, 0 Comments

Toy Organ Using a 555 Timer

20240410_183320.jpg
Toy Organ

In this tutorial, I'll be using a 555 timer to build a monophonic toy organ which doesn't quite sound like a toy organ. This project requires a little bit of knowledge on bread boarding, RC circuits, and 555 timers. Although, I'll give a theoretical overview of each part of this project, I won't be going over all the details, so I've left some links below to get you going.

I'll explain why this "toy organ" doesn't quite sound like a toy organ, along with how you can fix this, later in this instructable. But for now, here are the things that you'll need to get started:

Supplies

  • A 555 timer
  • 6 x (or more) momentary tactile push buttons (any kind is fine, but I'm using a four pin button like this)
  • 6 x 1kΩ resistors
  • 1 x 10kΩ resistor (or potentiometer with a rating greater than 10kΩ)
  • 8 Ω speaker
  • 1 x 10µF capacitor electrolytic capacitor
  • 1 x 1nF capacitor
  • 9V battery and a battery clip
  • (Optional) ON-OFF Switch

General Theory (at Least the Idea Behind It, If Not All the Details)

The core of this circuit is the 555 timer IC configured in an astable multivibrator mode. In this configuration, the 555 timer oscillates between its two output states (high and low) at a frequency determined by the resistor-capacitor (RC) network connected to pins 6, 7, and 2 of the 555 timer. Specifically, the frequency is inversely proportional to the product of the resistor and capacitor values.


f = 1 / (0.693 * (R_a + 2*R_b) * C1)

R_a, R_b, and C1 are boxed in blue, green, and red respectively.


Here, R_b is the series combination of resistors that is a result of a button being pressed, which are portrayed as a switch in the schematic. Let's say, for example, that the fourth button across is pressed, R_b is equal to 3kΩ, the sum of the individual resistance of the first three 1kΩ resistors. If the first button is pressed, R_b = 0Ω. The image below illustrates R_b at 3kΩ when the fourth button is pressed.


The musical tones are generated when one of the push-buttons, which are connected in parallel, is pressed. Depending on which of the button is pressed, R_b changes and affects the total resistance in the RC network of the 555 timer, thereby changing the frequency of the sound produced. This is because the resistance in the RC circuit also determines the rate at which capacitor C1 is charged and discharged. The faster the capacitor is charged and discharged, the higher the frequency of sound produced by the speaker and vice versa. Finally, as you probably guessed by now, going from right to left, the frequency of the resulting tone gets lower and lower since the resistance increases.

Putting It All Together

circuit-20240427-1224.png
waveforms-tim37.gif

Start by placing the 555 timer IC on the breadboard with its notch facing up and connect pin 8 to the positive rail and pin 1 to the negative rail as shown in the schematic above, which has the numbered pins of the timer. Then, set up the connections necessary around the 555 timer, no need to connect the buttons or the resistors at this point. I'll lay out some steps that you can follow or use as a checklist:

  • connect pins 2 and 6 together
  • connect pins 4 and 8 together
  • place a 1kΩ resistor between pins 7 and 8
  • place a 10nF capacitor between pin 2 and the negative rail
  • connect a 10kΩ to pin 7 of the IC

Now, you'll need to set up the pushbuttons. Be careful to place the buttons such that the pair of pins that are interconnected close the circuit when the button is pressed. For more info on this, check out this article: The Four-Pin Switch: Hooking it up.


Then either the left most or right most pin of the pushbutton to the 10kΩ resistor, and the other pin to pin 6 of the 555 timer. Place the next button, and connect the pin of the first button which is connected to the resistor such that they are in series, and connect the other pin in the same way. Then follow this procedure for each of the subsequent buttons that you add. The image below illustrates this.


To complete the circuit, place a 10μF capacitor with its positive terminal connected to pin 3 of the IC and its negative terminal connected to an empty row. Then, connect the 8Ω speaker such that the positive terminal of the speaker is connected to the negative terminal of the capacitor, and the negative is connected to ground. Finally, connect the power supply, and the organ is ready...ish. Test it and you'll get what I mean.

So...I Didn't Actually Build a Toy Organ?? What Gives??

Well...if you noticed the sound that each button produced, the pitch of each note sounds quite random and out of tune. The reason for this is that our choice of resistors going from one button to the other don't really account for a specific pitch, but rather simplifies our work a bit. To fix this, start by selecting resistor combinations for R_b at each junction of the buttons to produce the desired ranges of pitches you want. To aid with this, the equation outlined in Step 1 can be inverted to calculate R_b for a desired frequency:


R_b = ((1/(f * C1)) - (0.693 * R_a)) / 1.386


For example, let's say we want the first button to produce a frequency of 293.665 to produce note D4 (referenced here) in the musical scale. Using the equation above:


Rb = ((1/(293.665 * 10µF)) - (0.693 * 10kΩ)) / 1.386

= (340.524 - 6930) / 1.386

= -4754.3 Ω


You can continue this process for each proceeding button while accounting for the accumulated resistance. It might be hard to find the exact resistor needed for the desired frequency, so pick the closest resistor combination available to you.