24
Telephony • How do phones and traditional telephone networks work? • How is IP Telephony different? • Asterisk PBX: An example of open-source enabler. • Looking forward:“Personal Telephony”: Phone as a universal voice information access device.

Telephony How do phones and traditional telephone networks work?

Embed Size (px)

Citation preview

Page 1: Telephony How do phones and traditional telephone networks work?

Telephony

• How do phones and traditional telephone networks work?

• How is IP Telephony different?• Asterisk PBX: An example of open-source

enabler.• Looking forward:“Personal Telephony”:

Phone as a universal voice information access device.

Page 2: Telephony How do phones and traditional telephone networks work?

Traditional Phones

• Dumb devices (1$ phone)• Intelligent network (million-dollar switches)• TDM (Time-Domain Multiplexing)• Tight control:• Until 1977 – no customer-owned phones• Until 1984 – no access to trunk-side

(MCI/Sprint court cases)

Page 3: Telephony How do phones and traditional telephone networks work?

Openness of Phone Network

• Begins in 1984 -AT&T divestiture: Baby Bells, IXCs

• BRI/PRI ISDN availability to end users: “Smart” Interfacing to Phone Network (delivery of multiple TNs, caller*id for outgoing calls, forwarding, etc).

• SS7 interconnect for carriers

Page 4: Telephony How do phones and traditional telephone networks work?

Layers of Phone / IP protocols

• Network: IP• Transport: UDP/TCP• Higher layers: BGP,

FTP, HTTP, etc.

• Network: unnamed• Transport: SCCP• Higher layers: ISUP/IN• CNAM, LNP, CLASS,

LIDB, E911, etc.

Page 5: Telephony How do phones and traditional telephone networks work?

Phone Networks Architecture

• Central Office (“CLASS 5”, end user svc)

• Tandems (Central Office without end users)

• Signal Switching Point (“SS7 end node”)

• Signal Transfer Points (“router”)

• Signal Control Point (“database interface”)

• No hierarchy (somewhat like IP)

Page 6: Telephony How do phones and traditional telephone networks work?

SS7 Services

• CNAM (Caller Name): look up of caller’s name for Caller-ID presentment).

• CMSDB (Call Management Service Database): 800/900 billing, call management, congestion prevention.

• LIDB (Line Information Database): billing information (COCOTS, payphone, etc), to find out how to bill customer for the phone call, collect/third party phone calls.

• LNP (Local Number Portability): Decoupling of phone number from a physical line, Rate Center and Central Office: Each phone call involves now LIDB lookup to find out where physically the phone number is located.

Page 7: Telephony How do phones and traditional telephone networks work?

Phone/IP Network Comparison

• Mindset: IP is an open network, SS7 is a closed network, providing similar range of services.

• Both are packet based networks

• SS7 is tightly controlled with high requirements for interconnection

Page 8: Telephony How do phones and traditional telephone networks work?

TDM vs Packet

• TDM stands for “Time Domain Multiplexing”, means that a given channel is reserved for duration of the call. (No silence suppression or similar)

• TDM signalling: All endpoints need to know how to reserve bandwidth for the phone call and free it (setup/teardown).

• Out-of-band signalling is used to set up channels.

• No routing: Once call is set up and bandwidth allocated, data is passed by intermediary endpoints

• Packet-based: In-band, over network-layer protocol (such as IP), each packet has source/destination headers, intermediary routers only need to understand IP.

Page 9: Telephony How do phones and traditional telephone networks work?

Analog to Digital

• To transmit data over a digital network, we need to convert it into digital form. (encode and decode, “codec”)

• Uncompressed call is 64k bps (8000 samples/second, 8 bits/sample), “PCM” (Pulse code modulation”)

• Other compressions:

• ADPCM (32kbps)

• GSM (8kbps)

• G.723.1 (patented)

• G.729 (patented but reasonably licensable)

• MP3 (slow, no tolerance to loss)

• ILBC (new, becoming popular, alternative to patented algorithms)

Page 10: Telephony How do phones and traditional telephone networks work?

VoIP signalling

