Saturday, April 21, 2012

How music is stored in memory chip and How the Earphones work???

© 2012 Ganti Sree Rajiv

Everyone these days has a pair of earphones plugged into their music player and enjoys the music. When you press ‘Play’ button you start hearing song in your earphones. Did you ever wonder how it actually happens??


The song is actually stored in a tiny memory card. The memory card is a tiny chip which is built with thousands of transistors and capacitors. The transistor and Capacitor is paired to make a ‘memory cell’, which represents a single bit of data. So when the whole memory is considered, there will be array of these memory cells. When the capacitor is charged, it means capacitor has stored binary ‘1’, and if the capacitor is discharged it means capacitor has stored binary ‘0’. The transistor acts as a switch that lets the control circuitry on the memory chip read the capacitor or change its state. However there are different types of memory (Flash Memory http://en.wikipedia.org/wiki/Flash_memory is usually used for music players). The song you store in memory is ‘encoded’ http://en.wikipedia.org/wiki/Code using a specific format (for example, the most common encoding format for audio/songs is MP3 ) and this encoded data bits are then stored in memory.


When you ‘Play’ the music, the encoded data from particular memory location is read, and decoded back and electrical signals are sent out through the earphones Jack (there are different connecting Jack’s depending on the device built, one of them is the 3.5mm Jack).

The earphone/Headphone has 2 speakers which you fit them in your ear. These 2 speakers are independent and are connected to signal wire. These two signal wires come down and are joined below at one point to make one sound cable, that connects to the audio jack. 













This Jack is connected to signal source such as Music player.


The song(actually in form of varying electric signals) flow from the signal source via the Jack to the housing of the earphone. Now this housing has several parts that actually convert these electrical signals into sound waves. The brain then translates these sound waves and so we experience it as Sound/Music.



Working Mechanism: ‘Inside the Earphone
The principle behind it is very simple. Consider you are striking a drum.













When you strike a drum, the outer skin/diaphragm vibrates thereby creating sound waves. The same is the principle of speakers. But it uses something called as ‘Electromagnetism’.

As you can see from the diagram, one end of the speaker has a Diaphragm (a very thin material made of fibre or plastic) which is firmly fixed at top and bottom, which is similar to the outer skin of the Drum. The other smaller end of the speaker has a magnet and a coil placed right in front of the magnet and in between the magnet ends. The wires coming from the source (audio jack of player) are coiled around.
The electric signal comes from the audio jack rotates around this coil, and as this coil is put in a constant magnetic field, this constant magnetic field and changing electric current creates ‘Electromagnetism’. This electromagnetic force either attracts or repels the diaphragm. This force of attraction or repulsion depends on the varying current around the coil as the magnetic force is constant in that field.  The pitch of the sound depends on this vibration of diaphragm.
Thus, the movement of Diaphragm back and forth creates sound waves (just like in case of Drum), and these waves reach your ears.
In order to give the ear/head phones a good look, this speaker part is covered/finished with many other parts.


The mechanism explained above is just basic mechanism which gives clear idea of how it works inside earphones.
However with the advancement of technology, there are many developments in field of sound technology (acoustic technology) and today we can see lot of difference and improvement in quality of sound being produced.
One such famous development is the ‘Noise-Cancellation’.


How Noise Isolation and Noise Cancellation works??
The principle of noise cancellation is pretty simple. It is in principle of physics ‘destructive interference’ that suppose if you consider a periodic wave, and if you add to it another periodic wave equal in amplitude and opposite in phase, they cancel out each other, and result is Zero amplitude wave.


Please note that Noise isolation and Noise cancellation are different.

Noise Isolation is a passive way to isolate external noise. In this case, the earphone has a 'round the ear' pad and a high-density foam to block the sound waves from outside to reach ears.

However the Noise Cancellation uses active method. It uses the above mentioned destructive interference method to cancel noise.


A microphone is placed inside the earphone. When external noise reaches this microphone, the microphone picks up some of this noise randomly and sends it the noise-cancellation circuit. This circuit then analyzes the noise wave pattern, and sends back similar wave (equal in amplitude and opposite in phase). When this wave mixes with original noise wave, according to principle of destructive interference, both waves cancel out each other. So in this way, noise gets cancelled. 


©2012 Ganti Sree Rajiv

4 comments:

Anonymous said...

very informative article.... we all listen to music but very few knows mechanism behind it...

Anonymous said...

Thanks to you,the article is very informative.Nice stuff.
=)

$we♥ said...

Such a simple thing, and there's sooo much behind-the-scene action going on :O

And you've said it in a simple, super way :) Kudos Rajiv.

$we♥ said...

Rajiv, great work :)

There is so much behind-the-scenes action and you've explained it very well! Kudos, keep blogging TechFreak :D