I want to turn off my POTS line

I want to dump my analog phone line at home. I’m just not sure if I can.

This has been building for a while. I’ve been using Asterisk for over 4 months. At this point, my home POTS line is both the most expensive and least reliable part of the whole system. It’s currently costing me over $33/month, and that’s just for incoming calls and outgoing local calls. I’ve been sending long distance calls to NuFone for over 4 months, and they’ve only charged me $10 for the privilege. That’s less then my average monthly long-distance bill used to be.

According to Asterisk’s logs, I average around 400 minutes of incoming and outgoing local phone service per month. At $0.02/minute, that’s only $8/month. I’m paying that much just for Caller ID on my POTS line. If I could drop the POTS line, then I could save around $25/month. That’d be a nice addition to my DSL speed, or it’d cover cellular data usage with a Treo on most networks.

Besides simple cost, I’m just generally unhappy with telcos. Today’s big point came from Telepocalypse. Plan on phone line charges going up another $4/month in the near future. That, coupled with my Verizon DSL upgrade saga, really makes me want to dump Verizon altogether. See TeleTruth’s “dirty phone bill” for another quick take on what’s hiding in a typical phone bill.

Unfortunately, I just don’t see how I can do it for a reasonable cost. I’m in Comcast cable-modem territory, but they want $50/month for service for non-subscribers, and they don’t offer static addresses with residential service. They might offer them with business services, but those start at $95 and go up. I’d be amazed if I could get a static address (and the ability to run servers) out of them for under $150/month. I don’t seem to have any alternatives for home broadband; it’s either Verizon DSL or Comcast cable modem. Or a T1, but that’s way more then I’m willing to spend.

There does seem to be one way out–I could move the mail and web server out of the house and into a colo server. Several providers advertise dedicated P4 boxes with reasonable amounts of RAM, disk, and network connectivity for around $50/month. I could conceivably drop the DSL and POTS line and move to a $50 server and $50 cable modem, and come out slightly ahead, but I don’t see it being worth the trouble, even if I’d have 4x the bandwidth.

Finally, even ignoring all of the connectivity problems, I’m still left with one problem–how do I dial 911 without a POTS line? 90% of the time, we have a cell phone handy, but they’re never really handy in emergencies. I haven’t seen anyone discuss how to dial 911 is a pure roll-your-own VoIP system. Do you just redirect it to some local phone number? Or do you just leave the POTS line plugged in and trust that they’ll leave it live for 911?

Posted by Scott Laird Wed, 18 Aug 2004 05:01:44 GMT


VoIP: Where to go from here?

To recap, my Asterisk-based home phone system is working nicely. It lets me make cheap long-distance phone calls using VoIP. It sends me copies of incoming voicemail via email. It lets me selectively forward (or even ignore) incoming calls based on Caller ID. Basically, it’s a completely programmable home phone system. It’s completely under my control.

And it’s sort of boring. After all of this, it’s still just a telephone. I have a fantastic amount of computer and network power devoted to emulating a 100-year-old communication tool. It’s an “inside the box” system.

I’d like to change that, but I think I’ve lived inside the telephone box for too long, and I’m having a really hard time seeing out. What should the future’s phone system look like, and what do we need to do to build it? And, while we’re building it, how to we get it to interact with the existing phone network?

All sorts of fun question pop up here:

  • Should phone (and phone numbers) be person-based or location-based?
  • Do we want to stick with phone numbers, or would name-based addressing work better. Do you want to call me at +1-425-488-9014 or sip:scott@sigkill.org?
  • How does presence play into this?
  • How long should call setup take? Is there an advantage to < 1 second call setup, like the cellular push-to-talk people keep pushing?
  • How should we differentiate between “buddy list” calls and calls from complete strangers? When we don’t know the caller, are we better off punting them to voicemail by default?
  • For semi-stable social groups, would we be better off with semi-stable “chat room”-style conference calls rather then two-party phone calls? For instance, I could set up a conference for my extended family. Everyone with the right equipment could keep a “line” open for the call whenever it’s convenient. Then, anyone in the group with something to say simply has to activate their microphone and talk to the group, and everyone can listen in and respond. This is basically just the audio equivalent of IRC; it’s not technically difficult to implement, but it has huge social implications.

