HOWTO: Connecting to GPRS/EDGE/4G t-mobile with IPwireless PCMCIA card

From Sabayon Wiki
Revision as of 00:04, 20 February 2009 by Zambayoni (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Connecting to t-mobile in Czech republic (you can alter it for your country easily)

OK, let's presume we have nothing but the standard PPPD and CHAT installed, no NetworkManager is though needed etc... Next, we presume you have the IPWIRELESS PCMCIA card, as the steps differ for the other systems and I don't remember, how much do they differ. For this card the good news is it's module is already loaded (or get's loaded when you insert the card?, dunno) authomatically, so don't care at all about the HW driver. Now, please first put the SIM card to some phone and disable PIN checking. It is possible to use the PIN checking, but my configuration, to be the easiest possible, doesn't expect this...

  • first, edit /etc/ppp/chat-secrets, add the following line:
 *<tab>*<tab>"gprs"<tab>*
  • second, create file /etc/ppp/peers/tm4g, containing following:
 hide-password
 nopcomp
 noauth
 connect "/usr/sbin/chat -v -f /etc/chatscripts/tm4g"
 debug
 /dev/ttyIPWp0
 230400
 defaultroute
 noipdefault
 usepeerdns
 user "gprs"
 ipparam tmobile
  • third, create file /etc/chatscripts/tm4g, containing following:
 ABORT BUSY ABORT 'NO CARRIER' ABORT ERROR
  AT
 AT ""
 OK AT+CDGCONT=1,"PPP","internet.t-mobile.cz","0,0",0,0
 AT+CDGCONT=1,"PPP","internet.t-mobile.cz","0,0",0,0 ""
 OK "ATDT*99#"
 CONNECT \d\c

That's it... Now, we want to connect, don't we? So, plug in the PCMCIA card with SIM card in it, with PIN code disabled (other chat script would have to be used, you can google it :-) ), and wait, until the GREEN LED is constantly on (without blinking) - that means, we have GPRS/EDGE or 4G signal and GSM connection established, now we can run the command to get connected, of course under root's credentials, we needed root's credentials for creating/editing the 3 files before anyway, so just using the same root's console for thi :

 /usr/sbin/pppd call tm4g

This command will call pppd and exit, so you can watch the progress in /var/log/messages:

 tail -f /var/log/messages

If all goes well, the output should look like following:

 <date> <hostname> chat[PID]: pppd 2.4.4 started by root, uid 0
 <date> <hostname> chat[PID]: pppd ...
 ...
 <date> <hostname> chat[PID]: send (AT+CDGCONT=1 ...
 ...
 <date> <hostname> chat[PID]: OK
 <date> <hostname> chat[PID]: -- got it
 <date> <hostname> chat[PID]: send (ATDT*99#)
 ...
 <date> <hostname> chat[PID]: CONNECT
 <date> <hostname> chat[PID]: -- got it
 <date> <hostname> chat[PID]: send (\d)
 <date> <hostname> chat[PID]: Serial connection established.
 <date> <hostname> chat[PID]: using channel 9
 <date> <hostname> chat[PID]: Using interface ppp0
 <date> <hostname> chat[PID]: COnnect: ppp0 <--> /dev/ttyIPWp0
 ...
 <date> <hostname> chat[PID]: CHAP authentication succeeded
 ...
 ...
 <date> <hostname> chat[PID]: local     IP address <some.ip.address>
 <date> <hostname> chat[PID]: remote IP address <some.ip.address>
 <date> <hostname> chat[PID]: primary    DNS address <some.ip.address>
 <date> <hostname> chat[PID]: secondary DNS address <some.ip.address>
 <date> <hostname> chat[PID]: Script /etc/ppp/ip-up started
 <date> <hostname> chat[PID]: Script /etc/ppp/ip-up finished
  • Now, you are connected