Configuring the Linksys SPA-3102

So, I recently picked up a Linksys SPA-3102 PTSN Gateway with one FXO and FXS port.  I wanted to use this to connect our home phone line to an Asterisk server.  Asterisk is a software based PBX system that runs on just about any linux distro.

Anyway,  I quickly discovered that configuring the SPA-3102 was not as straight forward as I had hoped.  So I’m going to post some step by step instructions to help out anyone else who may be having trouble with this device.  My instructions are very similar to those provided by 3CX. I had to tweak their instructions to get my set-up working properly.

Variables used in this example:

  • Asterisk Server IP: 10.0.0.2
  • SPA-3102 IP: 10.0.0.3
  • SIP Trunk Name: trunk_1
  • SIP Trunk Port: 5061
  • SIP Trunk Username: trunk_1
  • SIP Truck Secret: password

In my setup the Asterisk server and the SPA-3102 are on the same local network, so I don’t have to worry about any NAT issues.  I’m going to assume that you already have or know how to create a SIP trunk in Asterisk.

Configuring the SPA-3102

  1. Connect the SPA-3102 to your local network via the ethernet port labelled Internet.
  2. Connect an analog phone to the phone port on the device and dial ****, then dial 110# to get the IP address assigned to the Internet port.
  3. Hang up and then dial 7932#, then press 1# to enable http access over the Internet port.  Then, press 1 to save this setting.
  4. Now we’ll need to log in to the SPA-3102 via a web browser.  Open a browser and navigate to the IP address the device read back to you from step 2.
  5. Click the Admin Login link and then the Advanced link on the upper right side of the page.
  6. Click on the Router tab in the upper left and then WAN Setup below.
  7. You’ll want to set a static IP address for this interface. In this example I chose 10.0.0.3.  Make sure to set the proper netmask and gateway for your network as well.
  8. Now click on the LAN Setup tab, and then disable the DHCP server.
  9. Click the Submit button at the bottom of the page.
  10. Click on the Voice tab in the upper left, then click SIP tab underneath.
  11. You’ll want to change the RTP Packet size to 0.020.
  12. Disable Line 1 by clicking on the Line 1 tab and changing the Line Enable to No.
  13. Now click on the PSTN Line tab.
  14. Make sure that the Line Enable option is set to Yes.
  15. Scroll down and enter the IP address of the asterisk server in the Proxy field.
  16. Enter the same IP address in the Outbound Proxy field.
  17. Make sure that the Register, Make Call Without Reg, and Ans Call Without Reg options are set to No.
  18. Under the Subscriber Information section, enter a Display Name. I entered the name of my trunk, Trunk_1.
  19. In the User ID and Auth ID field, enter the username of your SIP trunk (trunk_1).
  20. Set the Use Auth ID option to Yes.
  21. In the Password field, enter the trunk secret (password).
  22. Make sure that in the Audio configuration section that the Preferred Codec is set to G711u.
  23. Now let’s scroll down to the Dial Plan section.  Clear out the Dial Plan 8 field, and enter (S0<:trunk_1>) where trunk_1 is your SIP trunk username.
  24. Under the VoIP-To-PSTN Gateway section, set VoIP-To-PSTN Gateway Enable to Yes, the VoIP Caller Auth Method to none, and One Stage Dialing to Yes.
  25. Scroll down to the PSTN-To-VoIP Gateway section and set PSTN-To-VoIP Gateway Enable to Yes, the PSTN Caller Auth Method to none, the PSTN Caller Defaul DP to 8, the PSTN CID for VOIP CID to Yes, and then set PSTN Caller ID Pattern field to *.
  26. Then, change the PSTN Answer Delay field to 0.
  27. Now click on the Submit Changes button and you’re done!

The above settings are what got it to work for me.  Your mileage may vary depending on your setup.

Leave a Reply

Your email address will not be published. Required fields are marked *