I’d like to play with some of this in Asterisk, but I’m lacking a few pieces. None of the fancier things that you can do with smart phone systems really works when all you have to work with are shared home phones, like the Cisco 7940 in our kitchen. I’d really like to find a decent softphone for OS X, but as Boris Mann points out, they’re mostly stuck in the voice-as-application model, when they should be voice-as-utility. I’d love to see a OS X softphone that works just like iChat–its normal mode of operation is just a little toolbar icon. You click on it, and it gives you a couple menu options and then a list of all of your common contacts. Select one, and it dials the number and gives your a little call-management window. Incoming calls are handled via pop-up, just like iChat.

An alternative would be a PDA phone with a decent SIP client. I’ve heard rumors that Vonage will have a SIP client for the next Treo. Frankly, if the “Treo Ace” (or whatever it ends up being called) can run a decent SIP client, and it includes something besides bluetooth for wireless connectivity, then it’ll be almost impossible for me to resist buying one.

Posted by Scott Laird Mon, 09 Aug 2004 18:36:29 GMT


Continued Asterisk progress

Pulling Ethernet cable to replace a bad WiFi link seems to have fixed the audio dropouts that were plaguing our home phone system, but it didn’t do much to help the two other problems on my to-do list. Like many people using Asterisk with POTS lines, the first dozen seconds of some phone calls suffered from a strong far-end echo. Every time we talked, we heard our voices echoing back at full volume around a half-second later. It made it really hard to carry on a conversation. Fortunately, Asterisk’s echo canceling code killed it off eventually, but we had to suffer with it at the beginning of a lot of calls.

I’d heard reports that changes to the echo cancelling code in the latest Asterisk release, 1.0-rc1, had almost completely eliminated echos for a lot of people. So, I rebuilt Asterisk from source again, installed it, added echotraining=800 to zapata.conf, and restarted Asterisk. And, sure enough, the echo seems to be gone. I made a handful of test phone calls without issues, and a 15-minute call to my parents was perfect. No drop-outs, no echo, and the only noise came from their lousy cordless phone.

So, that left only one thing on my to-do list. The Cisco 7940 phones make it easy to use call forwarding–it’s one of the default softkeys on the main screen. Just press the matching button, enter a phone number, and bam, all of your calls are forwarded. Canceling forwarding is even easier. Unfortunately, the way I had Asterisk configured, all forwarded calls would use our caller-ID information. So, when forwarding our home phone to one of our cell phones, every call would look like it was coming from home, not from whoever was actually calling. Fortunately, since NuFone lets your set your own caller-ID information, it’s possible to leave the existing caller-ID info in place for forwarded calls. I just used this macro:

[macro-condsetcid]
  exten => s,1,SubString(cs1=${CALLERIDNUM},0,4)
  exten => s,2,GotoIf($[${cs1} = ${CALLERIDNUM}]?3:4)
  exten => s,3,SetCallerID(4254889999)
  exten => s,4,NoOp

In essence, it checks the current caller ID number. If the number is 4 digits or less, then it assumes that it’s an internal extension number, so it overrides it with our real phone number. Otherwise, it lets it stay as-is.

Then, I went through my extension.conf and replaced every occurance of SetCallerID(4254889999) with Macro(condsetcid). Now call forwarding works perfectly–the caller’s ID is used instead of our home phone number.

At this point, my Asterisk to-do list is essentially empty. There are a few little projects that I can pick up and play with, but there’s nothing left that needs fixed. It’s reached the point where it Just Works.

Posted by Scott Laird Mon, 09 Aug 2004 11:57:40 GMT


CommuniGate Pro does VoIP

I’m planning on doing more research on this in a while, but I should mention it now: the latest release of Stalker Software’s CommuniGate Pro email software includes basic VoIP support.

CommuniGate Pro (CGP) is kind of fascinating to me. At it’s heart, it’s just commercial email software. It does SMTP, POP, IMAP, LDAP, and web mail, all of which you can do for free with open-source software. However, if you’re a small business or ISP, and email means anything to you, and you aren’t tied to Exchange, you owe it to yourself to take a serious look at CGP. It’s fast, it’s reliable, it’s completely standards-based, it’s trivial to configure, and it’s cheap. It starts at $500 for 50 users and drops off quickly. For $2,000, you can get a 1,000 user license. Now ask yourself, how long would it take to set up a 1,000-user POP/Webmail/SMTP mail server? How much support time will it take?

I’m starting to sound like an ad. I’ll try to stop.

They also do clustered mail servers, but their previously-reasonable prices suddenly jump well into the 6-figure price range. This isn’t the way to go if you’re looking for SPOF-free corporate email for cheap.

Their more recent releases have added some Exchange-like functionality–they support MAPI- and web-based calendaring with an Outlook plugin (for an additional cost), and they’ll provide spam and virus filtering for a price.

