Category Archives: Software

New Business and Blog post

Things are really starting to come together for my new business, Swiftlet Technology. I’m very excited to be dedicating my time to this project: Open Source Wireless Mesh Networking. Check out my most recent blog post on that site ( for more information about the hardware that we are building, and stay tuned for more information about the software and the Kickstarter campaign!

Asterisk 11 + Google Voice: Multiple Lines

Introduction: Coexistence

My neighbor and I share an internet connection; we are very good friends and this affords us the opportunity to barter and share quite a few things. In order to help him slim his monthly costs, I’ve offered to set up the same service for him that I have: free “land-line” phone service through Google Voice. This requires some clever design in order to allow us both to route calls the way we want to. In this post, I will detail the configuration for supporting multiple Google Voice accounts through one Asterisk server.

Background: Configuration, Continued

This post assumes a configuration based on my previous post: Asterisk 11 + Google Voice. In that post, I start from scratch installing an Asterisk 11 service on Ubuntu.


Making this configuration work is all about context. Asterisk Contexts allow certain phones to call each other, but more importantly, define where incoming calls go.

The configuration is simple: There is one context for all of the simple extensions (my neighbor and I call each other directly, not over the PSTN) and a separate context for each Google Voice number. Each specific context includes 10-digit rules for dialing traditional phone numbers, a trap to catch incoming calls (with no extension specified), and the main context.

Now, for the actual config files.

res_xmpp.conf remains as before, only add an entry for each additional Google Voice account you wish to employ:

statusmessage=Asterisk Phone

statusmessage=Asterisk Phone

In motif.conf, add one entry for each GV account therefore bridging the Google account to the Asterisk context:



Assuming you have already set up phones in SIP, the only thing left is to specify your contexts in extensions.conf:

exten => 200,1,Dial(SIP/200,60) // My SIP phone
exten => 201,1,Dial(SIP/201,60) // My neighbor's SIP phone
exten => 202,1,Dial(SIP/202,60) // Second phone in my house

exten => s,1,NoOp() // Catch calls coming into my context without an extension
 same => n,Wait(1)
 same => n,Set(crazygooglecid=${CALLERID(name)})
 same => n,Set(stripcrazysuffix=${CUT(crazygooglecid,@,1)})
 same => n,Set(CALLERID(all)=${stripcrazysuffix})
 same => n,Dial(SIP/200,20,D(:1)) // Send them to my phone

// Catch calls going out of this context and use my Motif account
exten => _+1NXXNXXXXXX,1,Dial(Motif/mine-motif/${EXTEN},,r)
exten => _1NXXNXXXXXX,1,Dial(Motif/mine-motif/${EXTEN},,r)
exten => _NXXNXXXXXX,1,Dial(Motif/mine-motif/${EXTEN},,r)

include => home-context // Adds all standard SIP phones (above) to the context

exten => s,1,NoOp() // Catch calls coming into my neighbor's context without an extension
 same => n,Wait(1)
 same => n,Set(crazygooglecid=${CALLERID(name)})
 same => n,Set(stripcrazysuffix=${CUT(crazygooglecid,@,1)})
 same => n,Set(CALLERID(all)=${stripcrazysuffix})
 same => n,Dial(SIP/201,20,D(:1)) // Send them to my neighbor's phone

// Catch calls going out of this context and use my neighbor's Motif account
exten => _+1NXXNXXXXXX,1,Dial(Motif/neighbor-motif/${EXTEN},,r)
exten => _1NXXNXXXXXX,1,Dial(Motif/neighbor-motif/${EXTEN},,r)
exten => _NXXNXXXXXX,1,Dial(Motif/neighbor-motif/${EXTEN},,r)

include => home-context // Allows my neighbor to call either of my phones


As I’ve said before, Asterisk is incredibly powerful. There is so much you can do with it if you even start to understand it! As before, please leave any feedback in the comments below; I would love to know how it’s working for any of you.

Asterisk 11 + Google Voice

*** Update ***

Unfortunately, Google has decided to end support for the XMPP protocol in May of 2014. I will keep the post here in the hope that Google releases a new API, but also to share that information with any searchers. As of April 2016, the service is still operational, but there’s no telling for how long that will be the case.

Introduction: History

Earlier this year, the company I work for, Laird Technologies, converted their phone system to Cisco IP phones. In the process they threw out all of their old IP phones which were used with their Asterisk system. I acquired these, all Grandstream products (mostly GXP2020’s, 1 or 2 GXP2000’s and even a HandyTone-286!) and I had some ideas about what I could do with these, but I mostly just wanted to play around: set up phones around the house, make a doorbell/intercom system, etc. After I started reading and Asterisk and how people are using it, I got the idea to set up my own “land-line” service using Google Voice.

I think the first thing to understand about Asterisk is that it is a hugely powerful tool; Continue reading

Foray into Console Hacking

I feel compelled to open each blog post with “It’s been quite some time since my last blog post”, but maybe that’s just a sign I need to change my expectations. Regardless, today I want to tell you about my latest technological experiences.

About 2 years ago (late 2009), I became interested in what it would take to hack a Nintendo Gamecube in order to play “Backed up” game discs. As a poor college student this was primarily from my motivation to get something for really cheap. 🙂 So, I went on eBay and found a great deal: The console, 3 controllers, Continue reading

Going Mobile (and first published Android App)

Hello dear readers, It has been about a month since I last wrote you, but that seems par for the course. A lot has changed in the last month; Shannon and I got married (I still need to update the “about me” on my main page), have moved to Flint, and both gotten jobs! It’s been a whirlwind ride but oh so satisfying.

One of the relatively minor changes I’ve made in the past month is getting a data plan and Android phone (and getting rid of the trusty Palm Treo 700wx). This has been awesome (although never as awesome as getting married) and the relatively constant plug into the internet has been a good thing but has definitely needed to be moderated a couple of times. The motivation to get a data plan was two-fold: Continue reading

Web Application Idea


Good Evening! I haven’t blogged for a while so I decided that a good comeback post would be about an idea I’ve had for a web application.


One of the problems I have come across quite a bit in my downloading and using of software (primarily open-source, but also some closed-source) is that, typically, the people who test the software before releasing it into “the wild” are the very same people who are developing that application. You might think this would be a good thing, (if the developers are the ones writing it, they must now how to test it best, right?) but it turns out, according to many psychologists, that when we’re looking for something we can find it pretty easily but if we aren’t looking for it we’ll often miss very obvious things.

In summary, I would say that taking on the paradigm of the user will yield far greater discovery of bugs and inconsistencies than taking on the paradigm of the developer.


Many application developers can have a difficult time shifting to the user paradigm in order to test their own software because they are so familiar with what it took to get it to where it is and what’s going on behind the scenes (almost as a parent often does not notice their own flaws in their child); Continue reading

Google Calendar Windows Task Connector

Welcome, I’d like to share with you about a project I began working on recently. I originally read about the idea on Lifehacker when they posted a clever Linux hack for configuring the Linux Cron using a Google Calendar as a front-end (this project is called GCalCron, I give all credit for the idea to that developer).

Regardless, I decided that I would like to use this software on Windows and set out to find an alternative for use in that lesser operating system. A few Google searches later, I was still unsatisfied and decided to look into making one for myself. I should also make the disclaimer that I am not a software developer, just a tinkerer. With that, though, I started exploring the Google Calendar API to see how feasible this would be. I was incredibly pleased to find a very well documented .NET library for the Google Calendar API and, at that point, decided to learn C#. Continue reading