Linksys 3102 for Dummies


The Linksys SPA-3102 is the younger brother of Sipura's 3000. Sipura is now part of Linksys, which is itself part of Cisco. The main difference between the 3000 and the 3102 is that the latter can act as a NAT router. This is typically meant so you can connect your PC to the Linksys, and the Linksys to the LAN, without needing two LAN ports.

The 3102 unit offers the following features:

It's important to keep in mind of couple of things: This unit is...

Making sense of the 3102

The 3102 has Internet and Ethernet ports because it can be used as a router between two networks, or more realistically, between the Linksys and your PC. Setting the Router > Lan to "Bridge" just turns it into a bridge, ie. both plugs use the same IP so you can then access the 3102 through either plugs.

Once the embedded web server is up and reachable, configuring the 3102 means making changes in the Voice tab while in Admin mode (Basic or Advanced):


Important: If you already have a router, and hence, will use the 3102 as just a VoIP gateway, enable the WAN's web server, and use that port to plug the unit to the switch/hub. Alternatively, you can set the LAN from NAT to Bridge, and plug the unit using either the WAN or LAN interfaces ("Internet" or "Ethernet").

  1. Make sure the unit is connected to the switch through its blue Internet plug
  2. Connect a handset to the Phone plug, and type **** to enter the configuration menu
  3. To check the unit's IP address, dial 110#
  4. Dial 7932# followed by 1#, and 1 to enable access to the embedded web server through the Internet plug
  5. Aim your browser to http://linksys-ip/admin/voice/advanced . Some of the settings are country-specific, so you'll have to google or ask in forums for settings that those where you live.
  6. If you lost the admin's password, reset the unit with **** followed by 73738#, and confirm with 1
  7. The latest updates can be found here
  8. Sysros Syslog Desktop is a free syslog server for Windows

If you messed things up and can't connect to the embedded web server, unplug everything, power off the unit for at least 30 seconds to let capacitors drain, replug cables, and go through the above procedure to enable web access over the WAN port and get the IP address used by the unit.

One more thing: In some sections, the configuration of a 3102 differs depending on if you're going to use in stand-alone mode (the 3102 connects to a VSP directly) or with an IP PBX (the 3102 lets the PBX connect to the VSP), and whether there's NAT involved.


WAN Setup

LAN Setup

Once set as Bridge, you can connect the 3102 to the hub through its Internet or Ethernet port.




The RTP Port setting only matters if 1) the 3102 is located in a private LAN, 2) it either connects to a VSP directly or it goes through an IP PBX that is located in the public LAN, and 3) the NAT router doesn't support STUN so that you need to map ports to let incoming packets reach the 3102.

The settings in the "NAT Support Parameters" are not needed if you have an IP PBX in the private LAN to handle NAT issues, as the IP PBX will take of rewriting IP/port information accordingly. More information about this section here.

Regional (for France)

The FXS infos are only needed if you use the Phone plug to connect a handset. If the remote caller complains about echo, play with the "FXS Port Impedance", "FXS Port Input/Output Gain" settings.

More information about regional settings:

Line 1

The Phone port (ie. FXS) and the Line port (ie. FXO) must have their own UDP port. Here, we'll use 5061 for the Phone port, and 5060 for the Line port.


"PSTN Answer delay" is the number of seconds before the 3102 will call the IP PBX. This is needed to leave enough time for the 3102 to catch CID information.

The "<:1001>S0" dialplan means that incoming PSTN calls will call the 1001 extension on the IP PBX.

Make sure you use the right "Disconnect Tone" and "FXO Port Impedance" for your country.

In case of echo, play with the "SPA to PSTN Gain" and "PSTN to SPA Gain" settings.

Line-In-Use Voltage: Make sure it's lower than what it says in Voice > Info > Line Voltage: Otherwise, the Linksys will think that the line is already in use.

Adding a Linksys VoIP gateway to Asterisk

Here, we'll use an external box like the Linksys 3102 to act as VoIP gateway, ie. interface between a PSTN line and the network. If you only use SIP, you don't need to compile and configure zaptel and libpri. You'll just need to build sip.conf, extensions.conf, and voicemail.conf.

First, edit sip.conf to add an extension so the Linksys can connect to the Asterisk server:

qualify=yes ; Qualify peer is no more than 2000 ms away
nat=no ; located in the same LAN as Asterisk
host=dynamic ; This device registers with us
canreinvite=no ; Asterisk by default tries to redirect
context=internal ; the internal context controls what we can do

Next, edit extensions.conf to create a group extension so that incoming PSTN calls ring multiple phones:

exten => 200,1,Dial(SIP/200)
exten => 201,1,Dial(SIP/201)
exten => 202,1,Dial(SIP/202)
;phone number that start with 0 are sent to Linksys -> landline
exten => _0.,1,Dial(SIP/fxo)
exten => group,1,Dial(SIP/200&SIP/201&SIP/202)