The thing that’s always fascinated me about these guys is that they seem to be a dinky, 5-10 person outfit, but they’re able to keep adding features faster then anyone else on the market, and do it without turning their software into a complete pig. At Internap, we were amazed to discover that their basic server with SMTP, HTTP, POP, IMAP, LDAP, SSL for everything, decent logging, a web UI for configuration and for email, and a mailing list manager all fit into under 2 MB of RAM. Once it got running, with hundreds of busy users, it grew to need 15 MB or so, but that was about it. I think we only managed to crash it once or twice in two years, and that’s under a murderous load–I think I was averaging over 2,000 email messages/day for part of that, and I was rarely the busiest user. We had way more problems getting Linux to keep up with the server’s I/O load, but that’s a whole different issue–we were saturating 2 external RAID arrays for almost the entire day every day.

Anyway, the latest release (4.2) adds SIP and RADIUS to their list of supported protocols. It isn’t really intended for serious PBX-replacing VoIP, but rather for IM and voice messaging. Since Windows XP includes SIP IM software, this seems like a useful addition to CGP. It’ll do VoIP as well, but it’s based on email addresses, not phone numbers, so it’ll be hard to get SIP phones to interoperate with it (although not impossible–most of them will let you dial names, but it’s hard to enter them with a phone keypad).

Personally, I’m going to keep my eye on them over the next year or two–they aren’t very far from turning CGP into a cheap all-in-one solution for small-business communications. All they need is a dialing plan, voicemail, support for external SIP-to-PSTN devices, and maybe faxing.

One quick disclaimer–it’s been a couple years since I last used their software. I’m not a sysadmin at my present job, and I have nothing to do with out email environment. And, I’m not willing to pay $500 for my home email server, although I was tempted back in the .com days.

Posted by Scott Laird Sat, 07 Aug 2004 01:38:05 GMT


Vonage softphone for Treo Ace?

Engadget is torturing me. They have a brief report up on Vonage’s new WiFi SIP phone, and at the end of the article, they dropped this little snippet:

Oh, and they have a softphone VoIP client that’ll work on the new Treo 610/Treo Ace and other Palm handhelds on the way. We’ll obviously have way more on all of this in a few weeks.

Thanks, guys, that’s really helpful. The interesting thing that the leaked specs for the Treo Ace don’t really include a network interface that’s suitable for VoIP–it has Bluetooth, but that’s too short-range to really be practical for a SIP phone. Now, remember that the Treo Ace leak came from Sprint, who, along with Verizon, uses CDMA phones. Neither CDMA provider goes for cutting-edge phones. Even Bluetooth is usually to racy for them. Given that, I suppose that there’s a slim chance that the GSM version of the Treo Ace could include WiFi, but I’d view it as really unlikely. It’s slightly less unlikely that there will be two GSM models, one with 802.11 and one without, but I wouldn’t hold my breath for that, either. I haven’t heard a single leak that suggests that a WiFi Treo is on the way.

On the positive side, the fact that they’re talking about the new Treo and saying that they’ll provide more details in a few weeks gives me some hope that it’ll be announced before too much longer. Although I wasn’t all that excited by the initial Treo Ace leak, I’ve become increasingly interested in it as time goes on. At this point, I wouldn’t say that I’m chomping at the bit to buy one, but I’ll give it some serious consideration once it’s announced. Especially if it’s able to talk SIP to my home Asterisk server.

Posted by Scott Laird Fri, 23 Jul 2004 20:30:15 GMT


Seattle P-I on VoIP

The P-I has a nice little article on VoIP on their website today. It’s much more positive then I’ve come to expect–basically, it presents VoIP as an up-and-coming way to save money on phone service. They talked to Skype and Vonage users, as well as some industry types, and generally gave a spin-free picture of what’s possible with current consumer VoIP services.

There’s no real discussion of business VoIP usage, or anything like Asterisk, but that’s really out of scope for most newspapers anyway.

Posted by Scott Laird Fri, 23 Jul 2004 18:16:09 GMT


Wireless weirdness

Okay, this is just strange. As mentioned before, I have a Cisco 7940 IP Phone in my kitchen, currently connected to a Linksys WET11 wireless Ethernet bridge. I’ve been having problems lately with weird connection failures, which I assumed was caused by low signal strength.

