Connect with us

Make square-wave sound better

Discussion in 'General Electronics Discussion' started by wingnut, Nov 24, 2012.

Scroll to continue with content
  1. wingnut


    Aug 9, 2012
    Hi all

    I have a 555 timer circuit which produces musical notes.

    Does anyone know of a simple way of improving square waves so that these sound richer? I don't know what to Google search for, because I cannot think of a name for the process of enriching square-waves so that these sound more like real musical notes.

    I am hoping to add just a few electrical components to the 555's output to get a magically rich sound - or is that just a pipe dream?

    Could a PIC perhaps be programmed to produce rich notes instead of square waves, and if so, what kind of an algor-rhythm would one use?

    Last edited: Nov 24, 2012
  2. Raven Luni

    Raven Luni

    Oct 15, 2011
    Technically you cant get any richer than a square wave since it is composed of the fundamental frequency and an infinite number of full magnitude harmonics (not to be confused with a discretely sampled wave which will show logarithmic magnitude drop off and linear phase drift towards the nyquist frequency but stretch out to infinity and the variance becomes zero).

    When you say real musical notes, which instrument did you have in mind? There are countless ways in which you could vary a tone to approximate different instruments. Volume envelope, vibrato, reverb, low and high pass filtering,....noise addition.........

    Synthesis is what youre after. It's a whole scene in itself :)
  3. wingnut


    Aug 9, 2012
    That is beautiful Raven, pure Shakespeare, even though I am too igorant to understand its deeper overtones ;)

    Currently the closest it sounds like, is/are the bagpipes, so I wouldn't mind it sounding more fully so.
  4. duke37


    Jan 9, 2011
    A square wave contains only odd harmonics which sound rough.
    Early electronic organs generated a 'top octave' and divided this down by two, four etc to get lower octaves. By sounding the note and the octave(s) above, then even harmonics were added which sounded better. The second harmonic was at half amplitude and the fourth at quarter amplitude.

    I went to a wedding in scotland not long ago. They had a bagpipe for entertainment, the person playing was a south african!
  5. Raven Luni

    Raven Luni

    Oct 15, 2011
    You learn somethign new here every day :) . In my ignorance I had assumed even harmonics were the result of rectification and therefore not really important / desirable
  6. KJ6EAD


    Aug 13, 2011
    The simplest way to improve the sound is to create polyphony by applying the same control voltage to several 555 circuits then sum the outputs into an amplifier. The component value tolerances will produce enough pitch variation. You might try using 556 or 558 chips.

    Another variation would be to create even multiples of the base frequency (octaves). Two, three or four octave polyphony should be rich enough. This is what Duke37 was suggesting.
    Last edited: Nov 25, 2012
  7. wingnut


    Aug 9, 2012
    Thanks a lot for the feedback.

    I have added another 555 timer with the exact same components as the first, and combined the output of both to an amp. It definitely sounds richer (less anoying) than a single square wave.

    Using a 555 calculator, I see that if I wish to double the frequency, all I have to do is half the capacitance and this will give one octave higher. Sounds easy enough. Will try it later.

    Duke, I like bagpipes (in moderation), but especially like them when accompanied by a marching band of kilted up Scotsmen. It kind of stirs the blood. We don't see that often enough here. It must be a prohibitively expensive musical instrument, but cheap as anything to synthesise on a keyboard.
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day