Update: Since writing this blog entry many developments have happened with mobile internet under linux. These days you can just plug and go. NetworkManager will even help you find the right settings. However, I haven’t tested this particular mobile broadband pcmcia card with recent versions of Ubuntu, but assume that it works well. Leave a comment if you have any problems
First off, I realise that I haven’t posted a blog entry in a while now. I don’t know why I haven’t, as I’ve had plenty of time, it being the summer holidays and all. I always find my self wanting to do so much stuff in the summer holidays, and somehow turn up doing hardly anything. ‘Tis a shame.
After reading this mailing list post on ubuntu-uk, I was surprised these 3G datacards actually worked under ubuntu. Therefore, I instantly zoomed off to ebay and purchased one for £34 + postage. I made sure it said unlocked in the ebay listing, as I currently have a virgin mobile sim card and didn’t want to waste/switch to vodafone.
So the datacard turned up and I popped my phone SIM in it. Following the guide that was written in the mailing list, I configured it. This was using kppp. So I made everything was in there right and tried to connect. One problem though. Everytime I tried to connect kppp would lock up instantly. “Ah dear”, I though.
After much researching, I managed to set up the datacard using gnome-ppp, which is equally, if not more, easier to set up the datacard in. And here is a little guide I’ll write in full for you…
The vodafone 3G card. Great little thing. Get the internet almost anywhere!
Now, these vodafone cards seem to be just some re-branded ones. The real manufacture, found from the label underneath, is Novatel Wireless. The model of the datacard is Merlin U630.
Pop the SIM card into your datacard, ensuring that you put it in the right way (I may have been stupid enough to put it in the wrong way ). And then plug it into your computer. First off, it would be quite a good idea to ensure that it was detected by the system. To do this open up a terminal and enter the command
dmesg. This should hopefully give you a long list of text, where the end of it slightly resembles this:
[ 124.076000] pccard: PCMCIA card inserted into slot 0
[ 124.076000] cs: memory probe 0xf8000000-0xfdffffff: excluding 0xf8000000-0xfc1fffff 0xfce00000-0xfd3fffff
[ 124.080000] pcmcia: registering new device pcmcia0.0
[ 124.080000] pcmcia: registering new device pcmcia0.1
[ 124.224000] pcmcia: request for exclusive IRQ could not be fulfilled.
[ 124.224000] pcmcia: the driver needs updating to supported shared IRQ lines.
[ 124.268000] 0.0: ttyS0 at I/O 0x3f8 (irq = 3) is a 16550A
[ 124.312000] pcmcia: request for exclusive IRQ could not be fulfilled.
[ 124.312000] pcmcia: the driver needs updating to supported shared IRQ lines.
[ 124.360000] 0.1: ttyS1 at I/O 0x2f8 (irq = 3) is a 16550A
From this you can see the ttyS0 part. This is the name the Linux has given to your datacard. This isn’t really necessary, but it could be useful to know.
Time to install gnome-ppp. Run
sudo apt-get install gnome-ppp. One final thing to do in the terminal is edit a setting of ppp in linux. Run the command
sudo gedit /etc/ppp/options. That will load up the text editor, so that you are able to change the options. Head to the bottom of the file and add
novj to the end on a separate line. Save and close this file.
Head to Applications -> Internet -> Gnome PPP. This will load up the gnome ppp manager. Press the setup button to load up the options for connecting. Click the detect button, so that it can find your modem device, or alternatively choose the name we found earlier (in my case /dev/ttyS0). Even though it isn’t a USB modem select under type USB modem, as I found this is the setting that worked. Set the speed to 460800.
Now, you’re going to need to find your mobile provider’s APN address. I found this website had a bunch of APNs for many different mobile providers. So, as I use virginmobile, I scrolled on down to the virginmobile part and found my APN was goto.virginmobile.uk.
Pop back to the settings for gnome-ppp. Click the “Init Strings…” button. In the 3rd Init string item put the following line of code, replacing goto.virginmobile.uk with the APN for your mobile provider.
Once you’ve entered that, press the close button in the Init Strings window. That is the end of the configuration in the Setup dialog also. So go ahead and close that too.
You’re now back to Gnome PPP main screen. If you go back to that webpage I pointed to you earlier, and down to your provider you’ll find a username and password. Copy these accross to the username and password boxes of gnome ppp. If the webpage said (leave blank) next to either the username or password, just put anything in to fill that up, as gnome ppp will not allow you to connect otherwise.
One final part is to add in the phone number to dial. This is, for most people, going to be *99***1#. Now that you’ve entered all the settings needed go ahead and click Connect. Hopefully, through the power of 3G or GPRS, you will be connected up to your mobile network and able to surf the internet.
You may have a few problems with your DNS. You’ll know this if you are not able to load a webpage like google.com normally, but you are able to via http://22.214.171.124/. In which case, I’d solve this problem by using the opendns servers. Head to System -> Administration -> Network. On the DNS tab set your DNS servers to be 126.96.36.199 and 188.8.131.52. After that, you should be able to visit sites easily again.
Now, I think that’s it. If I’ve missed anything please comment.