That is, until I looked at my logs. Apparently the phone has left my network and migrated onto one of my neighbors’ networks, because the phone is now logging in from Comcast’s IP space. This is strange on several fronts–first, the WET11 is supposed to be hard-coded to use my SSID. Second, I’ve never seen any of my neighbors’ networks from my PowerBook, and I’ve looked around a few times, just to see if I could track down the source of my interference.

I’ll try moving everything to a different channel tonight and see if that helps. Failing that, I guess I’ll have to pull out my drill and start pulling Cat 5 through the basement this weekend.

Posted by Scott Laird Thu, 22 Jul 2004 16:20:47 GMT


New rates for NuFone

It looks like NuFone has finally listed their rates on their website. I’ve been happy with their services, but getting information out of them has been like pulling teeth.

On the plus side, their US rates have dropped from $0.0295/minute to $0.0200/minute. That’s $1.20/hour. My monthly long-distance bill has dropped off to almost nothing since I started using VoIP.

Just out of curiosity, I ran a quick search to see which countries I could call for under $0.05/minute. This doesn’t mean that all numbers are cheap (calls to mobile phones tend to cost extra), but that at least one part of the country (the capital city, if no where else) has cheap telephone access:

Argentina, Australia, Austria, Belgium, Brazil, Canada, Chile, China, Czech Republic, Denmark, Estonia, Finland, France, Germany, Hong Kong, Ireland, Israel, Italy, Japan, Luxembourg, Malaysia, Mexico, Netherlands, New Zealand, Norway, Peru, Portugal, Russia, Singapore, South Korea, Spain, Sweden, Switzerland, Taiwan, US, United Kingdom

In other words, I can call pretty much every industrialized country in the world via VoIP for less then my ILEC charges me to call numbers 10 miles away.

Posted by Scott Laird Wed, 16 Jun 2004 22:57:00 GMT


Hi-fi phones

Network World is reporting that ShoreTel is about to start shipping VoIP phones that support “hi-fi” codecs. Specifically, they’re going to be using up to 256 kbps for 16-bit, 16 kHz audio, which could sound a lot better then the 8-bit, 8 kHz audio stream that has been universal for decades.

I’ve been wondering when this was going to happen. In a LAN environment, there’s no real reason to limit yourself to 64 kbps audio. Even when talking over the Internet at large, you should be able to find a decent codec that’ll give you better sound quality while still using less then 64 kbps. On the other hand, we’re all really familiar with the compression inherent in standard telephones; there’s a chance that better sound quality could actually backfire by making IP phones sound less like the old phones that we’re all familiar with. If someone wants to send me a pair of Asterisk-compatible hi-fi phones, I’ll report back on how they sound.

Posted by Scott Laird Wed, 21 Apr 2004 17:32:22 GMT


Asterisk, the OS X Address Book, and cheap calls without dialing '1'

I am a happy man. I have, after four years of trying, achieved nerdvana. I am down to one single address book, accessible everywhere. It’s shared between my computer, my cell phone, my palm, my wife’s Mac, her phone, and finally, as of yesterday, our home phone. I can add new contacts anywhere, and they show up everywhere automatically.

It’s actually even more pervasive then that; the same address book entries re-write incoming caller ID and control our home phone’s ringer, so we can tell the difference between friends and telemarketers without even looking at the caller ID display. The best part is that it all just works. Setting it up in the first place took a bit of work, but once it’s running, all I have to do is drag cards around inside of the OS X Address Book, and everything else follows along on its own.

The first part of this whole operation was to get data out of the OS X Address Book and into a form that I could work with on one of my servers at home. Towards that end, I wrote ab2vcard, a simple tool that extracts vCards for every address book entry and stores them in a directory. If you set up Subversion and use the right flags on ab2vcard, then all of your vCards will be checked into Subversion and automatically replicated onto the Subversion server. I run ab2vcard from cron, so every two hours, all of my addresses are automatically sent to my server at home.

Next, I wrote asterisk-vcard-cid so I could use the names in my Address Book for Caller ID instead of the nasty stuff that Verizon sends me. If you copy the ‘vcardcid-cron.sh’ file that comes with it onto your Asterisk server and run it every couple hours, then it’ll do all of the hard work of checking changes out of Subversion and shoving them into Asterisk. The way I have it set up, I have 5 groups in my Address Book:

  • Home CallerID
  • Home Ring 1
  • Home Ring 2
  • Home Ring 3
  • Home Ring 4

Any contacts in the ‘Home CallerID’ group will automatically be added to the caller ID DB in Asterisk. Anyone in one of the ‘Home Ring’ groups will have ‘distinctive ring’ turned on when they call. That was really easy with Asterisk. All I had to do was add a macro like this:

