Wednesday, March 27, 2013

Interfacing between the Serval Mesh and Cellular Networks (Part 1)

A number of people now have asked whether a Serval Mesh can be connected to the cellular network, e.g., to allow people living just beyond the range of cellular service to be able to make and receive mobile telephone calls.

This would be best done using a cellular modem and a bit of software integration to make use of it, so that the cellular audio can be passed through digitally.  However, most people who have asked about GSM/mesh gateways have indicated strongly that the solution must use only Android phones, and not require any soldering.

This is not unexpected, since it is hard to get new equipment into areas where disaster, rural, remote or poverty are at play. The same goes for areas impacted by war or unrest.

So we started thinking about how we can do this.

Unfortunately, most models of Android phone don't let you access the audio from the cellular call directly, which rules out the easy option of writing some clever software that can run on a phone.

However, all is not lost.  We can use two phones, with one making the cellular end of the call, and the other handling the mesh end of the call.  Then by using headsets to do some good old-fashioned acoustic coupling, we can record the cellular audio through the microphone of the mesh-connected phone, and play the audio out the speaker of the mesh-connected phone and into the microphone of the cellular-connected phone.  A picture should help illustrate how this would be arranged in practice:


Yes, it really is that simple. And that ugly.  

For extra simple and ugly, you could just tape the two phones together with one upside down so that the speaker and microphones are close enough to couple the audio.

Of course it has some drawbacks, notably the need for two phones instead of one, and the degredation in audio quality that is almost certain to occur.  However, initial tests reveal that the audio quality is better than might be expected, and quite likely to be very usable.

Where we are up to now is that we have a student working on prototyping this.  He has got to the point where a call from on the mesh can trigger an outbound call to the cellular network, and has the two ends of the audio playing.  You can see this in the video below:



The next step, and the one that will get us to a complete usable prototype for mesh to cellular calls (the other way around is a bit trickier) is to make the Serval Mesh software know about wired headsets so that it can route the audio through that path.

Wednesday, March 6, 2013

Testing Serval Mesh Helper Prototypes in Moores Valley

Where we have been staying in Moores Valley near Wellington, NZ, the mobile phone coverage drops out half-way along the road, and power and even the bridge are cut from time to time by fallen trees and the like -- all natural hazards of living in such a beautiful location.
Despite the isolation, it is easy to understand why people choose to live in places like Moores Valley


So for communities like this, there is real value in being able to easily make a backup communications system -- which is just what we designed the Mesh Helper concept to enable.  By placing a few Mesh Helpers in homes, we can provide those houses with text and file communications amongst themselves, and possibly voice later on.  With a bit of extra effort, we can then connect the local mesh to the outside world as well, but that's something we will work on later.

So I thought I would go for a wander up the road and see how far away I could get while still having a link.

Because I wanted the test to be reasonably realistic for this use-case, I just put one Mesh Helper on a book case in the patio here.  The only special effort I made was about five seconds to generally point the antenna up the valley in the direction I was going to head -- and that is only necessary in these prototypes, because the antenna and large battery are sitting together in a bucket. 

We could do much better by placing the Mesh Helper on a high point, such as on top of a building, but I really wanted to see how it would perform with the kind of placement that could be reasonably expected by non-technical people who just want to use it, without investing lots of time, money or energy.

I then proceeded to carry the other Mesh Helper up the valley road, and check the signal strength at every house number.  As most people in the valley live on 10 acre sections, the houses are actually some way away from the road.  So the results may not be 100% accurate.  However, the road is generally lined with screening vegetation, which actually makes it a more challenging environment than adjacent to the houses themselves, which are mostly surrounded by paddocks.

Typical Road-Side Environment


Taking a measurement from on a letterbox along the road.
 I plotted the results on a Google Map, and colour coded the measurement points according to signal strength, with blue being best, yellow least, and red meaning no signal:



The result? We were able to obtain a link over distances of up to 1.27km, which is far enough to reach at least 13 houses in that direction, not counting those that might be reachable on the other side of the road, or on either side in the opposite direction along the road.  This means there are perhaps 50 homes that can be reached from one site.  

This is very important, because it means that a network can be constructed in a setting like this, even with only one out of 50 homes having a Mesh Helper.

Remember also that this is 1.27km between a pair of fairly casually placed Mesh Helpers. 

With units placed in good vantage points (and some of these properties include areas close to the local ridge line) with clear line of sight, we already know that links of >3km are easily possible.

Also, once we finish rewriting the radio firmware, we will be able to mesh many of these Mesh Helpers, we will be able to create links many times the range of a single Mesh Helper link.

Thus it might well be possible to connect communities in  rural, remote and developing settings over tens of kilometres.