Windows Phone @ MoDaCo: Linux USB Tethering Instructions for BlackJack II Using pppd - Windows Phone @ MoDaCo

Jump to content

Galaxy Nexus Review
We put the Galaxy Nexus and Ice Cream Sandwich through their paces.

Google Music Launch
Google bring Music out of beta and launch their music store.

MoDaCo Plus / Ad Free
Hate ads? Want cool stuff? Sign up for a MoDaCo Plus / MoDaCo Ad Free account with Online Kitchen access!

Close
Open
Close
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Linux USB Tethering Instructions for BlackJack II Using pppd This post made from my i617UCGK2 Blackjack II Tethered via USB
-----


#1 User is offline   linuxchuck 

  • Newbie
  • Pip
  • Group: Members
  • Posts: 1
  • Joined: 03-June 08
  • Devices:Blackjack II i617UCGK2

Posted 03 June 2008 - 09:09 PM

I have successfully configured my new Blackjack II (1617UCGK2) from ATT to work as a USB modem for my linux system.

Yes, I know that wvdial, or gnome-ppp or may work just fine, but not every distro out there provides those applications. Since I haven't seen anything elsewhere that covers this specific phone, and how to tether it via USB to practically any Linux distro out there in a generic, but fully functional way, here is the setup:

Your linux distro must have pppd installed. I can't think of any distro that doesn't come with this by default. However, if yours doesn't have it, installing software onto your system is beyond the scope of this document. Google is your friend. :(

You will also need to have the kernel module called cdc-acm.ko built and installed. Again, this post is not going to teach you how to configure your kernel, build modules, or even how to download them. Go find yourself a good linux support group for that. :D

I am also not here to teach you how to do basic filesystem management under linux. You should be able to edit, copy, move, rename, and such all on your own.

Now on to the "meat" of this post:

Create the following file, and add the content as seen in the code box below:

/etc/ppp/peers/blackjack

/dev/ttyACM0
921600
debug
noauth
novj
ipcp-accept-remote
defaultroute
usepeerdns
user ISPDA@CINGULARGPRS.COM
password CINGULAR1
crtscts
lock
remotename attws
ipparam attws
persist
nodetach
ipcp-max-configure 20
maxfail 0
connect '/usr/sbin/chat -v -V -t3 -f /etc/ppp/peers/blackjack-chat'


Create the following file, and add the content of the code box below:

/etc/ppp/peers/blackjack-chat

ABORT 'NO DIAL TONE' ABORT 'NO ANSWER' ABORT DELAYED
'' AT+cfun=1
OK AT+cfun=1
OK AT+cgreg=1
OK AT
TIMEOUT 40
OK ATQ0&F&D2&C1E1V1S0=0
OK AT+FCLASS=0
OK AT+IFC=2,2
OK 'AT+CGDCONT=1,"IP","WAP.CINGULAR"'
OK ATD*99#
CONNECT '\d\c'


Once you have those two files created, with the content listed above, you're pretty much done.

I found out that my /etc/resolv.conf was not getting updated properly, and DNS resolution was not working so I added the following two files to fix that issue: (If you don't have the DNS resolution issue, don't bother creating these two files.)

/etc/ppp/ip-up
#!/bin/sh
if [ -n "$USEPEERDNS" -a -f /etc/ppp/resolv.conf ]; then
        rm -f /etc/ppp/resolv.prev
        if [ -f /etc/resolv.conf ]; then
                cp /etc/resolv.conf /etc/ppp/resolv.prev
                grep domain /etc/ppp/resolv.prev > /etc/resolv.conf
                grep search /etc/ppp/resolv.prev >> /etc/resolv.conf
                cat /etc/ppp/resolv.conf >> /etc/resolv.conf
        else
                cp /etc/ppp/resolv.conf /etc
        fi
fi


/etc/ppp/ip-down
#!/bin/sh
if [ -n "$USEPEERDNS" -a -f /etc/ppp/resolv.conf ]; then
        if [ -f /etc/ppp/resolv.prev ]; then
                cp -f /etc/ppp/resolv.prev /etc/resolv.conf
        else
                rm -f /etc/resolv.conf
        fi
fi


I then made them executable with the following two commands:

chmod +x /etc/ppp/ip-up
chmod +x /etc/ppp/ip-down


Plug your phone in to a USB port on your system. The cdc-acm module should be loaded, and it should create a ttyACM0 device file in the /dev directory. To ensure the module is loaded, and the device node is there, use the following two commands:

lsmod | grep cdc_acm


That command will show you if the module is loaded,

ls -lah /dev/ttyACM*


That one will show you the device file if there is one.

There is a slight possibility that you will have more than one ACM device showing there. If that is the case, I'll leave it up as an exercise for the reader to figure out exactly which one is your phone. However, I doubt you'll run into this problem.

Once you know the device file was created properly, execute the following command to dial up:

pppd call blackjack


Sit back, and enjoy your 3G network connection on Linux.

P.S. One last piece of advice: If you can't seem to browse, but you can ping www.google.com, try configuring your browser to "auto-detect" the proxy configuration. That worked for me too...

Have fun!

Linuxchuck

This post has been edited by linuxchuck: 03 June 2008 - 09:15 PM

0

Sponsored Links


#2 User is offline   dtphantom 

  • Regular
  • PipPip
  • Group: Members
  • Posts: 74
  • Joined: 05-April 08
  • Devices:Blackjack II

Posted 04 June 2008 - 01:56 AM

awesome thanks. Now if only my laptop had a battery that lasted for more than 5 minutes and this would really be useful

0


Sponsored Links

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users

MoDaCo is part of the MoDaCo.network, © Paul O'Brien 2002-2012. MoDaCo uses IntelliTxt technology. Privacy Policy / Contact Details.

Skin and Language

Sign in here


Sign in options
Log in with Facebook Log in with Twitter   Go to advanced login Register Now!