QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 1995|回复: 0

求助:(linux下通过蓝牙手机上网)网页打不开

[复制链接]
发表于 2008-5-20 21:31:07 | 显示全部楼层 |阅读模式
最近在想在一个pc机上实现-----linux+蓝牙手机---上网
内核2.6.9+MOTOv3
下面是我已所做的,大家帮我看看问题出在哪????
1 安装bluez-libs 2.25  bluez-utils 2.25
没问题
2 配置bluez
   # HCId options
options {
        # Automatically initialize new devices
        autoinit yes;

        # Security Manager mode
        #   none - Security manager disabled
        #   auto - Use local PIN for incoming connections
        #   user - Always ask user for a PIN
        #
        security auto;

        # Pairing mode
        #   none  - Pairing disabled
        #   multi - Allow pairing with already paired devices
        #   once  - Pair once and deny successive attempts
        pairing multi;

        # PIN helper
        pin_helper /usr/bin/my-bluepin;                              //这里是我自己写的一个bluepin,因为能够配对成功,所以这些应该都没问题了

        # D-Bus PIN helper
        #dbus_pin_helper;
}

# Default settings for HCI devices
device {
        # Local device name
        #   %d - device id
  #   %h - host name
        name "ZCF-ATR-COMPUTER (%d)";

        # Local device class
        class 0x3e0100;

        # Default packet type
        #pkt_type DH1,DM1,HV1;

        # Inquiry and Page scan
        iscan enable; pscan enable;

        # Default link mode
        #   none   - no specific policy
        #   accept - always accept incoming connections
        #   master - become master on incoming connections,
        #            deny role switch on outgoing connections
        lm accept;

        # Default link policy
        #   none    - no specific policy
        #   rswitch - allow role switch
        #   hold    - allow hold mode
        #   sniff   - allow sniff mode
        #   park    - allow park mode
        lp rswitch,hold,sniff,park;

        # Authentication and Encryption (Security Mode 3)
        #auth enable;
        #encrypt enable;
}
3 设置设置拨号上网
所用的工具:
pppd(用来拨号的)
rfcomm(用来连接手机拨号服务)

1. 需要建立编辑的文件有2个:                          //谁能提供这两文件的配置说明,谢谢了
第一个:/etc/ppp/peers/gprs
内容如下:

/dev/rfcomm0
230400
defaultroute
usepeerdns
user ''
password bobo
nodetach
crtscts
lock
noauth
local
debug
connect "/usr/sbin/chat -v -f /etc/ppp/chat-gprs"


第二个:/etc/ppp/chat-gprs
内容如下:

TIMEOUT 10
ABORT 'BUSY'
ABORT 'NO ANSWER'
ABORT 'ERROR'
"" 'ATZ'
OK 'AT+CGDCONT=3,"IP","cmwap" '     //不明白什么意思
ABORT 'NO CARRIER'
SAY 'Dialing....\n'
OK 'ATD*99***1#'
CONNECT ''

4 修改/etc/bluetooth/rfcomm.conf

#
# RFCOMM configuration file.
#

rfcomm0 {
        # Automatically bind the device at startup
        bind yes;

        # Bluetooth address of the device
        device 00:17:84:**:**:**;                                   //我手机MOTOv3RMAC地址

        # RFCOMM channel for the connection
        channel 1;                                                         //我手机rfcomm的工作信道

        # Description of the connection
        comment "Example Bluetooth device";

5  绑定rfcomm0到手机上
rfcomm bind 0  00:17:84:**:**:** 1

6. 运行命令进行拨号
pppd call gprs                                          //手机有收到"请求拨号连接网络网关"

显示如下:
Dialing....
Serial connection established.
using channel 1
Using interface ppp0
Connect: ppp0 <--> /dev/rfcomm0
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x1c705108> <pcomp> <accomp>]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x1c705108> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x1 <asyncmap 0x0> <auth pap> <magic 0x52b7ef> <pcomp> <acc omp>]
sent [LCP ConfAck id=0x1 <asyncmap 0x0> <auth pap> <magic 0x52b7ef> <pcomp> <acc omp>]
sent [PAP AuthReq id=0x1 user="localhost.localdomain" password=<hidden>]
rcvd [PAP AuthAck id=0x1]
PAP authentication succeeded
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15>]
sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> < ms-dns3 0.0.0.0>]
rcvd [LCP ProtRej id=0x1 80 fd 01 01 00 0c 1a 04 78 00 18 04 78 00]
rcvd [IPCP ConfRej id=0x1 <compress VJ 0f 01>]
sent [IPCP ConfReq id=0x2 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
sent [IPCP ConfReq id=0x2 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
rcvd [IPCP ConfNak id=0x2 <addr 10.90.20.89>]
sent [IPCP ConfReq id=0x3 <addr 10.90.20.89> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0> ]
rcvd [IPCP ConfAck id=0x3 <addr 10.90.20.89> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0> ]
rcvd [IPCP ConfReq id=0x2 <addr 192.168.100.101>]
sent [IPCP ConfAck id=0x2 <addr 192.168.100.101>]
local  IP address 10.90.20.89
remote IP address 192.168.100.101                                 
//我看了网上很多关于这一段的内容,都有形如primary   DNS address 0.0.0.19 secondary DNS address 0.71.35.128
//而我这里没有,我觉得很有可能是这个问题,因为手机的上网DNS不对,可能导致没法通过蓝牙手机上网
Script /etc/ppp/ip-up started (pid 4544)
Script /etc/ppp/ip-up finished (pid 4544), status = 0x0

我的问题也就在这里,pc机已经跟蓝牙手机配对成功,并且手机上也提示连接着,同时GPRS显示打开了,为什么找开firefox浏览器还是上不了

看网上说还得设置代理,我也设置了
编辑--首选项--连接---设置--->手动配置代理
HTTP 代理  填上 10.0.0.172  端口为 80


大侠们,帮我看看,我这问题出在哪里,搞了很多天了,也看了很多网友的介绍,可我的问题还是依旧,真是郁闷

期盼回复!!!
您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-4-23 18:33 , Processed in 0.086106 second(s), 15 queries .

© 2021 Powered by Discuz! X3.5.

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