Finally, connect to the Linsys embedded web server, and go to Voice > PSTN Line to add the IP address of the Asterisk server in "Proxy and Registration" > Proxy, and fill the "Subscriber Information" section with the login/password set in sip.conf for the device.

Also edit the default dial plan "Dial Plan 1" under "Dial Plans" so that the Linksys knows which extension to call when it detects an incoming call:


Launch Asterisk in console mode, type "reload" to... reload the configuration files, reboot the Linksys, and type "sip show peers" to check that the Linksys device registered correctly.

Now, call into the Linksys from a PSTN phone: The extensions listed in extensions.conf should ring.

Stuff I learned while trying to use a 3102 as a PSTN gateway on a private network, with remote IP phones behind their own NAT router and connecting to Asterisk:

Error messages with firmware 5.1.7 while booting:

<159>system request reboot
<134>++++ sip skt[0]= INVALID
<134>++++ sip skt[0]= INVALID
<151>[5061]STUN trying 0
<159>IDBG: st-0
<151>[5061]STUN trying 1
<151>[5061]STUN trying 0
<151>[5061]STUN trying 1
<151>[5061]STUN trying 2

Recent update to the 3000. Once you know its IP address by hooking up a phone to its PHONE interface and typing **** followed by 110#, make sure you uploaded the latest firmware to the unit.

Regional settings

Regional settings for France

References:, World PSTN Tone Database, and here.

Information: "le codec standard (en Europe et dans le reste du monde, sauf en Amérique du Nord et au Japon) est le G711 a-law, appelé aussi PCMA; il correspond à un échantillonnage de la voix sur une échelle logarithmique, à une fréquence de 8 kHz et sur 8 bits (le codec standard utilisé en Amérique du Nord et au Japon étant le G711 µ-law, appelé aussi PCMU; la différence entre le PCMA et le PCMU réside, entre autres, dans la fonction d'interpolation) le débit correspondant à la voix est alors de 64 kbit/s - équivalent à une communication analogique -, tout le reste correspond à des overheads pour le transport sur la couche IP"


Playing with dialplans

Securing the 3102

Make sure no one can make calls from the Net to the PSTN line, or from the PSTN line to a VoIP gateway

No connection to the embedded web server from the Net

Reliable IP Phones

Those phones are known to work well, although they'll have the same issues if there's a non-VoIP-friendly NAT firewall in the way to the Internet...

Tips & Tricks

Checking the hardware

When turned off, the SPA3102 connects the Line to the Phone socket directly, so you can check that the hardware works by just plugging a handset in the Phone plug while the 3102 is off.

In case of echo when connecting to the PSTN line

