LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1861|回复: 0

linux EDGE 希望能帮到各位想上EDGE的朋友

[复制链接]
发表于 2008-7-1 11:54:05 | 显示全部楼层 |阅读模式
特贴出本人设置手札 希望能帮到各位想上EDGE的朋友

硬件:X31+centos 4.6 +tlink e6 pcmcia卡 +移动2000M/月

插入卡后会有提示,若无提示可使用kudzu来找一下。

这里看一下卡是否被找到
[root@konds ~]# dmesg | grep tty
ttyS1 at I/O 0x2f8 (irq = 3) is a 16C950/954
[root@konds ~]#

看卡是否有回应

[root@konds ~]# stty -a < /dev/ttyS1
speed 115200 baud; rows 0; columns 0; line = 3;
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>;
eol2 = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W;
lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 hupcl -cstopb cread -clocal crtscts
ignbrk -brkint ignpar -parmrk -inpck -istrip -inlcr -igncr -icrnl -ixon -ixoff
-iuclc -ixany -imaxbel
-opost -olcuc -ocrnl -onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0
ff0
-isig -icanon -iexten -echo -echoe -echok -echonl -noflsh -xcase -tostop
-echoprt -echoctl -echoke
[root@konds ~]#

使用拨号配置测试一下

[root@konds ~]# wvdialconf  /etc/wvdial.conf
Scanning your serial ports for a modem.

Port Scan<*1>: Scanning ttyS1 first, /dev/modem is a link to it.

ttyS1<*1>: ATQ0 V1 E1 --
ttyS1<*1>: failed with 2400 baud, next try: 9600 baud
ttyS1<*1>: ATQ0 V1 E1 -- )!!
ttyS1<*1>: failed with 9600 baud, next try: 115200 baud
ttyS1<*1>: ATQ0 V1 E1 --
ttyS1<*1>: and failed too at 115200, giving up.
Port Scan<*1>: S0   S2   S3   S4   S5   S6   S7   S8
Port Scan<*1>: S9   S10  S11  S12  S13  S14  S15  S16
Port Scan<*1>: S17  S18  S19  S20  S21  S22  S23  S24
Port Scan<*1>: S25  S26  S27  S28  S29  S30  S31  S32
Port Scan<*1>: S33  S34  S35  S36  S37  S38  S39  S40
Port Scan<*1>: S41  S42  S43  S44  S45  S46  S47  S48
Port Scan<*1>: S49  S50  S51  S52  S53  S54  S55  S56
Port Scan<*1>: S57  S58  S59  S60  S61  S62  S63  S64
Port Scan<*1>: S65  S66  S67  SHSF0 SHSF1 SHSF2 SHSF3 SHSF4
Port Scan<*1>: SHSF5 SHSF6 SHSF7

Sorry, no modem was detected!  Is it in use by another program?
Did you configure it properly with setserial?

Please read the FAQ at http://open.nit.ca/wvdial/

If you still have problems, send mail to wvdial-list@lists.nit.ca.

在这里出现问题。使用setserial设置一下速度
[root@konds ~]# setserial /dev/ttyS1 baud_base 230400

再测试一遍

[root@konds ~]# wvdialconf /etc/wvdial.conf
Scanning your serial ports for a modem.

Port Scan<*1>: Scanning ttyS1 first, /dev/modem is a link to it.
ttyS1<*1>: ATQ0 V1 E1 --
ttyS1<*1>: failed with 2400 baud, next try: 9600 baud
ttyS1<*1>: ATQ0 V1 E1 --
ttyS1<*1>: failed with 9600 baud, next try: 115200 baud
ttyS1<*1>: ATQ0 V1 E1 -- OK
ttyS1<*1>: ATQ0 V1 E1 Z -- OK
ttyS1<*1>: ATQ0 V1 E1 S0=0 -- OK
ttyS1<*1>: ATQ0 V1 E1 S0=0 &C1 -- OK
ttyS1<*1>: ATQ0 V1 E1 S0=0 &C1 &D2 -- OK
ttyS1<*1>: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 -- OK
ttyS1<*1>: Modem Identifier: ATI -- WYLESS_600
ttyS1<*1>: Speed 230400: AT --
ttyS1<*1>: Speed 230400: AT --
ttyS1<*1>: Speed 230400: AT --
ttyS1<*1>: Max speed is 115200; that should be safe.
ttyS1<*1>: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 -- OK
Port Scan<*1>: S2   S3   S4   S5   S6   S7   S8   S9
Port Scan<*1>: S10  S11  S12  S13  S14  S15  S16  S17
Port Scan<*1>: S18  S19  S20  S21  S22  S23  S24  S25
Port Scan<*1>: S26  S27  S28  S29  S30  S31  S32  S33
Port Scan<*1>: S34  S35  S36  S37  S38  S39  S40  S41
Port Scan<*1>: S42  S43  S44  S45  S46  S47  S48  S49
Port Scan<*1>: S50  S51  S52  S53  S54  S55  S56  S57
Port Scan<*1>: S58  S59  S60  S61  S62  S63  S64  S65
Port Scan<*1>: S66  S67  SHSF0 SHSF1 SHSF2 SHSF3 SHSF4 SHSF5
Port Scan<*1>: SHSF6 SHSF7

Found a modem on /dev/ttyS1, using link /dev/modem in config.
Modem configuration written to /etc/wvdial.conf.
ttyS1<Info>: Speed 115200; init "ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0"
[root@konds ~]#

应该是通过了,拨号上线

[root@konds ~]# wvdial
--> WvDial: Internet dialer version 1.54.0
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
OK
--> Modem initialized.
--> Configuration does not specify a valid phone number.
--> Configuration does not specify a valid login name.
--> Configuration does not specify a valid password.

................没设置电话号和用户名

无奈打电话问了号是*99***1# 客服说用户名不需要填写

以下是配置文件

[root@konds ~]#cat /etc/wvdial.conf

[Dialer Defaults]
Modem = /dev/modem
Baud = 115200
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ISDN = 0
Modem Type = Analog Modem
Phone = *99***1#
Username = 11
Password = 1
; Phone = <Target Phone Number>
; Username = <Your Login Name>
; Password = <Your Password>

再拨号。

[root@konds ~]# wvdial
--> WvDial: Internet dialer version 1.54.0
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
OK
--> Modem initialized.
--> Sending: ATDT*99***1#
--> Waiting for carrier.
ATDT*99***1#
CONNECT
--> Carrier detected.  Waiting for prompt.
--> Don't know what to do!  Starting pppd and hoping for the best.
--> Starting pppd at Tue Jul  1 11:06:22 2008
--> pid of pppd: 5090
--> Using interface ppp0
--> pppd:  ATM1L4
--> pppd:  ATM1L4
--> pppd:  ATM1L4
--> pppd:  ATM1L4
--> local  IP address 10.60.84.255
--> pppd:  ATM1L4
--> remote IP address 192.200.1.21
--> pppd:  ATM1L4
--> primary   DNS address 211.136.112.50
--> pppd:  ATM1L4
--> secondary DNS address 211.136.20.203
--> pppd:  ATM1L4

好像是上了,可就是打不开网页,试了一下,dns没解析

执行以下,把网卡刷一下。

ip route flush all
route add default ppp0

OK,EDGE是可以上了。但有时候速度不稳定,我在家里有时候EDGE信号不稳定,没有EDGE时候就是GPRS了,慢的嘞只想砸机器.
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表