GPRS and Linux get mobile access on track

47
– by David “cdlu” Graham
In May, I acquired a GPRS PC Card with an unlimited data plan from Canadian cellular service provider Fido. I asked the Fido clerk whether Linux was supported on Fido’s GPRS service. He wasn’t familiar with what a Linux was, but he wished me luck. At home I did a Google search for Fido service and Linux and did not turn up any useful information. Was I going to be stuck using Windows for mobile Internet connectivity?

With the card came a Windows installation CD and strict instructions to install
it only once, lest I wipe out the SIM card, a problem that could not be remedied over the phone.
I performed the initial installation of the GPRS card in Windows on my laptop, which initialised the SIM card. I was fairly sure I would not be able to do that in Linux. My next step was customer service.

I have been using Fido for my regular cell phone service for about a year and a half, and have always been impressed with their telephone support, even if their network coverage area is pretty lousy. Knowing that even if they didn’t know what planet I was from, they would be friendly, I called their tech support number from my cell phone, and asked for help running my GPRS card in Linux.
Very quickly I was turned over to an actual technician who was clearly unused to dealing with customers, but who was both helpful and instrumental in my success in using GPRS from Linux.

It turns out that the GPRS PC Card is little more than a glorified modem. The technician gave me the numbers I needed to log in.
Using pppconfig I told my Debian GNU/Linux installation that the dial-up number is ‘*99#’ and that the login and password are both ‘fido.’ Authentication is actually done with the SIM card and is handled by the hardware — the operating system need not be involved.

This was wonderful. It worked flawlessly. I connected my laptop to the Internet and used ssh to log in to my home computer.

All of a sudden my connection dropped.

A quick check of my system logs showed that the PPP daemon had given up on the connection. The GPRS service did not respond to repeated LCP ping requests, so the PPP daemon assumed that the service had died and it disconnected.

I added the line lcp-echo-interval 0 to my /etc/ppp/peers/fido file and reconnected. That finally gave me uninterrupted mobile Internet access.

That was the good news. The bad news was the connection speed. GPRS, which is supposed to run at about 56Kbps, ran at a real rate of about half that, with a 500ms minimum latency. However, since I was using console tools such as lynx and ssh, this was more than adequate to provide NewsForge readers with NewsVac stories from wherever I happened to be.

So where was I? Why did I want this silly service?

Well, I am a railfan. I chase freight trains back and forth across southern Ontario. I have a Web site dedicated to it, and since February I have taken more than 5,000 photos and hundreds of videos of trains, train cars, train tracks, and train paraphernalia.

When I’m out at the tracks, I still need to come to work. I need to log in to NewsForge, sort through submissions, look for relevant news, and keep readers up-to-date with the latest developments in Linux and Open Source. With this device, my colleagues can’t tell whether I’m at home or at the rail yard.

Since acquiring my wireless Internet service in May, I have found new and helpful uses for it. With GPRS running and a Wi-Fi PC Card in the second slot of my laptop I can provide wireless Internet access to my friends when we go railfanning together. I have a 1,200-watt inverter in the car with enough power to keep several laptops (and maybe a microwave and fridge) going through a whole day. We can all get on the Internet together, with network address translation provided by my Linux laptop.

GPRS, Linux, and my big power inverter came in handy in August when Ontario, Ohio, New York, and several other US states were hit with a massive power blackout. While my neighbours told ghost stories by candlelight in their backyards, I ran an extension cord from my car to my back porch, set up a TV, DVD player, my laptop, and some lights, and was on line over GPRS before my UPS went on the desktop.
As my neighbourhood went hours without electricity, I watched movies, cooked, and checked email over GPRS.

Most recently, I have connected the cheap GPS I use for navigation assistance to the serial port of my laptop. I run a small script that takes my current speed, heading, and location and sends them to a Web page where the information is interpreted into a Mapquest map showing where I am, scaled according to my speed. Without the use of an expensive map-filled GPS computer, this GPS+GPRS combination gives me a simple navigation system, where I can pull up a page showing where I am and look at a map to see where I have to go.

If my car breaks down, I could use the system to tell a tow truck dispatcher exactly where I am even when I don’t have any real idea myself. That could be helpful someday if ever my car stalls out precariously close to the tracks.

Category:

  • Linux