internecik.com
my home website

Running Sony Ericsson GC75 GPRS PC Card Modem on Linux HOWTO

"How to run GPRS over SE GC75 on Linux with Slackware 9.1"
Autor: Tymoteusz Rogalewski http://www.internecik.com
version 1.0, 19 Jan 2004

Specification of Sony Ericsson GC75 Card:
is here http://www.sonyericsson.com/GC75/ ;-)

Some information provided by system:
This card is recognized by system as standard modem,
and You must only install pcmcia-cs package, recompile kernel,
and use stadard ppp script. Only diffrent with standard mobile phone
is to run before pppd session one small script,
who tell to the card what is our SIM code and make the card log into the GSM network.




Let's go:


1. Kernel and pcmcia-cs
General setup --->
[*] Support for hot-pluggable devices
PCMCIA/CardBus support --->
<M> PCMCIA/CardBus support
[*] CardBus support
[*] Databook TCIC host bridge support
[ ] i82092 compatible bridge support
[*] i82365 compatible bridge support
Character devices --->
PCMCIA character devices --->
<M> PCMCIA serial device support
< > SyncLink PC Card support

I have standard files /etc/pcmcia/*.opts and I don't modify them - for me they are ok
If You have problem with this config or Your system is freeze at start time or
at pc card plugin time, try see in BIOS if You may change someting there.
I have Toshiba Portege 3010CT and in BIOS I have types of pcmcia-port: "auto-selected",
"PCIC compatible", and "CardBus/16-bit".
I use with this laptop GC75 Card and 3com 3c575 32-bit network card
When I use "auto-selected" - 3c575 works, but pcmcia-cs don't see GC75
When I use "CardBus/16-bit" - GC75 works, but pcmcia-cs don't see 3c575 :)
But when I use "PCIC Compatible" - two card work fine.

Warning - in the past I used the tarball pcmcia-cs package from pcmcia-sc.sourceforge.net
in opposite drivers from kernel distribution, but this from SF doesn't see GC75 card when
I plug it or plug out - there wasn't any message in system logs.
With this pcmcia drivers in "PCIC Compatible" mode after plug 3c575 system freeze :(
PCMCIA drivers from kernel works ok for me - recognize this card as standard serial port
and load properly serial_cs module :) (and link new serial port file to /dev/modem)




2. run GC75 - send PIN code
I'm not super extra programmer and I can't write comfortable script to send PIN code to GC75.
If You can - please send this script to me :)
ok - for login into GSM network I do this:
minicom --noinit /dev/modemand in window I type:
AT+CFUN=1,1 # this enable additional AT commands, w/o this next command won't work
answer from GC75 schould be: OK
AT+CPIN=1234 # this is PIN code to Your SIM card
answer from GC75 schould be: OK

IMPORTANT: after AT+CPIN You MUST wait few seconds (about 10s in my network) to SIM card be ready andproperly logged into GSM netowork. After this You can run pppd to establish GPRS connection or SMS or data connection

All AT commands recognized by GC75 Card (about 200 pages in pdf) You can find
at http://www.sonyericsson.com/support/
With this command You can also send SMS, read them and many more :)




3. Establish GPRS connection :)

--- /etc/resolv.conf PlusGSM PL ---
nameserver 212.2.96.62
nameserver 212.2.96.52

--- /etc/resolv.conf IDEA PL ---
nameserver 194.9.223.79
nameserver 217.17.34.10

--- /etc/ppp/options ---
debug
/dev/modem
115200
crtscts
nodetach
nodeflate
noauth
connect /etc/ppp/gprs-connect
disconnect /etc/ppp/gprs-disconnect
:10.0.0.1
noipdefault
novj
novjccomp
nobsdcomp
defaultroute

--- /etc/ppp/gprs-connect ---
#!/bin/sh
exec /usr/sbin/chat \
TIMEOUT 5 \
ECHO ON \
ABORT '\nBUSY\r' \
ABORT '\nERROR\r' \
ABORT '\nNO ANSWER\r' \
ABORT '\nNO CARRIER\r' \
ABORT '\nNO DIALTONE\r' \
ABORT '\nRINGING\r\n\r\nRINGING\r' \
'' '\rAT' \
TIMEOUT 6 \
SAY "Press CTRL-C to close the connection at any stage!" \
SAY "\ndefining PDP context...\n" \
OK 'ATE1' \
OK 'AT+CGDCONT=1,"IP","www.plusgsm.pl","",0,0' \
OK 'ATD*99***1#' \
TIMEOUT 10 \
SAY "\nwaiting for connect...\n" \
CONNECT "" \
SAY "\nConnected." \
SAY "\nIf the following ppp negotiations fail,\n" \
SAY "try restarting the phone.\n"
Line OK 'AT+CGDCONT=1,"IP","www.plusgsm.pl","",0,0' may be diffrent for Your network
fo example for IDEA (PL) must be: OK 'AT+CGDCONT=1,"IP","www.idea.pl","",0,0'

--- /etc/ppp/gprs-disconnect ---
#!/bin/sh
# send break
exec /usr/sbin/chat -V -s -S \
ABORT "BUSY" \
ABORT "ERROR" \
ABORT "NO DIALTONE" \
SAY "\nSending break to the modem\n" \
"" "\K" \
"" "+++ATH" \
SAY "\nPDP context detached\n"

If You're ready, type as root:
pppd
and have fun with GPRS ;-)

If You want more info about connection stage (pppd), look at my new HOWTO named "BT GPRS EDGE UMTS"