Page 1 of 2

modem switch but can't connect

Posted: 10 Jul 2012, 05:43
by jundi7680
hi there, i have evdo modem air flash ah007, with id 05c6-6000. in my android 2.3 tablet recognize as 05c6-1000, there is an id called 05c6-1000-uMa_SSE wich is very similar... it did switch when run usb_modeswitch -I -W -c /etc/usb_modeswitch.d/05c6-1000-uMa_SSE

lsusb show that there is device 05c6-6000, my modem device id
in dmesg also shown that gsm converter attach in usbtty0,usbtty1 until usbtty3

but there is no sign of signal bar and cant connect to the internet

is it something wrong here ?

sorry for my english

Posted: 10 Jul 2012, 10:18
by Josh
Unfortunately, it's not that easy in Android. Unless your tablet manufacturer implemented a way to connect via USB modems or phones, the device is not prepared to do that.

There is a tedious way to get at least partial network access, by using the "old" pppd method. You will find information about this by googling "android pppd".

For this to work you need root access on your tablet though.

BTW, and this is my first announcement, I am working on a widget for Android which has usb_modeswitch and pppd integrated, with fully automatic mode switching. This will need at least Android 3.2 and root access too.

Note that with this method, most Internet functionality is there - with some exceptions like Google Play download and others.


Posted: 10 Jul 2012, 11:25
by jundi7680
hi there josh,

this problem happened only with cdma/evdo usb modem. when i stick my huawei e1553 it worked like charm. my tablet is aishuo A7+ with one usb (full usb) port that can be use to connect external modem, usb flashdisk etc. it run gingerbread 2.3 os version. the tablet is already rooted.

is there a special way to handle evdo-cdma modem, because when it is gsm there is no problem with connection

BTW your announcement is a great news for tablet users...

Posted: 10 Jul 2012, 19:35
by Josh
The problem may be that the tablet software picks the wrong port ...

Huawei modems can almost in all cases connect via ttyUSB0. Other modems want to be used on ttyUSB2 or higher.

You can check this on a full Linux system with running the "lsusb -v -d 05c6:6000" command and looking for an endpoint with "Interrupt Transfer" (with your device plugged and modeswitched). That is most likely the right interface/port for connection.

Maybe your tablet allows to set the port manually - but I doubt it ...


Posted: 11 Jul 2012, 12:00
by jundi7680
You are genius mr Josh,
I try to edit my call script,change /dev/ttyUSB0 with ttyUSB3

In logcat I found new problem, it said pppd chat script failed

Posted: 12 Jul 2012, 07:39
by jundi7680
correction...the modem attached at usbtty1 not 2 or 3

edit my call script like this :

# optionfile was generated by pppconfig 2.3.15.
#
#
/dev/ttyUSB1
nodetach
noauth
usepeerdns
ipcp-accept-local
ipcp-accept-remote
local
0.0.0.0:0.0.0.0

noipdefault
novj
novjccomp
noccp

asyncmap 0
lcp-echo-failure 0
lcp-echo-interval 0
defaultroute

connect '/system/bin/chat -s -v -f /etc/ppp/peers/cdma-chat-connect'
disconnect '/system/bin/chat -s -v -f /etc/ppp/peers/disconnect'

and this what cdma-chat-connect script:

ABORT 'NO CARRIER'
ABORT 'ERROR'
ABORT 'NO DIALTONE'
ABORT 'BUSY'
ABORT 'NO ANSWER'
'' \rAT
OK \rATZ
OK-AT-OK ATDT#777
CONNECT \d\c


try to run pppd
# pppd call cdma

and what i've got :

abort on (NO CARRIER)
abort on (ERROR)
abort on (NO DIAL TONE)
abort on (BUSY)
abort on (NO ANSWER)
send (^MATZ^M)
expect (OK)
AT^M^M
OK
--got it

send (^MATZ^M)
expect (OK)
^M
ATZ^M^M
OK
--got it

send (ATDT#777^M)
expect (CONNECT)
^M
ATDT#777^M^M
CONNECT
--got it

send (\d)
abort on (NO CARRIER)
abort on (ERROR)
abort on (NO DIAL TONE)
abort on (BUSY)
abort on (NO ANSWER)
send (^MATZ^M)
expect (OK)
AT^M^M
OK
--got it

send (^MATZ^M)
expect (OK)
^M
ATZ^M^M
OK
--got it

send (ATDT#777^M)
expect (CONNECT)
^M
ATDT#777^M^M
NO CARRIER
FAILED

the modem start blinking forever....

Posted: 17 Jul 2012, 19:07
by Josh
I don't know about CDMA, but with GPRS connections you always have to provide a correct "APN" string (access point). Otherwise dialing will fail.

Posted: 18 Jul 2012, 03:45
by jundi7680
Josh wrote:I don't know about CDMA, but with GPRS connections you always have to provide a correct "APN" string (access point). Otherwise dialing will fail.
yes we have to do that APN setup also in cdma, the different is just dial number, in gprs *99# in cdma #777...

where do i have to put this APN string ? in dialer script or chat script , in my case in cdma script or cdma-chat-connect script?

i would like to try your widget on my 2.3 android...hope it also works

Posted: 18 Jul 2012, 08:13
by Josh
There is a good listing of the most common commands here:
http://3g-modem.wetpaint.com/page/common+AT-commands

In my experience, less is more. You should be able to work just with the APN command (CGDCONT) and the CFUN command (set it to 1).

At the moment, the PPP Widget needs Android 3.1 as a minimum.


Posted: 21 Jul 2012, 12:16
by jundi7680
i managed to install your widget too in my other tablet running android 4.0.1

the problem also lay on cdma usb modem, the tablet recognize the modem as CDMA network ( just that, no provider named on it)... the modem was switch into modem mode (05c6:6000)

no connection too when using your widget (auto or manual selection of usbtty*) i have fill all mandatory field (APN, username, pasword and dial number)

Posted: 21 Jul 2012, 14:42
by Josh
I am working on changing the conditions regarding the parameters.

If you have trouble connecting, maybe the log will tell you about the problem (see config page).


Posted: 25 Jul 2012, 03:16
by jundi7680
ok i'll see the log and try to find it in config page. btw, is it possible that your widget ported into 2.2 or 2.3 ?

Posted: 25 Jul 2012, 08:13
by Josh
Have a look at the PPP Widget announcement thread ...

http://www.draisberghof.de/usb_modeswit ... =6302#6302

Posted: 27 Jul 2012, 03:34
by jundi7680
the log told me only this:
connect script failed


both with first and the new ppp widget on 4.0.1 and also 2.3.1 in gingerbread, after dialling out, the widget can't be disconnect eventhough i've unplugged the modem.

i think it need special ways to handle cdma modem

Posted: 27 Jul 2012, 09:56
by Josh
jundi7680 wrote:the log told me only this:
connect script failed
This means that there was not even any initial communication with the modem. Not a single AT command went through.

I don't think the problems are related to the network technology; it's the stick (or its firmware).

Can you check on a "desktop" linux and run "lsusb -v -d 05c6:6000" after mode switching?
I'd really like to see the whole device configuration of that thing.