linux 蓝牙 开机启动,蓝牙鼠标bluetooth mouse的ubuntu 7.10开机自动连接方法指南(罗技v270)...

蓝牙鼠标bluetooth mouse的ubuntu 7.10开机自动连接方法指南(罗技v270)

发布时间:2008-02-07 00:59:56来源:红联作者:Dazkj

先装驱动

sudo apt-get install bluez-utils

sudo /etc/init.d/bluez-utils restart

然后

sudo hidd --server

sudo hidd --search

这一步以后应该可以找到蓝牙鼠标,并且显示出MAC码

修改/etc/default/bluetooth

# start bluetooth on boot?

# compatibility note: If this variable is not found bluetooth will

# start

BLUETOOTH_ENABLED=1

############ HIDD

#

# To have Bluetooth mouse and keyboard support, get the

# Linux 2.6.6 patch or better from bluez.org, and set

# HIDD_ENABLED to 1.

HIDD_ENABLED=1

HIDD_OPTIONS="--connect aa:bb:cc:dd:ee:ff --server"

aa:bb:cc:dd:ee:ff是鼠标的mac地址

修改完上面还不行,还要设置开机自动连接鼠标,google和baidu都没有找到真正的解决方法,这是我自己摸索出来的,也是实现开机自动连接蓝牙鼠标的关键步骤

编辑rc.local

$ sudo gedit /etc/init.d/rc.local

在后面加上

hciconfig hci0 down

hciconfig hci0 up

hidd --search

保存后重新起动

第一次会要求授权,选择总是授权,以后开机就会自动连接了

以上在富士通p1510笔记本电脑(没有内置蓝牙),IBM X40,水木行蓝牙适配器,罗技V270,ubuntu 7.10 环境下完成,设置好以后,每次重启系统,蓝牙鼠标都是自动找到,非常爽。

关于自动启动

我感觉加在rc.local不太好,因为这时候可能hidd服务还没有起来,所以楼主必须手动加上down和up。但是因为7.10似乎优化过启动顺序的,这样可能会延长启动时间。

我的做法是

A.建立一个文件/etc/init.d/xloadBluetooth.sh,内容是

hidd --search

B. 修改他的权限为777

sudo chmod 777 /etc/init.d/xloadBluetooth.sh

C. 建立一个软链接,让启动的时候,rc*脚本能运行他

sudo ln -sf /etc/init.d/xloadBluetooth.sh /etc/rcS.d/S99xloadBluetooth.sh

这样命名主要是为了让他能在启动的最后运行。

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值