If you're hearing your own voice, the problem lies at the other end of the line, in the analog section before voice is digitized at the Central office: "In a normal phone conversation, the latency is so low that you don't notice it. Your brain automatically tunes out to its own voice when you’re talking (as long as the delay between talking and hearing isn't too long)." Another cause for echo is how far you are from the Central office, which affects impedance and audio levels

Thus, if you hear echo of your own voice, the problem lies at the other end, and, short of getting the telco to improve their local loop, or the remote user to get a better phone and/or replace their shoddy cabling, there are three things you can try:

If they hear their own voice, the problem lies at your end, and you can do the following things:

More information:

Cheap line simulator

Take an RJ11 cable, plug one end into the FXS (Line1) port on your SPA, and the other end into the FXO (PSTN) port on the SPA. That way, you have a cheap PSTN line simulator which allows you to configure the caller ID standard (by changing the Line 1 settings). Calling the number people call to reach you on Line1, will then trigger a "PSTN" call that comes in to your PSTN port.


Tunnel to IP PBX instead of STUN? OpenVPN with UDP?

Billion 7401VGPM

Router + VoIP

Linksys 3102 vs. Obi110?

Linksys 3102 vs. Minitar MVA11A? 

Caller ID is not showing

In the PSTN Line section, under FXO Timer Values, make sure PSTN Answer Delay is set to a value superior to 3 seconds.

If no caller ID name is sent by the telco, you can set what caller ID name will be sent to the PBX in the PSTN Line > Subscriber Information section (Display Name).

My syslogd is not getting debug information from Linksys

There are two locations under the Voice section:

"When PSTN stops ringing, it takes a few seconds before my Line 1 stops ringing. Why?

The SPA rings a PSTN call through Line 1 by making an internal SIP call to Line 1. When PSTN ring stops, the SPA will take a few seconds to realize that the ring has truly stopped (due to some quiet period between rings), before it can tear down the corresponding internal SIP call to Line 1. This delay should be larger than the expected quiet period between 2 PSTN rings. You can configure this delay in the < PSTN Ring Timeout > parramter. The default value is 5 (s)."


How to make direct IP calls with a Linksys 3102?

GrandStream : "Note:- You will need to have SIP Server field blank, along with NAT traversal set to NO, no STUN Server configured and Use Random Ports set to NO. You can make calls between public IPs and Private IPs under the same LAN."

... so as to avoid using an SIP PBX, and just have the Linksys ring a remote IP phone through the Net when a PSTN call comes in?

Enable IP Dialing Enable IP Dialing no

Note: If IP dialing is enabled, one can dial [user-id@]a.b.c.d[:port], where "@", ".", and ":" are dialed by entering "*", user-id must be numeric (like a phone number) and a, b, c, d must be between 0 and 255, and port must be larger than 255. If port is not given, 5060 is used. Port and User-Id are optional. If the user-id portion matches a pattern in the dial plan, then it is interpreted as a regular phone number according to the dial plan. The INVITE message, however, is still sent to the outbound proxy if it is enabled.

Provisioning tab: Should I disable this?

You only need to disable this if you're having problems with settings (particularly dial plan) reverting to vendor defaults every 24 hours. If the Profile Rule is the default (shown below), leave it.

Profile Rule: /spa$PSN.cfg

I would disable it. It is mostly used by voip providers to remotely configure the adapter.

Recommended settings for France

Set Time Zone to "GMT+01:00"

DST : start=3/-1/7/2;end=10/-1/7/3;save=1

The ATA Administration Guide has a lengthly discussion of the setting. I fussed with it and eventually got it to work after I put save=+1.

You can setup an NTP server on one of the Router tabs so the adapter will get the correct time from an Network Time Protocol server when you boot it up.

"FXO Timer Values (sec)", "PSTN Disconnect Detection", "International Control": What are recommended settings for France?

Linksys ATA Administrator Guide

Parameters that pertain to the pstn line attached to the FXO port of the adapter.

The ATA Administration Guide is the basic technical manual for the SPA3102. The manual has impedance and disconnect tone settings for France. Other regional tone settings will work with the default settings, however changes can be made to them so the sound is similiar to local settings. The Voxilla site used to have a "localization wizard" but it looks like that is now gone. The "3am" database has tone settings for a number of countries.

PSTN settings for France here.

Also, French progress tones (Dial, Busy, etc.) here.

This Voxilla site has a useful configuration wizard for a SPA3102 with Asterisk.

XLite issues

In incoming PSTN calls, how to rewrite CID so that XLite displays the actual caller's ID instead of the 3102 extension?

In outgoing PSTN calls, XLite says "Connected" although the 3102 is still dialing/ringing a remote PSTN number

How does SIP work

?'s for Voice items

Line1/PSTN Line


To allow incoming PSTN calls to ring an IP PBX server, you must enable "PSTN-to-VoIP Gateway", and configure the "Proxy and Registration", "Subscriber Information". Apparently, there's no need to add anything else (eg. PIN number + dial plan)

What are the "User1" and "PSTN User" tabs?

User1 are settings for the Line1 port. PSTN User are settings for the PSTN Line port.



What is the "NAT Support Parameters" section, including the VIA information?

These settings offer various methods for the SPA3102 to discover its own external IP address which is necessary for some type of VoIP calls, specifically IP Dialling.

The only settings you might need to use here are STUN Enable and STUN Server but if your VoIP is already working properly leave them alone.

If you have a static IP address you can use EXT IP in this section to enter the IP address.

Different settings for the adapter to help the adapter to determine its external ip address and external port number. Good description here.

What are "SIP Port" and "EXT SIP Port" for?

SIP Port is the current SIP port and EXT SIP Port allows you to specify (force) the external SIP port.

These are parameters on the Line 1 and PSTN tab used to set the sip port address for the adapter. I haven't seen EXT SIP port used.

PSTN Line Section: NAT Settings

NAT Mapping Enable is whether to use the adapter's internal network address or external ip address (if the adapter can figure it out) in the sip messages. If your Asterisk server is on the same local network as the SPA3102 you would not use this setting.
NAT Keep Alive Enable is whether or not to send a message every 15 seconds to the proxy to keep your sip port open in your local router for an incoming call.

PSTN Line section: Proxy and Registration: What are "Outbound proxy" (to use a different server for outbound calls?), "Use OB Proxy in Dialog", and "Make/Ans Call Without Registration"?

Only change these if advised by your VSP.

To give you the flexibility to use a different proxy or domain from the registration proxy.

What are "VoIP-To-PSTN Gateway Setup" and "PSTN-To-VoIP Gateway Setup"?

Control incoming (PSTN-To-VoIP) and outgoing (VoIP-To-PSTN) PSTN calls and other advanced stuff. Just make sure that both Gateways are enabled.

Parameter settings for the bridging of calls between incoming/outgoing calls on the FXO port and voip.


More information: