Beruflich Dokumente
Kultur Dokumente
Vishwakarma Institute of Information Technology
(Department of Electronics & Telecommunication)
A
Project entitled
“ELECTRONIC SYNTHESIZER
”
Submitted by
SOMESH GANESH(413045)
RAGHAK RADHAKRISHNAN(413012)
AMIT TIWARI(413061)
B.E Project
.Electronics & TeleCommunication
Year 2015 – 2016
Savitribai Phule Pune University
Under the supervision of
Prof. Mr. A.V. CHITRE
1
CERTIFICATE
BANSILAL RAMNATH AGARWAL CHARITABLE TRUST”S
VISHWAKARMA INSTITUTE OF INFORMATION TECHNOLOGY
(Department of Electronics & Telecommunication)
This is to certify that the project
“DIGITAL SYNTHESIZER”
has been successfully presented by
SOMESHGANESH (413045)
RAGHAK RADHAKRISHNAN (413012)
AMIT TIWARI (413061)
This is an original work done by the students and has not been submitted previously
by any other student/students for the award of any other degree of same or other
university.
The work is done, on the basis of the work allotted to these students, based on
various project ideas presented by them. This project report is being submitted as a
part of the subject Project and Seminar at B.E.E&TC.
Prof. Mr. A.V. Chitre Dr. Prof. Y.H. Dandawate
(Guide) (H.O.D E& TC)
2
ACKNOWLEDGEMENT
We completed our target for the project in the E&TC department of VIIT College. A
warm thank you to our H.O.D Prof.Y.H.Dandawate for his support and
encouragement. We would also like to thank Prof. Mr. A.V.Chitre who inspired us
with the idea of the project and is guiding us in the entire course of the project.
A hearty thanks to Coursera, an open online course portal which helped us in
building the algorithm and enlightened us about the various aspects during the early
stage of our project.
It would be inappropriate not to mention the help we received from Prof. G.H.
Chavan who
introduced us to the Raspberry pi platform.
Our thanks also extends to all the web portals and IEEE papers which helped us
throughout the process. Last but not the least we would like to thank our friends and
batch mates for their support and assistance.
3
INDEX
Sr. No. Contents Page No.
1 Problem Statement 5
2 Abstract 6
3 Introduction 7
4 Literature Survey 8
5 Principal Hardware & Software Components 11
6 Approach (Block Diagram) 12
7 Applications & Future Scope 14
8 Concept in MATLAB 15
9 References 16
FIGURE INDEX
Sr. No. Contents Page No.
31 Raspberry Pi 2 & Arduino UNO 7
41 Musical Telegraph 8
42 Prophet 5 9
4
1) PROBLEM STATEMENT
“To build an Electronic Synthesizer on a standalone Raspberry Pi platform and
produce different notes along with audio effects and display the frequency and time
plot.”
Objectives
● Create a MATLAB GUI to understand the concept and develop the idea
● Implement the algorithm on the Raspberry Pi board for signal generation
● Add delay effect
● Generate the continuous frequency plot of the sound
● Incorporate capacitive touch keyboard with the Arduino board
5
2) ABSTRACT
The rapid spread of electronic music and increasing demand for unique and
innovative sounds has led to the rise in various software music creation platforms.
When one needs to produce these unique sounds on a keyboard while composing or
performing, he/she will have to connect the keyboard to a laptop therefore utilizing
the complex functionality provided by the software. This synthesizer setup includes
the cost of not only the keyboard, but also the laptop, the software being used, any
additional plugins used and the wiring used to connect the keyboard and the laptop.
This project comprises the development of a digital music synthesizer capable
of sound synthesis with the processing of delay audio effects. The system will be
implemented on Raspberry pi, a development board which will be programmed in
python. Capacitive touch sensors have been implemented to give a smoother feel to
the keys. These keys have been interfaced with the Raspberry pi board via a
Arduino UNO board. The completed synthesizer will be capable of producing a
variety of musical tones, many aspects of which are completely controllable by the
user. The module will also generate the frequency plot of the sound created.
Therefore, this synthesizer will be a standalone, plugandplay system which
will obviate the need
fora laptop or any additional software to develop complex
sounds. The project is aimed at providing music enthusiasts with a low cost solution
for composition and performance.
6
3) INTRODUCTION
The rise in modern music production techniques and widespread use of MIDI
(Musical Instrument Digital Interface) has called for the need of development of
electronic synthesizers which are capable of producing a wide range of unique
sounds, the parameters of which can be completely controlled by the user. The use
of digital signal processing modules in the synthesizer can make one feel that the
number of possible sounds created by it are infinite. This level of complexity offered
by a single instrument has brought synthesizers to the forefront of music composition
and production across many genres of music today. While early synthesizers were
developed using analog circuits, the modern ones use digital components such as
embedded processors and integrated circuits.
The goal of this project is to develop a synthesizer using the Raspberry pi
development board to read in the musician input, perform signal generation and
effect processing, and output an analog waveform to be played through speakers.
Python will be used as the programming language. We will design the system to be
capable of producing waveforms and executing realtime effects for audio signal
output. The Raspberry pi 2 Development Board and the Arduino UNO Board are
shown in Figure 11.
Fig. 31 Raspberry Pi 2 & Arduino UNO
Audio signal processing will hold an important role in the manipulation of the
produced sound. This project will be carried out with a goal to develop a standalone
hardware platform which, through various effects modules will allow the user to
produce complex sounds without the need for a separate software. This will reduce
cost of the equipment setup and therefore increase access to many more music
enthusiasts.
7
4) LITERATURE SURVEY
A sound synthesizer is an electronic musical instrument that generates
electric signals converted to sound through loudspeakers or
headphones .
Synthesizers may either imitate other instruments or generate new timbres . They are
often played with a keyboard , but they can be controlled via a variety of other input
devices, including music sequencers ,
instrument controllers,
fingerboards ,
guitar
synthesizers,
wind controllers, and electronic drums . Synthesizers without builtin
controllers are often called
sound modules , and are controlled via MIDI or CV/Gate
(Control Voltage/Gate). [1]
Synthesizers use various methods to generate a signal. Among the most
popular waveform synthesis techniques are
subtractive synthesis
,
additive synthesis
,
wavetable synthesis
,
frequency modulation synthesis
,
phase distortion synthesis
,
physical modeling synthesis
and
samplebased synthesis.
The Evolution of Synthesis
During the 1870s, Elisha Gray accidentally discovered that he could control
sound from a self vibrating electromagnetic circuit and in doing so invented a basic
single note oscillator. Using this principle he designed what is known as the first
electronic musical instrument; The ‘Musical Telegraph’. It contained enough
singletone oscillators to play two octaves and later models were equipped with a
simple tone wheel control. A figure of this device has been shown below in Figure
21. [2]
Fig. 41 Musical Telegraph
8
This idea was taken to the next level by implementation of a Voltage Controlled
Oscillator (VCO), where the frequency of oscillation is proportional to the input
voltage provided to the circuit. This resulted in compact designs as one oscillator
could produce a wide range of frequencies. This reduced the size of the synthesizers
and increased its portability. As electrical technology advanced over the course of
the 20th century, new designs for more complex and commerciallyavailable
synthesizers became prevalent worldwide. The synthesizer became a common
instrument in popular recorded music. In early synthesizers, each effect module was
a stand alone analog system which had to be connected sequentially using patch
cables. Consequently, systems were large, bulky and expensive. But with the
advancements in the field of digital systems and microprocessors, smaller, portable
and less expensive systems were possible. Different synthesis techniques were
employed to produce a wide range of timbres suited across many genres of music.
One such synthesizer was the Prophet 5 shown in Figure 22. In 1978, the success
of the
Prophet 5, a
polyphonic and
microprocessor controlled keyboard synthesizer,
strongly aided the shift of synthesizers towards their familiar modern shape, away
from large modular units and towards smaller keyboard instruments. [3]
Fig. 42 Prophet 5
Early digital synthesizer systems were limited by the speed and memory available to
microprocessors, which has grown logarithmically over the past 30 years. Modern
digital synthesizers make use of highspeed microprocessors to accomplish a
multitude of realtime effects processing techniques. [4]
9
Synthesis Techniques
There are many synthesis techniques that have been developed for musical
applications in both analog and digital synthesizers. The origins of waveform
synthesis stem from Additive Synthesis. [5] This method allows the user to add
specific harmonics of a base frequency into the output signal, through the use of
multiple oscillators. The Hammond Organ is one of the earliest examples of an
additive synthesizer, which implemented analog sinusoidal additive synthesis. With
the development of the VCO and Voltage Controlled Filters (VCF), a new synthesis
method was developed, known as Subtractive Synthesis. [6] This allows the user to
start with a more complex waveform (such as a sawtooth or square signal) and cut
off undesired frequencies, resulting in a wide variety of possible sounds.
Other forms of synthesis include FM synthesis (frequency modulation synthesis)
which is a process that usually involves the use of at least two signal generators
(sinewave oscillators, commonly referred to as "operators" in FMonly synthesizers)
to create and modify a voice. Often, this is done through the analog or digital
generation of a signal that modulates the tonal and amplitude characteristics of a
base carrier signal Granular synthesis
. is a type of synthesis based on manipulating
very small sample slices.
Physical modelling synthesis is the synthesis of sound by
using a set of equations and algorithms to simulate a real instrument, or some other
physical source of sound. This involves modelling components of musical objects
and creating systems that define action, filters, envelopes and other parameters over
time. Various models can also be combined, e.g. the model of a violin with
characteristics of a pedal steel guitar and the action of piano hammer. When an
initial set of parameters is run through the physical simulation, the simulated sound is
generated. [7]
Synthesizer Effects
A large number of synthesizer effects have been developed since the origin of
electronic instruments. The aim of this project is to implement some of the most
common effects, considered essential to any modern synthesizer. Recreating the
amplitude envelopes of certain physical sounds into the synthesizer allows the
generated sound to have smooth transitions between waveform amplitudes. There
are other interesting effects like the Vibrato effect which comprises
a rapid, slight
variation in pitch in playing some musical instruments, producing a richer tone. Noise
has been used very effectively in music to give a sense of space to the sound.
Distortive effects produce grainy sounds which are desired in certain genres of
electronic music. The large number of audio effects used today are essential in this
evolving modern music production era.
10
5) PRINCIPAL HARDWARE & SOFTWARE COMPONENTS
Raspberry Pi 2
The Raspberry Pi is a low cost, creditcard sized computer that plugs into a
computer monitor or TV, and uses a standard keyboard and mouse.
The Raspberry Pi board, as mentioned before, is the main hardware component in
this project. It is responsible for reading the user input from the Arduino board,
perform signal generation, assign the note frequency, add the delay effect and
generate the frequency plot.
Arduino UNO
The Arduino board is a microcontroller which we have used to implement our
capacitive touch keyboard. It consists of analog pins which make it very easy to
develop a smooth keyboard like feeling.
Capacitive Touch Keyboard
The keys in this project will be interfaced to the Raspberry Pi board through the
Arduino board. The concept is based on the idea that when a user plays a key, the
capacitance developed during contact will generate a spike and will be detected by
the Arduino. This data will be serially sent to the Raspberry Pi board which will read
this input and accordingly generate a note of the desired frequency.
Python
The Raspberry Pi board has been programmed in Python (Version 2.7.9)
Python contains a lot of builtin modules for signal processing, sound generation and
waveform generation. It works well in realtime applications. It is a very user friendly
programming language and has hence been used in this project as the principal
programming language.
We have used the following packages in our code
● RPi.GPIO for accessing the general purpose input/output pins on the
Raspberry Pi board
● Tkinter and tkSnack for generation of the base sounds and their
corresponding frequency and note length
● Numpy and Scipy
for continuous waveform generation
● Serial
for communication and transfer of data from the Arduino board to the
Raspberry Pi board
11
6) APPROACH (Block Diagram)
We have broken down the project into the following blocks as shown in Fig. 31
Fig. 61 Block Diagram
Base Sound & Length
The user will be given an option to select a base sound of his choice.
The options will include the three basic waves used to create electronic synthesizer
sounds which are a sine, square or sawtooth wave.
He/she will also be allowed to choose the length of the note.
Note (frequency)
The user can then decide the note he/she wants to play and the respective octave
too. This will correspond to a particular frequency which will decide the frequency
with which the base sound will play.
12
Audio Effects
This is the block which includes the effects processing.
Currently, this block has the delay effect. The user will be able to choose the value
for two parameters in this effect. He/she can decide the number of times the delayed
note should be played and the duration between the delayed notes.
Output
This final block includes not only the final sound being played on a speaker but also
continuous generation of the frequency plot of the corresponding sound being
played. This will aid the musician or composer in analysing his sound and making
suitable changes to it instantly.
This whole module will be dealt with block by block in python and finally ported to the
Raspberry pi 2 board.
13
7) APPLICATIONS AND FUTURE SCOPE
This project is a developing prototype and has tremendous scope for improvement
and specialization.
● It has the potential to be the main system for production of electronic music
● It can be used as a standalone system to create complex sounds without the
need of an expensive software and a heavy processing system
● It can be used in various live performance situations
● It can be used in the studio for composition and mixing of various sounds
● Being a digital system, many features can be added without a steep increase
in cost
● A lot more base sounds can be added for more choice
● Various delay, dynamic and filter effects can be added in the effects
processing block for more variety and complexity
● The basic working and principle of the system is designed in such a way that
addition of various individual components and their integration can be done
easily
14
8) CONCEPT IN MATLAB
The basic concept of this project has been developed and has been demonstrated
using a MATLAB GUI. A screenshot of the output has been shown in Figure 32. A 3
octave keyboard has been programmed to generate either a sine, square or
sawtooth wave. It specifies the fundamental frequency of the note and also
generates the time and frequency plot of the signal. Although this is a monophonic
software instrument, the final synthesizer on the standalone hardware platform will
be polyphonic. In this screenshot, a sawtooth wave has been generated and its
corresponding time domain and frequency domain response (all harmonics present
for sawtooth wave) has been plotted. The note B4 has been played which has a
fundamental frequency of 329.63 Hz.
Fig. 81 MATLAB GUI
The final product will be able to assist in creating and modifying synthesizer sounds
for music production. It can be used as a standalone system for live performances. It
can be useful in studios for composition and mixing various sounds. It can help
produce innovative sound patches without the use of a laptop. Since it is a digital
synthesizer, many features can be added to the system without a considerable
increase in price.
15
9) REFERENCES
[1] “Synthesizer,”
https://en.wikipedia.org/wiki/Synthesizer
[2] "The 'Musical Telegraph',"
http://120years.net/themusicaltelegraphelishagreyusa1876/
[3] “
Polyphonic keyboards and the digital revolution,
”
https://en.wikipedia.org/wiki/Synthesizer#Polyphonic_keyboards_and_the_digital_rev
olution
[4] V. Beal, "Moore's Law,"
http://www.webopedia.com/TERM/M/Moores_Law.html
[5] G. Reid, "Synthesizing Tonewheel Organs,"
http://www.soundonsound.com/sos/nov03/articles/synthsecrets.htm
[6] M. Ottewill, "Subtractive Synthesis,"
www.planetoftunes.com/synthesis/subtractivesynthesis.htm
[7] “Types of Synthesis,”
https://en.wikipedia.org/wiki/Synthesizer#Types_of_synthesis
16