• Transmission of voice: Usually done with “RTP” protocol (real-time protocol, small headers, and one “stream” per UDP/TCP port). Stream, is for example, voice or video one-way conversation.

• Now that we have our phone call in a digital form, two endpoints need to agree on codecs and transmit call setup information. (Such as caller phone number, caller’s business card, callee’s phone number).

• Two major protocols in use:

• H.323: ISO-approved suite, based on ASN compression, fixed protocol numbers and binary encoding.

• SIP: IETF-backed, string-based (easy to parse, easy to generate), very HTTP-like, web-friendly (sending URLs or email addresses during phone call)

Page 11: Telephony How do phones and traditional telephone networks work?

Signalling, continued

• Required functionality: Communication between endpoint (Terminal or “User Agent”/UA) and gateway (“Gatekeeper” or “Server”)

• “Dumb” terminals: Terminal is generally attached to a single gateway.

• Functions to support usual phone features: Conferencing, call forwarding, call pickup, etc.

• TCP or UDP: Both SIP and H323 can use either protocol, historically SIP usually runs over UDP, and H323 uses TCP.

• H323 is very firewall-unfriendly, and nearly impossible to use through firewall.

• Auxiliary functions: Billing, Codec conversion are all part of signalling.

• Phone/IP address routing: No standard, thus even if carrier B will eventually deliver the phone call via VoIP to end customer, phone call needs to travel via PSTN channels between carriers A and B.

• ENUM is the standard that may change that: 4.6.6.8.7.0.4.7.1.9.1.e164.arpa is DNS name that should translate into IP endpoint for phone number 1-917-407-8664

Page 12: Telephony How do phones and traditional telephone networks work?

Questions?

Page 13: Telephony How do phones and traditional telephone networks work?

Enough Boring Stuff

• Okay, you told us how do things work. Now, what can we do with it?!

• Traditional VoIP applications were “toll avoidance” (for example, when company had two offices and a dedicated line, “extend” a PBX through the dedicated line, benefitting from compression).

• VoIP can be over private IP network or over the Internet.

• Internet + VoIP combination provides many interesting possibilities by overlaying two networks. Example: Least Cost Routing among available carriers via Internet (or a private IP exchange)

• One of pioneers was Free World Dialup: A service run by volunteers at each location, providing gateways from VoIP into PSTN at their location.

Page 14: Telephony How do phones and traditional telephone networks work?

More VoIP services

• Free World Dialup (FWD) is now a “gatekeeper”/meet-me service where you can get your own phone number, set up Netmeeting/GnomeMeeting or any other H.323 application on your PC and any other FWD customer can call you via FWD.

• Cool stuff: FWD received its own country code. Now, anyone can call your FWD number from a regular phone and have their call routed to your PC.

• (Unfortunately, its an international call for the caller)• VoIP “commoditises” the phone network. Now, to provide any kind of voice

service, you don’t need to wait two weeks for monopolistic provider to provide you with service, and you are not bound to any given carrier to terminate your calls. You can port your phone number to a new carrier in matter of days (all electronic).

• Public Internet is an enabler, but also limits quality-of-service (when did you last lose your dialtone? When did you last had packet loss?).

Page 15: Telephony How do phones and traditional telephone networks work?

Personal Phone Company

• Don’t you wish your phone was “smarter”? For example, most of us have phone and answering machine at home (shared with your family), cell phone with voice mail, and voicemail in the office.

• Which phone number do you usually give out?

• What if you had only one phone number for everything?

• One Man, One Phone: Follow-me phone number. With GPS, potentially, all you need is to “check in” at a given location, and you will receive your phone calls at the nearby phone.

• Routing phone calls intelligently based on time, caller ID, and information entered by caller, if any.

• Dealing with girlfriend calling from payphone is a homework exercise for the reader.

Page 16: Telephony How do phones and traditional telephone networks work?

Wireless VoIP

• Decoupling wireless transport from the phone service.

• Already you can use your iPaq as a wireless phone anywhere in the world where you can get Wi-Fi, and get your phone calls without roaming charges.