[macro-setalertinfo]
  exten => s,1,DBGet(ALERT_INFO=distinctivering/${CALLERIDNUM})

Then, I make sure that all incoming calls use this macro. Here’s my complete outside line macro:

[macro-outsideline]
  exten => s,1,SetCDRUserField(Outside (${CHANNEL}))
  exten => s,2,LookupCIDName
  exten => s,3,SetMusicOnHold(random)
  exten => s,4,Macro(setalertinfo)
  exten => s,5,LookupBlacklist
  exten => s,6,Dial(${PHONES},13,Ttmr)
  exten => s,7,Answer
  exten => s,8,Goto(outside-ivr,s,1)
  exten => s,106,Wait(3600)
  exten => s,107,Hangup

This handles caller-ID rewriting, blacklisting, distinctive rings, adds extra logging, and sends unanswered calls to voicemail.

One little note on distinctive ring: the way I’m using it, it probably only works right with Cisco SIP phones, although other SIP phones that support distinctive ring will work with a few changes to the vcardcid-cron script.

Finally, I’ve added a mechanism for tying the same set of vCards into the speed dial directory on Cisco SIP phones. I’m using the 7940, but the 7905, 7912, 7920, 7960, and 7970 should all work. Each of these phones has the ability to download XML programming objects over HTTP. There aren’t a lot of great references out there, but this one is fairly complete and seems accurate so far.

The directory tool that I wrote, cisco-phone-directory, runs as a CGI on a web server. If you set up the Cisco phone right, every time you select ‘external directory’ from the directory menu, you’ll be prompted with a search screen. Enter a few letters from the name that you’re looking for, and you should get a nice, short list of names to choose from. At this point, it works with almost no fuss, and almost no user training.

Er, except for one little problem. All of the numbers in my address book look like (206)-555-1212. Once you strip the punctuation, you’re left with 10 digits. The problem is that I need to dial a ‘1’ before I call long distance numbers, and it’s not really obvious which numbers are long distance and which aren’t. I can dial most numbers in the 206 area code for free, and about half of the numbers in 425, but there’s no simple way to tell which numbers are which. Since I’m cheap, I want to send toll-free calls out over a real phone line, because it doesn’t cost me anything, while I send toll calls to NuFone over the Internet, because they cost about half as much per minute.

In order to do that, I need to know which numbers are local, given my phone’s area code and exchange. So, enter yet another tool: asterisk-lca-map. If your home number was (425)-488-1212, then you’d run it from the command line like this:

$ asterisk-lca-map.rb 425 488 1212 'Macro(dialanalog)'

and it’ll produce a dial plan that sends all local calls out ‘Macro(dialanalog)’, like this:

exten => _206200XXXX,1,Macro(dialanalog)
exten => _206202XXXX,1,Macro(dialanalog)
exten => _206203XXXX,1,Macro(dialanalog)
exten => _206204XXXX,1,Macro(dialanalog)
exten => _206205XXXX,1,Macro(dialanalog)
exten => _206208XXXX,1,Macro(dialanalog)
exten => _206210XXXX,1,Macro(dialanalog)
exten => _206213XXXX,1,Macro(dialanalog)
exten => _206214XXXX,1,Macro(dialanalog)
exten => _206215XXXX,1,Macro(dialanalog)

You can then add a couple extra rules at the bottom to handle 800 numbers and toll calls:

exten => _888NXXXXXX,1,Macro(dialanalog1)
exten => _1888NXXXXXX,1,Macro(dialanalog)
; continue on with 877, 866, 855, and 800

exten => _NXXNXXXXXX,1,Macro(dialnufone1)
exten => _1NXXNXXXXXX,1,Macro(dialnufone)

The ‘dialanalog1’ and ‘dialnufone1’ macros prepend a ‘1’ to the number that they’re calling. When all of this is done, dialing ‘2062001111’ goes out the POTS line as-is, while dialing ‘2125551212’ goes out NuFone as ‘12125551212’. Everything Just Works, and users don’t have to know when to dial a 1 and when not to. They never actually need to dial the 1 at all, although if they do, it’ll still work. And that’s what I’m aiming for–the back end is complex, because it has to interact with complex parts of the real world. The front end is dead simple, though, because I can handle all of the hard bits without bothering the user. They can just dial the phone number, and I’ll route it out the cheapest connection automatically.

Posted by Scott Laird Fri, 09 Apr 2004 08:23:06 GMT