https://gekk.info/articles/ata-config.html
gekk.info << articles
Configuring SPA122 ATA For Dial-Through
Two laptops connected via modem over a VoIP ATA
[Two laptops communicating over modems using a VoIP ATA (don't mind
the two screens not matching - Windows 98 Hyperterminal isn't so
hot)]
Table of Contents:
Intro
Configurations
Using One ATA
Using Two ATAs
Calling Over The Internet
Troubleshooting
Now What?
Intro
This guide will explain some ways to set up a VoIP ATA so that you
can place calls between computers with modems (although any other
pair of telephone devices will work.)
When done, you will be able to:
* Connect two or more computers with modems directly together
* Connect a computer with a modem to another one elsewhere in your
house over your LAN
* Connect a computer with a modem to another one in someone elses
house over the internet
To make this work, you will ideally have:
Cisco SPA122 ATA
* A Cisco SPA122 (pictured above)
This procedure is written for that device specifically, and there are
tons of them on eBay for under $30.
However, it is pretty easy to adapt it to any of the following
devices:
* Cisco SPA2102
* Linksys SPA2102
* Linksys PAP2T
* Sipura SPA2100
All of these are literally the same device, with different firmware.
It'll probably only take you a few minutes to figure out how to find
the matching fields, so if you have any of these, use it.
You cannot do this with any ATA made by Grandstream. You may be able
to use ATAs from other vendors, but I do not cover those procedures.
There are two important caveats to these devices:
First, make sure the power supply you get with your ATA is 5V / 2A.
There are identical-looking 5V / 1A adapters, which will work until
you ring one of the ports; then the device will crash and reboot.
Second, all SPA devices have a feature that lets them be locked to a
particular VoIP carrier.
To reduce this chance, buy one that comes in a Cisco retail package
if possible; failing that, don't buy one that has a VoIP provider's
logo on it; if all else fails, just make sure it can't reach the
internet and you should be okay.
A really good reason to buy a SPA122 specifically is that it is the
only model in this line that has a hardware factory reset button; the
others are very irritating to reset.
Configurations
Using a single ATA
Basic Network Setup
1. Plug in power, but do not connect to your LAN.
2. Plug in a PC to the Ethernet port - the yellow one, not the blue
one
3. You'll get an IP eventually. (If you don't, factory reset the
device (hold the button for 30, wait five minutes and try again))
4. In a web browser, go to 192.168.15.1
5. Log in as admin / admin
6. Go to Administration, then User List
1. Edit admin
2. Change the password to something new, whatever you like - if
you don't do this, the next step will refuse to work.
7. Go to Web Access Management
1. Enable Remote Management
8. Plug the blue Ethernet port into your LAN, not the yellow one!
9. Go to the Status page, then Internet Status, and find the IP
address
10. Plug your PC back into your normal network
11. Put that IP into your web browser
12. You should get the config interface. Now you can access the web
config from anywhere on your network.
You should be aware that the SPA122 acts as a full-blown broadband
router by default - anything plugged into the yellow port will be
NATed to the IP on the blue port.
If you'd like, you can "bridge" the two ports so you can plug another
device into the yellow port and connect it directly to your LAN.
To do that, just go to Network Setup, then set Networking Service to
Bridge.
VoIP Setup
Once you have web access to the SPA as above, you can configure the
ports. We will use the bogus number 9095551010, but if you want to
use another one, just replace it (in yellow) below.
1. Log into the web interface
2. Go to the Voice section, then Line 1
1. Set Make Call Without Reg and Ans Call Without Reg to yes
2. Set User ID to 100
3. Scroll down and find Dialplan, and replace its contents with
the following:
o (*xx|[3469]11|0|00|[2-9]xxxxxx|1xxx[2-9]xxxxxxS0|
xxxxxxxxxxxx.|<9095551010:101>S0<:@127.0.0.1:5061>|)
4. Under the Audio Configuration section, set everything that
says Fax to no
5. Click Submit and wait about two minutes, then click on the
Voice tab again if it doesn't redirect
3. Go to Line 2
1. Set Make Call Without Reg and Ans Call Without Reg to yes
2. Set User ID to 101
3. Scroll down and find Dialplan, and replace its contents with
the following (it's different, so don't just reuse the first
one!):
o (*xx|[3469]11|0|00|[2-9]xxxxxx|1xxx[2-9]xxxxxxS0|
xxxxxxxxxxxx.|<9095551010:100>S0<:@127.0.0.1:5060>|)
4. Under the Audio Configuration section, set everything that
says Fax to no
5. Click Submit and wait about two minutes, then click on the
Voice tab again if it doesn't redirect
4. Configuration is complete!
This config instructs the ATA that if you dial this bogus number from
either port, it should just immediately call the other port.
Leave the ATA plugged into a network (it won't work without some kind
of network connection,) connect modems to both ports, tell one to
listen for connections, and then have the other one dial 9095551010,
and you're off to the races! See the Troubleshooting section if you
have problems.
Using two ATAs
Note: I have not tested this for lack of hardware, but I have little
doubt that it will work. Let me know if it doesn't.
In this config, you'll call between two ATAs in your house, on the
same LAN.
There are countless ways that interfacing two ATAs could work. I'm
going to explain how to do this with two identical SPA122s. If your
other ATA is another model, you'll need to figure out how to adapt
these steps to that model.
Configure two SPA122s, exactly as in the "Using one ATA" section, but
with these changes:
1. Make sure you have fixed IPs on both devices
1. Under the IP settings in the Network section, assign a static
IP address to each SPA; let's say 192.168.1.100 for the first
one and 192.168.1.101 for the second.
2. You could also make a static DHCP lease if you know how to do
that.
2. When you assign the User ID field to each line, use unique
numbers on both devices, like this:
+ ATA 1, line 1: 100
+ ATA 1, line 2: 101
+ ATA 2, line 1: 102
+ ATA 2, line 2: 103
3. Since there are now four ports that can all call between each
other, we'll use a more complex dialplan that assigns an
"extension" to every port:
1. Use this Dialplan for both lines on both ATAs:
(*xx|[3469]11|0|00|[2-9]xxxxxx|1xxx[2-9]xxxxxxS0|
xxxxxxxxxxxx.|<9095551010:100>S0<:@192.168.1.100:5060>|<
9095551011:101>S0<:@192.168.1.100:5061>|<9095551012:102>S0<:@
192.168.1.101:5060>|<9095551013:103>S0<:@192.168.1.101:5061>
|)
2. Remember to replace the IPs (in blue) with the ones you used.
3. You can change the phone numbers (yellow) for each port as
you see fit.
After doing all of the above, you will now have two ATAs (at the IPs
in blue) that can call between any of their ports (the extensions
defined in lavender) with the bogus numbers (defined in yellow.) So
if you're on ATA 1 and you want to call port 1 on ATA 2, you call
9095551012, and if you're on ATA 2 and you want to call port 2 on ATA
1, you call 9095551011.
This configuration can be used on a LAN, so you can put the two ATAs
in two different rooms. You might also be able to plug the two ATAs
directly into each other, using the blue Ethernet jacks, and have a
self contained four-line telephone network, but I haven't tested that
yet.
Calling Over The Internet
Note: I have not tested this for lack of hardware, but I have little
doubt that it will work. Let me know if it doesn't.
Assuming you and a friend both have ATAs you want to call between,
configure them the same as the last section, with the following
changes:
1. Assuming you're behind a normal internet router, you'll need to
forward UDP ports 5060 and 5061 to the ATAs on both ends.
2. Build your dialplans just like above, but replace the private IP
of the other ATA with your friends public IP, meaning:
1. In your ATA, replace 192.168.1.101 with your friends WAN IP
2. In your friends ATA, replace 192.168.1.100 with your WAN IP.
That should be all that's needed.
Troubleshooting
This should just work, but here are a couple things you can do if it
doesn't:
1. Test basic dialing functionality:
1. Get a plain, basic telephone and plug it into one port
2. Try to dial 9095551010. Regardless of what's plugged into the
other port, you should hear ringing. If you hear busy signal
or dead air, you missed a config step.
3. If you have a second phone, plug it into the other port. Test
dialing 9095551010 from either one; it should ring the other
set and you should be able to pick up and talk.
4. If all of the above works then there's nothing wrong with the
ATA dialing
2. Apply data optimization settings:
1. The instructions given earlier include the necessary step of
disabling fax detection, but if that isn't enough, you can do
this too.
2. In Line 1 and Line 2, apply the settings below. They will
tell the ATA not to try to "help" and should cause it to just
pass through audio unmodified.
1. After applying the settings to Line 1 and hitting Submit,
make sure you wait for the page to reload before moving
on to Line 2.
3. In the Network Settings section:
o Network Jitter Level: Extremely high
o Jitter Buffer Adjustment: No
4. In the Audio Configuration section:
o Preferred Codec: g711u
o Second and Third Preferred Codec: Unspecified
o G729a Enable: No
o Silence Supp Enable: No
o Echo Canc Enable: No
o Everything that says Fax: No
o Modem Line: Yes
3. If you're not getting any dialtone, check that the SPA has an
active Ethernet link on the blue port. If it doesn't have a
connection and a valid IP, it'll shut off the voice module.
4. You will not get a 56k connection speed no matter what you do -
the V.90 and V.92 specifications explicitly state that the modems
you have ("analog modems") are only capable of originating a 33.6
connection. You need special ISP equipment to originate a 56k
connection.
Now What?
As I said earlier in this document, there's a big question of what to
do once you've gotten the dialing part taken care of. I'm still
working on this part, but here are some starting points.
Internet Access
One of the most obvious end goals is to get online. You'll need a
host system for this, something that can connect to your home
internet that also has a modem. I used a 2012 Dell laptop for my
tests.
I was able to set up RAS on Windows Server 2003, dial into it from
Windows 98 on a Pentium 3 laptop with no ethernet jack, and get
connected at 33.6kbps. Because Windows supports software compression
for dialup connections, I'm able to get a sustained 14KB/s of
throughput with ideal data.
You can also do this on Linux (here's a guide for doing it with a
Raspberry Pi specifically), but personally I find it much more
irritating and broken. Namely, I couldn't actually get it to work - I
tried, and it just wouldn't go, and I don't know why. The Windows
approach is finicky too, but I'm able to replicate my steps there,
whereas on Linux I just plain can't, so my rec is to just do it on
Windows.
Direct-Connection Networking
There's a lot of older software that supports direct dialup - all DOS
multiplayer games, for instance, as well as some early Windows
multiplayer games. If you're looking for something to try this out
with a friend, download the Doom 95 shareware release - it supports
direct dialup multiplayer and should run on just about anything,
albeit pretty slowly on some machines.
You should also be able to do this with some file sharing software
and communication apps like Netmeeting, though I haven't tried any of
that.
Direct System Access
Another notion that might come to mind is the ability to dial in to a
system, like an old Unix or VMS machine, for instance, or a modern
Linux system, and get connected directly to a shell account.
This is really no different than just plugging directly into the
serial port on the machine in question, except that you need
something that will acknowledge an incoming phone call from a modem
and start a new login process. On Linux that's mgetty. You can adapt
the instructions from the Raspberry Pi guide for this - just set up
your dialin user with /bin/bash instead of ppp to get a shell after
dialing in.
---------------------------------------------------------------------
If this was interesting to you, or if you did something interesting
with it, email me: articles@gekk.info
If you like my work, consider tossing me a few bucks. It takes a lot
of effort and payment helps me stay motivated.
List of Articles