#VelocityConf: Mobile Performance from the Radio Up

I seem to be going to a lot of really deep, low-level talks this year. I think it's good to get a refresher and see what has happened in these spaces since I learned the first theoretical bits over 10 years ago. Unfortunately, most of the material in this talk didn't exist 10 years ago, so it was fairly new. There are obviously two types of radio we deal with on a regular basis: Wi-Fi and 2g/3g/4g.


Leaving out a lot of the detail, Wi-Fi is Ethernet over the air. This means that the collision detection and avoidance systems are exactly like Ethernet. Of course, it's been a while since we used Ethernet hubs, so the collision issues are really about whether you are trying to send while receiving, so they don't happen very often. In Wi-Fi, you may be colliding with someone using the same frequency on a different network, so it's much worse than Ethernet ever was. Because of this, the protocol is not necessarily adapted to the task of wireless communication.


The cellular protocols, on the other hand, are designed for stability and scalability. They are also designed to optimize battery life. As a result, there is a radio resource controller (RRC) that will handle assigning time slots, powers, and modulations to any data-sending tasks. Once this has completed, the controller may choose to power down the radio. Unfortunately, this power-saving mechanism also means that the first packet is often very slow, sometimes many seconds are needed just to re-create the network connection.

The key to this issue is to ensure that your mobile applications and sites respond instantly, if only to let the user know that something is happening. After that, you may be at the mercy of the network.

Reverse Tethering

I was recently on vacation and checked into a hotel that did not have free wifi. At this point, I am basically enough of an internet addict to pay the absurd amounts of money for the wifi. I can usually mitigate some of this cost by just using my Motorola Atrix to access the internet over the cell network when I didn't need the full functionality of my netbook.

However, my strategy was foiled this time. I have had an almost complete cell phone blackout in my hotel. I'm not talking about my room here. I'm talking about the entire building. Granted, I don't have a great signal when I walk outside, but I have only looked at my phone a few times to see a single bar on it.

Well, this isn't really too bad. I mean, I have my netbook, and I can pay to get on the wifi. Of course, that's per client. I guess my phone is just an expensive little brick. There are things I want to do on my phone, though. It's a source of entertainment as well as a device for calling people and looking up restaurants.

I did a little searching around. I found several forums about how to get an android phone to connect to the internet through a computer. I was pretty happy with that since most people want to do it the other way. I finally found a forum that gave me what I needed.

The software that has saved a bit of my sanity (if there is actually any left) is called Connectify. It's pretty simple to set up. I only needed the free version. It will actually let you use the wireless interface to act as an access point as well as the way the laptop gets on the internet. I was able to set it up in a few minutes and get my phone on the internet through my laptop.

I honestly wonder if I could get rid of my wireless access point and just use Connectify...

If I give that a try, I will post the results.