• With development of 2.5G wireless networks, it is also now possible to decouple phone from RF (radio frequency) interface: You could carry in your pocket iPaq and PCMCIA data connection cards for whichever network: GSM/GPRS, CDMA/1xRTT, AMPS/CDPD, wired ethernet, etc.

• Currently 2.5G networks have high latency and barely usable for VoIP , 3G networks are expected to fix that.

Page 17: Telephony How do phones and traditional telephone networks work?

Getting Started: VoIP Market

• Origination: Receiving calls. Termination: Sending calls.

• Termination: hundreds of providers, strong price competition. Many internet sites act like “switching boards”, bringing together customers with minutes to terminate and providers who can terminate in a given market, at a given “call completion ratio”. Some don’t mind dealing with small customers, most are wholesale-only. Market rate for US long distance is 1c/minute.

• Origination (getting a phone number delivered to you via VoIP): Currently much harder.

• Vonage: Probably the most vocal company providing VoIP services to end users. If you have a broadband connection, you can get a reliable local phone number from Vonage and all-you-can-eat long distance. Unfortunately, they are trying to preserve as much control as Bells, and will not allow you to interface your PC directly with their network. (and go to extraordinary lengths to do so).

• iConnectHere: Local coverage at many regions, 800 numbers, no problems with VoIP.

• Regional players: (yours truly)

Page 18: Telephony How do phones and traditional telephone networks work?

Questions?

Page 19: Telephony How do phones and traditional telephone networks work?

VoIP software

• Number of Free Software packages available to do VoIP.

• Major ones:

• VOCAL: Vovida Open Communications Application Library: Set of components that implement SIP and make possible to build applications based on it. (Gatekeeper, Feature Server, etc), C++.

• libh323: Open Source implementation of H.323 stack, C++

• Bayonne: IVR package, with a very powerful scripting language, supports H323 via libh323 and a number of proprietary interfaces. Quite good for what it does, C++.

• Asterisk: “Open Source Hybrid TDM/packet voice PBX and IVR platform with ACD functionality”. Focus of the rest of the talk.

Page 20: Telephony How do phones and traditional telephone networks work?

Asterisk overview

• What does Asterisk do? Asterisk is a platform (“switch”) where resources and plugins can be added to implement functionality.

• Example resources:

• Channel drivers:

VoIP (H323, SIP, MGCP, skinny)

TDM (hardware cards that support fixed phones)

• Applications: Queue, Agent, Festival (Text-To-Speech)

• PBX features: Voicemail

• CLASS features: 3-way call, caller*id, Call Waiting, etc.

• All features are transparently integrated. SIP phone and analog phone can make outgoing calls via H323, for example.

Page 21: Telephony How do phones and traditional telephone networks work?

Asterisk IVR

• Multiple ways to implement IVR:

• Asterisk has very powerful dialplan (“extensions.conf”) file where call routing logic can be represented: exten => s,1,Answer

• exten => s,2,BackGround,pilosoft-welcome; Play the prompt

• exten => 1,1,BackGround,pleasewait ; if user pressed 1, play “please wait”

• exten => 1,2,Queue,salesq ; Transfer to sales queue

• exten => 1,3,Voicemail,u599 ; Send to voicemail if nobody picks up

• exten => 1,4,Hangup

• (also, channel variables can be set/modified, etc).

• If dial plan is not sufficient: external interface via “AGI” (Asterisk Gateway Interface), similar in concept to CGI. Excellent Perl Interface available (Asterisk::AGI), allowing for arbitrarily complex applications.

Page 22: Telephony How do phones and traditional telephone networks work?

• exten => 7,5,PGSQL,"Fetch fetchid ${resultid} message strlen"; • exten => 7,6,GotoIf,${strlen}?7|100:7|8; • exten => 7,7,Goto,t|1 • exten => 7,8,Festival,${message}

Page 23: Telephony How do phones and traditional telephone networks work?

PBX

• Hardware feasible for deployment for small-scale PBX for small businesses. (Integrated with DSL and other services)

Page 24: Telephony How do phones and traditional telephone networks work?

Experiences

• Setting up a call center with 8 lines in 48 hours.

• Switching LD provider.

• Future: Asterisk+SS7

• Demos:16463753460