Got a BT line? Want to make cheap calls over the Internet but don't want to buy separate phones, don't want to use a headset and don't want to have to leave your PC switched on? Want to use your normal household phones to make VOIP calls whilst still receiving incoming calls on your normal BT number?
This is a fairly comprehensive HOWTO for the Linksys/Cisco SPA3102 and a British Telecom line in a domestic situation. It also has specific configuration details for WebCallDirect.com , but will work with any VOIP SIP provider.
If you currently spend more than 20 quid a month on calls on your BT bill, then I expect this setup to pay back the £45 cost of the SPA3102 in less than 3 months. Furthermore, after a year or so, I got begging letters from BT asking me to bring back my calls to them, offering me discount packages that were still nowhere near as cheap as VOIP.
Our goal is to vastly reduce the phone bill whilst the spouse/teenage children/housemate remains almost oblivious to the fact we're routing outbound calls over the Internet. In essence, save money and minimise nagging. At this point I would like to remind all readers that I love my wife Melissa very, very much.
The capacitor is important. It stores a small amount of charge which is released in two short bursts to create a ring-ring sound. Originally, this burst was enough to cause an electric motor, or a lever attached to an electromagnet, to strike a bell. UK BT telephone lines have remained with this system, and BT compatible telephones will not ring unless they receive this burst of charge- even though their ring is electronic rather than a motorised bell! Your BT master wall socket contains a capacitor, but the effect of this is lost when you go through the SPA3102, because your phones are no longer directly connected to the master socket at the wall- the SPA3102 is a little telephone exhange in its own right! So you have to add a capacitor between the SPA3102 and your BT handsets in order for them to ring. Without the capacitor, you can still make and receive calls, but the phones will never ring.
Note the difference between the "BT master wall socket" (the place where the phoneline comes in to your house) and the "BT master socket adaptor" (a short wire with an RJ11 plug at one end and a BT socket with a capacitor in it at the other).
Do not proceed any further until you are certain that your phone cabling is correct.
The next sections talk about configuring your SPA3102 settings. Until this is fully completed, which may take about half an hour, you won't be able to make or receive calls through the SPA3102 in the manner you'd normally expect. Therefore:
Linksys assume that you will be using the SPA3102 as both a VOIP router and a network router. I am going to assume this is not the case for your domestic situation. I am going to assume that you already have an existing, working, separate broadband router that you wish to continue using.
The problem with my new assumption is that we need to activate the web configuration tool for the Internet (WAN) socket on the SPA3102. By default this only works for the Ethernet (LAN) socket. If you are not using another existing broadband router, changing this is unsafe, and could give everyone access to your VOIP router, including allowing hackers to make calls on your phone bill and allowing hackers to get access to your computer network.
You may have noticed that the sockets on the SPA3102 are colour-coded and that the indicator lights change colour between red, green and orange. Since like one in twelve white males, I am colour-blind (red-green colour vision deficient), I will not be referring to these colours.
Enable WAN Web Server: Yes
No doubt you've noticed on American TV programmes that their phones have a different ring - a single long ring instead of our British two quick rings. Well, the bad news is there are lots of other differences, such as the pitch of the dialling tone, and the SPA3102, despite being shipped with a British mains plug, has factory defaults of the USA. So we'll be spending some time reconfiguring it to sound and act like a British telephone line.
Bear in mind that the dialling tone and ringing tones you'll eventually get when everything is done, will NOT be generated by your local BT telephone exchange like it is now. The SPA3102 will generate its own ring tone, its own dial tone, its own call waiting tone, everything. It'll only connect to your BT line when it needs to, such as an incoming call. So in order for your existing BT telephone handsets to work, and more importantly, your wife not to complain about the phone doing odd stuff, we need to make sure it acts as much like a BT line as possible.
Many, but not all, of the following settings were taken from the excellent document "Sipura UK Regional Settings" by Paul Hayes of ProVu.com . Other settings were taken from the Voxilla.com forums. Thank-you all.
Dial tone: 350@-19,440@-22;10(*/0/1+2)
Ring back: 400@-20,450@-20;*(.4/.2/1+2,.4/2/1+2)
Busy tone: 400@-20;10(.375/.375/1)
Reorder tone: 400@-20;10(*/0/1)
SIT 1 tone: 950@-16,1400@-16,1800@-16;20(.330/0/1,.330/0/2,.330/0/3,0/1/0)
MWI dial tone: 350@-19,440@-22;10(.75/.75/1+2)
CWT1 cadence: 30(.1/2)
CWT2 cadence: 30(.25/.25,.25/.25,.25/5)
CWT frequency: 400@-10
Ring 1 cadence: 60(.4/.2,.4/2)
Ring 2 cadence: 60(1/2)
Ring 3 cadence: 60(.25/.25,.25/.25,.25/1.75)
Ring 4 cadence: 60(.4/.8)
Ring 5 cadence: 60(2/4)
Time Zone: GMT
FXS Port Impedance: 370+620||310nF (or 270+750||150nF )
Caller ID Method: ETSI FSK With PR(UK)
Daylight Saving Rule: start=3/-1/7/1:0:0;end=10/-1/7/2:0:0;save=1:0:0
These settings make the dial tone, ring tone and other tones sound like BT.
PSTN VOIP Gateway Enable - No
This means that the SPA3102 should never answer the phone automatically, allowing the existing household phones and answering machine to answer calls. If you intend to use the SPA3102 to do more advanced things such as voicemail or call redirection, you'll probably want this to be Yes, but that's beyond the scope of this document.
PSTN Answer Delay - 60
This means that the SPA3102 should only answer the phone automatically after 60 seconds, allowing residents or the existing household answering machine a full minute to pick up the phone. If you intend to use the SPA3102 to do more advanced things such as voicemail or call redirection, you'll probably want a shorter value, but that's beyond the scope of this document.
Detect CPC: yes
Detect Polarity Reversal: no
Detect PSTN Long Silence: no
PSTN Long Silence Duration: 30
PSTN Silence Threshold - High
Min CPC Duration: 0.09
Detect Disconnect Tone: yes
Disconnect Tone - 400@-30,400@-30; 2(3/0/1+2)
These changes include the BT disconnect tone and also should ensure that calls don't get accidentally dropped due to the SPA3102 mistaking strange noises or quiet volume for a disconnection.
FXO Port Impedance: 270+750||150nF
OnHook Speed: 3ms (ETSI)
Current Limiting Enable: yes
Ring Validation Time: 256ms
Ring Indication Delay: 512ms
Ring Timeout: 640ms
These settings are more stuff to make your line BT compatible, including a delay to read CallerID on incoming calls.
Auto PSTN Fallback: Yes
This means that if your internet connection fails, it will dial via BT.
Dial Plan:(x.<:@gw0>)
Emergency Number: 999
We are now ready to test the system again. The SPA3102 should now route all incoming and outgoing calls via the BT line even when switched on. If you've unplugged the SPA3102 from your phoneline and handsets, plug it back in.
If this doesn't work, try unplugging the power to the SPA3102. If it works when the SPA3102 is off, the problem is with your configuration. If it doesn't work when the SPA3102 is off, the problem is with your cabling.
Once everything works, we are now ready to start routing calls over the internet.
SIP (session initiation protocol) is the open standard for VOIP. This means that lots of companies can all use the same protocol. This is also the protocol that your SPA3102 uses. Skype, at the time of writing (Jan 2008) does not use SIP and you will not be able to use Skype with your SPA3102.
There are lots of SIP VOIP providers to choose from. Most of them will have rates far cheaper than BT. Google for "voip sip calls" and pick one that has the cheapest rates for the destinations or types of call you make most often. For example, my wife makes a lot of 01 and 02 calls, but I occasionally call my sister in Holland.
Remember that BT's national and local landline calls are pretty cheap even on the cheapest tarrif. Many VOIP companies offer bundled, inclusive or free landline minutes for a period if you spend a certain amount, so pick one of those.
Some examples to get you started:
I suggest you put about five or ten pounds onto the account intially. Some providers may take this in Euros or US Dollars. I currently use WebCallDirect, so I will be using this in my configuration examples.
Once you have an account with a VOIP SIP provider, you will need to know the SIP configuration details. These can usually be found on the FAQ or technical support pages. WebCallDirect's SIP configuration details are here.
Some providers will allow you to use your own telephone number, as well as and instead of your username, to log in, so that your Caller ID will be shown to people you call. This is required in order for your name to show up as the caller when you ring your friend's mobile phone, for instance. If you do not do this, your Caller ID will probably be withheld, and people you ring won't know that it is you who is calling.
You may need to do some special kind of registration with your VOIP provider to confirm that you really do own that phone number. For example, WebCallDirect require you to download and run their MS-Windows application and use the account settings options to confirm your phone number with a test call. Once you've done this, you don't need to use the downloaded application ever again - which is good as far as I'm concerned, as I use Linux most of the time.
Many VOIP SIP providers who give specific instructions for the SPA3102 or SPA3000 assume that you want to route all outbound calls via them. This is not the case for us, as we want to route 100, 151, 999 and 0800 calls via BT still. Also we may, at a later date, want to route different calls via more than one VOIP SIP provider (one may be cheaper for UK calls, another cheaper for international calls). Therefore ignore any instructions that tell you to fill in the Proxy and Registration section, as this will route all calls via that provider by default!
Gateway 1: +441242000000@sip.Webcalldirect.com
GW1 NAT Mapping Enable: no (but you may need to enable this; see below)
GW1 Auth ID: myusername
GW1 Password: mypassword
...where I replace +441242000000 with my home phone number that I have registered with my provider for caller ID, myusername is my account name and mypassword is, surprise, my password.
If you do not, or cannot, register your home number with your VOIP provider for outbound Caller ID, then replace +441242000000 with your userid (eg. myusername). Yes, this means it gets entered twice - once in the Gateway 1 field, and again in the GW1 Auth ID field.
Dial Plan: (x.<:@gw1>)
Note that you have changed from gw0 (Gateway Zero) to gw1 (Gateway One). Gateway Zero is your BT line, also known as PSTN or POTS. Gateway One is your VOIP SIP provider. Time for another test!
If you can't successfully call your mobile (e.g. you get the number unobtainable tone), check the Info tab before you put down the handset. If the Info tab says "Call 1 State: failed" then it is having problems making the outbound VOIP call, usually due to incorrect credentials but sometimes due to router problems. Check your Gateway 1 setting, Auth ID and Password. A common problem is that you may need to enable NAT Mapping, depending on how strict your broadband router's firewall is (some broadband routers are shipped with very strict firewalls by default). So:
GW1 NAT Mapping Enable: yes
Another hint for SIP traffic problems ("Call 1 State: failed") is that some broadband routers try to automatically rewrite SIP traffic, and fail pretty badly. If your router supports SIP ALG (SIP Application Level Gateway) then try turning this off (disable SIP ALG). On some Belkin routers there is a hidden SIP ALG page at: http://your.router.ip.address/siproxdcfg.html
If you still have problems with "Call 1 State: failed" on the info tab during an unsuccessful outbound call, then try putting your SPA3102's IP address in your router's DMZ section (see your router's manual for details). You could even try turning your router's firewall off completely - if you're using NAT then it probably won't matter much from a security perspective, but you should confirm this yourself, or get good advice, especially if you have a server or other machine permanently connected to your network 24/7.
Do not proceed any further until the tests work as expected (ie. you can call your mobile using the international number, but you cannot call the operator).
The dial plan determines which outbound calls route over which network - normal BT line or the internet. I'm going to give you a call plan which routes operator, faults, emergency and freephone numbers over the BT line, routes local, national, mobile and international calls over the internet, and bans directory enquiries and premium rate numbers.
Dial Plan: (100<:@gw0> | 999<:@gw0> | 112<:@gw0> | 151<:@gw0> | 1471<:@gw0> | 0[58]0x.<:@gw0> | 00x.<:@gw1> | <0:0044>[123]x.<:@gw1> | <0:0044>[67]x.<:@gw1> | 084x.<:@gw0> | <087:004487>x.<:@gw1> | <:00441242>[2-8]x.<:@gw1> | 118! | 09!)
(all on one line)
Dial Plan: (100<:@gw0> | 999<:@gw0> | 112<:@gw0> | 151<:@gw0> | 1471<:@gw0> | 0[58]0x.<:@gw0> | 00x.<:@gw1> | <0:0044>[123]x.<:@gw0> | <0:0044>[67]x.<:@gw1> | 084x.<:@gw0> | <087:004487>x.<:@gw1> | <:00441242>[2-8]x.<:@gw1> | 118! | 09!)
(all on one line)
You can read more about customising your own call plan, for instance to route different numbers via different providers, by looking in the "SPA ATA Admin Guide" which can be obtained from the Linksys website, or directly from this Linksys FAQ page. They are similar to, but not the same as, POSIX regular expressions. There's also a lot of discussion on the Voxilla.com forums.
If you do not already have Call Waiting with BT, then one way to check call routing is: Call a number that should route over the internet. Leave this call going. Then, at the same time, use your mobile to call your landline number. If it is engaged (busy), then you've done something wrong - it's calling via BT! If it rings, then it is working - and on the normal handsets you will hear a quiet "Call Waiting" beep in the background. Yup, the SPA3102 generates its own Call Waiting system!
To perform a Call Return using VOIP (as an alternative to 1471-3), from the dialtone dial *69 . This will call the last incoming Caller ID.
Auto PSTN Fallback: No
The SPA3102 is capable of much, much more than we've configured here. You can use it to get cheap international calls from your mobile, by configuring it to recognise your mobile caller ID and answer those calls with an international dialling tone. You can use it to interface to an Asterisk software telephone exhange and create your very own voicemail hell. You can use it to store your favourite phone numbers and access them with a shorter sequence. Plus lots, lots more - read the manual and forums for more ideas.
2008-02-06 Changed Ring Indication Delay to 512ms and Ring Timeout to 640ms, to allow CallerID time to transmit. Corrected duplicate Disconnect Tone.
2008-07-01 Put back missing minus signs in dial tones. Thanks to Theo Markettos.
2009-07-22 Change the Disconnect Tone to 400@-30,400@-30; 2(3/0/1+2)
2010-01-20 Switched dial plan so that 084x. numbers (eg. 0844, 0845) are dialled via gw0 (PSTN). 084x numbers are not usually available internationally.
2010-10-23 Changed FXO Port Impedance from 370+620||310nF to 270+750||150nF . Thanks to Steve Trow, see also the Cisco Small Business Pro Analog Telephone Adapters Administration Guide and this Cisco support forum thread.
2011-02-07 Added router firewall hints for solving "Call 1 State: failed" errors. Absolutely no thanks to Belkin for their hardwired, non-editable firewall and hidden SIP ALG configuration page.
2012-10-25 Corrected the daylight savings time setting to start=3/-1/7/1:0:0;end=10/-1/7/2:0:0;save=1:0:0 - thanks to Garry Martin for the tip.
2014-05-29 Updated to refer to rebranding of Linksys to Cisco, and to note about Local Loop Unbundling. Added section on codecs and why you should stick to G.711 .
2014-06-10 Add coverage of 03 numbers to national dial plan.
Public Domain - Andrew Oakley - 2008-01-08