Linux下轻量级蓝牙用法


如果想在Linux下用蓝牙存取文件,又不想安装blueman等笨重的东西,可以这样:

pacman -S bluez (安装蓝牙协议栈)

/etc/rc.d/dbus start

/etc/rc.d/bluetooth start

hcitool scan (查找设备)

bluez-simple-agent(依赖dbus-python和pygobject,它用于配对,需要配对时以root权限运行它)

pacman -S obexfs (用于文件操作)

obexfs -b <devices mac address> /mountpoint (以普通用户运行就行)

然后就可以在/mountpoint看到文件,可读可写,但注意不能用touch创建文件,可以echo > filename。另外速度很慢。

相关内容