Disclaimer: This is a personal site that has nothing to do with any employer. All content given on this site is either produced, used with permission, or under free or acquired license.



Using Fedora Core Linux with the PPC-6700 PocketPC USB Modem (PPC6700)

Posted: Tue Jun 6 21:34:01 PDT 2006
Last modified: Wed Dec 5 05:52:42 EST 2007
More about myself...

About...

Don't Muck with The Duck This is a simple guide on getting Fedora Core working with a UTstarcom / Sprint PPC-6700 PocketPC (aka the HTC Apache, or PPC6700, or Verizon XV6700) as a USB modem (this is the one with the flip out keyboard), giving you pretty high speeds on a tethered wireless modem using EVDO (almost 3G speeds). If you are looking to run Linux on this phone, please check out the XDA Developers Wiki for Linux on the HTC Apache, which provides info on getting the ARM/XScale port of Linux going. This guide is verbose (lots of images!) as to be understandable to new users, and can probably be modified for other phones. Note some service providers want you to get a data plan, so exercise caution. It is probably prudent not to make excessive use of it by doing things like file-sharing on the cell-phone (it is your responsibility that your plan allows flat-rate usage, it may not so you'll need to check). The screenshots have been taken from Fedora Core 5 Linux, on a relatively unmodified install, and the PocketPC has Windows Mobile 5.0 on it with firmware version 2.06. These instructions are provided without any guarantees, and can probably easily be translated to other distributions of Linux fairly easily. This is probably applicable to the other flavors of this phone, such as the Verizon XV6700, though you may need to locate the wmodem.exe program directly from the WINDOWS directory (you'll need to show hidden files) on the XV6700 as Verizon has kept it hidden. You can copy the smaller shortcut file to the Programs menu to keep it accessible.


Configuring the Network Device

  • Log in to your system as a normal user, and start configuring a network device as shown.
  • You'll need to enter the superuser password.
  • Here we have the network devices that are currently defined in the system. You'll want to click New on the toolbar here to create a new device.
  • Choose the Modem connection and then proceed to the next step.
  • Note if you don't have a modem on this machine (like on my test machine), you'll get this error message. Just ignore it and continue.
  • OK, here is the modem properties dialog box. You'll want to modify it in the next step.
  • Change the modem device to /dev/ttyUSB0 and the baud rate to 460800, and go forward.
  • On this screen, enter the PPP dial string "#777" in the phone number space, something like SprintPCS for the provider name (or a short string for whomever your provider is), and most important, your login name and password for your service. Then continue forward.
  • On this step we're just going to use the defaults provided. Just continue forward.
  • Here the selections you typed in are summarized. Verify that things look OK and then Apply.
  • Now we are back at the network device list in the network configuration tool. Note we now have a new PPP device.
  • Choose File/Save to save the new configuration, and then exit the tool by choosing File/Exit. Now we'll move on to configuring your system to load the USB modem driver on bootup.

Configuring the Linux PocketPC Driver for your 6700

  • Run a terminal as shown so you can run some commands.
  • With the open terminal, you'll want to run the command shown so that you can edit the system initialization script. Upon hitting enter, you'll need to type in the superuser or root password to continue.
  • If you have not modified your system, you should have something similar to the following. You'll modify this file in the next step.
  • Here you will add the following line in the rc.local init script so that on bootup the driver will load. Make sure that you add it exactly as shown. The line is provided here for cut and paste convenience. It contains the device ID of the CDMA serial modem for this particular unit in the UTstarcom 6700.
  • /sbin/modprobe ipaq vendor=0x0bb4 product=0x00cf
  • If you have another PocketPC modem that is not immediately recognized, you can try to find the info by running the following command when the device is not plugged in, and then when it is plugged in (though be sure it is running wmodem.exe), and then run the diff command on it to see the newly added device. See the P: line that contains the vendor and product ID. You can try replacing those above.
          [root@localhost ~]# cat /proc/bus/usb/devices
          ...
          T:  Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 19 Spd=12  MxCh= 0
          D:  Ver= 2.00 Cls=20(unk. ) Sub=00 Prot=00 MxPS=16 #Cfgs=  1
          P:  Vendor=0bb4 ProdID=00cf Rev= 0.90
          S:  Manufacturer=Generic Manufacturer (PROTOTYPE--Remember to change idVendor)
          S:  Product=Generic Serial (PROTOTYPE--Remember to change idVendor)
          C:* #Ifs= 1 Cfg#= 1 Atr=c0 MxPwr=500mA
          I:  If#= 0 Alt= 0 #EPs= 3 Cls=02(comm.) Sub=ff Prot=ff Driver=ipaq
          E:  Ad=81(I) Atr=02(Bulk) MxPS=  64 Ivl=0ms
          E:  Ad=02(O) Atr=02(Bulk) MxPS=  64 Ivl=0ms
          E:  Ad=83(I) Atr=03(Int.) MxPS=  64 Ivl=32ms
          ...
          
  • Ensure that the file looks OK, and then run File/Save and then File/Exit.
  • Now you'll want to reboot your computer so that the driver loads by running System/Shutdown and then Restart.
  • After rebooting, login and run another terminal like you did previously. In this terminal you'll want to run the following command. You'll need to type in the superuser password to get it to run (if successful, it will just seem to do nothing).
  • su -c 'tail -n 0 -f /var/log/messages'
  • Now on the PocketPC, from the Start menu, choose Programs. Locate the Wireless Modem application, wmodem.exe. Note on the Verizon XV6700 you may need to create a shortcut to wmodem.exe into the \WINDOWS directory on the device, as it may not appear here.
  • After running wmodem.exe, you'll get the following screen. If your data connection is off, you'll be able to hit the Start button. If your data connection is on, you'll need to stop it before trying again.
  • After hitting Start, it will look like this.
  • Proceed to plug the unit into your USB cable that is connected to your computer.
  • If the driver loaded properly on reboot, you should see something like the following on the terminal where you are running the tail command. If you see an error (such as -110), you can try unplugging the device for 5 seconds, and then plug it back in.
  • Note the last line. This is important, the device listed here should be exactly the same as the modem device you choose in the beginning. Most likely it will be /dev/ttyUSB0 and you'll be fine. If not, you'll need to go back into the system network tool and modify the network device that is used by your mobile PPP connection.

Bringing up the PPP Connection

  • Open up another terminal and position it near but not on top of the one running tail. Here you are going to run (it should run as a user with default network device settings) the following command to bring up the device. Previously we called the network device SprintPCS, so replace this if you named it something different.
  • /sbin/ifup SprintPCS
  • After running the ifup on the network device, I get the following results (the IP addresses are blurred out).
  • You should be connected to the Internet at this stage and should be able to do your work. You should have something similar, but if not, you will want to check things like your username, password, etc. for your service provider.
  • Since latency is higher on this type of connection, more advanced users may want to run a local caching nameserver to noticeably speed up browsing. Fedora comes with a default caching nameserver configuration that is installed with bind that works great (you'll need to install bind if you didn't). You just need to start it with "service start named" and ensure that "nameserver 127.0.0.1" is your first nameserver entry in /etc/resolv.conf (you can disable setting of your service provider's DNS servers in the network device configuration).
  • Bringing down the connection is as simple as when you brought it up.
  • I have noticed that if I want to reinitiate the connection, I will have to hit Stop and then Start on the wmodem application on the PocketPC at this point before trying to bring the connection back up with ifup.
  • If you still have problems, perhaps your PPP peer does not respond to Link Control Protocol echo requests. You can try turning this off by adding the following to /etc/ppp/options (you'll need to do this with a gedit command similar to the one run above):
          lcp-echo-interval 0
          lcp-echo-failure 0
          

If you still have problems, perhaps your PPP peer does not respond to Link Control Protocol echo requests. You can try turning this off by adding the following to /etc/ppp/options (you'll need to do this with a gedit command similar to the one run above):

lcp-echo-interval 0
lcp-echo-failure 0