skip to main | skip to sidebar

Check It-

Photoshop Design Designers

Thursday, April 28, 2011

How does VoIP work?


* When you speak at the handset or a mike or a microphone, your voice generates electrical signals inside the gadget. These are analog signals i.e. the voltage level can take up any value within a range.
* The analog signal is converted to a digital signal using an algorithm implemented by the device you are using. It can be a stand-alone VoIP phone or a softphone running on your PC. If you are using an analog phone, you will need a Telephony Adapter (TA) for this purpose. The digitized voice is arranged in packets (i.e. collection of bytes) and sent over the IP network.
* The data is channeled through gateways and servers to the destination. If the called number is on the PSTN, the server opens a connection to the PSTN and routes your call there.
* While going to the PSTN or at the end device of a VoIP connection, the voice is again brought back to its analog form so that it is perceptible to a human ear.

* During the entire process a protocol like SIP or H.323 is used to control the call (e.g. setting up connection, dialing, disconnecting etc.) and RTP is used for reliable transmission of data packets and maintain Quality of Service.

VoIP: Circuit Switching  

Existing phone systems are driven by a very reliable but somewhat inefficient method for connecting calls called circuit switching.

Circuit switching is a very basic concept that has been used by telephone networks for more than 100 years. When a call is made between two parties, the connection is maintained for the duration of the call. Because you're connecting two points in both directions, the connection is called a circuit. This is the foundation of the Public Switched Telephone Network (PSTN).

Here's how a typical telephone call works: 

   1. You pick up the receiver and listen for a dial tone. This lets you know that you have a connection to the local office of your telephone carrier.
   2. You dial the number of the party you wish to talk to.
   3. The call is routed through the switch at your local carrier to the party you are calling.
   4. A connection is made between your telephone and the other party's line using several interconnected switches along the way.
   5. The phone at the other end rings, and someone answers the call.
   6. The connection opens the circuit.
   7. You talk for a period of time and then hang up the receiver.
   8. When you hang up, the circuit is closed, freeing your line and all the lines in between.

Let's say you talk for 10 minutes. During this time, the circuit is continuously open between the two phones. In the early phone system, up until 1960 or so, every call had to have a dedicated wire stretching from one end of the call to the other for the duration of the call. So if you were in New York and you wanted to call Los Angeles, the switches between New York and Los Angeles would connect pieces of copper wire all the way across the United States. You would use all those pieces of wire just for your call for the full 10 minutes. You paid a lot for the call, because you actually owned a 3,000-mile-long copper wire for 10 minutes.

Telephone conversations over today's traditional phone network are somewhat more efficient and they cost a lot less. Your voice is digitized, and your voice along with thousands of others can be combined onto a single fiber optic cable for much of the journey (there's still a dedicated piece of copper wire going into your house, though). These calls are transmitted at a fixed rate of 64 kilobits per second (Kbps) in each direction, for a total transmission rate of 128 Kbps. Since there are 8 kilobits (Kb) in a kilobyte (KB), this translates to a transmission of 16 KB each second the circuit is open, and 960 KB every minute it's open. In a 10-minute conversation, the total transmission is 9,600 KB, which is roughly equal to 10 megabytes (check out How Bits and Bytes Work to learn about these conversions). If you look at a typical phone conversation, much of this transmitted data is wasted.  

VoIP: Packet Switching

A packet-switched phone network is the alternative to circuit switching. It works like this: While you're talking, the other party is listening, which means that only half of the connection is in use at any given time. Based on that, we can surmise that we could cut the file in half, down to about 4.7 MB, for efficiency. Plus, a significant amount of the time in most conversations is dead air -- for seconds at a time, neither party is talking. If we could remove these silent intervals, the file would be even smaller. Then, instead of sending a continuous stream of bytes (both silent and noisy), what if we sent just the packets of noisy bytes when you created them?

Data networks do not use circuit switching. Your Internet connection would be a lot slower if it maintained a constant connection to the Web page you were viewing at any given time. Instead, data networks simply send and retrieve data as you need it. And, instead of routing the data over a dedicated line, the data packets flow through a chaotic network along thousands of possible paths. This is called packet switching.

While circuit switching keeps the connection open and constant, packet switching opens a brief connection -- just long enough to send a small chunk of data, called a packet, from one system to another. It works like this:

    * The sending computer chops data into small packets, with an address on each one telling the network devices where to send them.
    * Inside of each packet is a payload. The payload is a piece of the e-mail, a music file or whatever type of file is being transmitted inside the packet.
    * The sending computer sends the packet to a nearby router and forgets about it. The nearby router send the packet to another router that is closer to the recipient computer. That router sends the packet along to another, even closer router, and so on.
    * When the receiving computer finally gets the packets (which may have all taken completely different paths to get there), it uses instructions contained within the packets to reassemble the data into its original state.

Packet switching is very efficient. It lets the network route the packets along the least congested and cheapest lines. It also frees up the two computers communicating with each other so that they can accept information from other computers, as well.  

How voice is coded digitally for voip?

The digitization of analog voice signals is a must to transmit voice over the digital IP network. It can be done in several ways
  • PCM (Pulse Code Modulation) is a simple technique of sampling the sound signal at a fixed rate (8000 times/second) and generate a number corresponding to each sample. It assumes no specific property of the signal. So it works reasonably well with all types of sounds.
  • LPC (Liner Predictive Coding) assumes specific properties of human voice and uses a more complex algorithm to digitize and compress voice data. It works well for sending human utterances offering a low data rate but is not suitable for transmitting music or fax.
  • SBC (Sub Band Coder) uses a different approach of representing sounds in terms of frequencies rather than sampling at regular intervals.
  • Hybrid coders like the CELP (Code Excited Linear Prediction) use a mixture of the techniques to transmit sound of adequate quality.

0 comments:

Post a Comment

Share your view here