Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| en:guides:bluetooth [2010/04/03 21:47] – linea | en:guides:bluetooth [2010/08/22 15:39] (current) – linea | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Bluetooth ====== | ====== Bluetooth ====== | ||
| + | |||
| + | ===== Introduction ===== | ||
| This guide will help you to configure bluetooth, e.g. to use your phone as a modem. | This guide will help you to configure bluetooth, e.g. to use your phone as a modem. | ||
| Do following steps as root. | Do following steps as root. | ||
| First of all you must install Slitaz packages related to bluetooth: | First of all you must install Slitaz packages related to bluetooth: | ||
| - | tazpkg get-install bluez | + | |
| - | tazpkg get-install linux-bluetooth | + | |
| The first package contains the Official Linux Bluetooth protocol stack www.bluez.org and the second contains the kernel modules related to bluetooth. | The first package contains the Official Linux Bluetooth protocol stack www.bluez.org and the second contains the kernel modules related to bluetooth. | ||
| Now you can launch the bluetooth daemon: | Now you can launch the bluetooth daemon: | ||
| - | bluetoothd | + | |
| And load the module required by your local bluetooth device, this is very likely btusb: | And load the module required by your local bluetooth device, this is very likely btusb: | ||
| - | modprobe btusb | + | |
| If btusb is the module you need the command " | If btusb is the module you need the command " | ||
| root@slitaz:/ | root@slitaz:/ | ||
| Line 25: | Line 27: | ||
| If you want to start the pairing from the remote device you need to put your local device in discoverable mode: | If you want to start the pairing from the remote device you need to put your local device in discoverable mode: | ||
| - | hciconfig hci0 piscan | + | |
| Now launch bluez-simple-agent, | Now launch bluez-simple-agent, | ||
| This code will be the same one you typed on the phone. When you are done you need to kill bluez-simple-agent with Ctrl-c: | This code will be the same one you typed on the phone. When you are done you need to kill bluez-simple-agent with Ctrl-c: | ||
| Line 39: | Line 42: | ||
| root@slitaz:/ | root@slitaz:/ | ||
| Put your local device back in undiscoverable mode: | Put your local device back in undiscoverable mode: | ||
| - | hciconfig hci0 pscan | + | |
| If you want to start the pairing from your local device you can do it using bluez-simple-agent with the hci* of your local device and the address of the device you discovered with " | If you want to start the pairing from your local device you can do it using bluez-simple-agent with the hci* of your local device and the address of the device you discovered with " | ||
| Line 49: | Line 52: | ||
| root@slitaz:/ | root@slitaz:/ | ||
| Be fast because bluez-simple-agent has a timeout which I don't know how to set (suggestions? | Be fast because bluez-simple-agent has a timeout which I don't know how to set (suggestions? | ||
| + | |||
| + | ===== Use a phone as a modem ===== | ||
| Now you have your two devices paired, i will go on with the phone as a modem example, I don't have other experiences with bluetooth devices. | Now you have your two devices paired, i will go on with the phone as a modem example, I don't have other experiences with bluetooth devices. | ||
| Line 57: | Line 62: | ||
| root@slitaz:/ | root@slitaz:/ | ||
| If CONFIG_BT_RFCOMM_TTY is not =y you must recompile the module with tty support. Install linux-source: | If CONFIG_BT_RFCOMM_TTY is not =y you must recompile the module with tty support. Install linux-source: | ||
| - | tazpkg get-install linux-source | + | |
| cd in / | cd in / | ||
| - | make CONFIG_BT_RFCOMM=m CONFIG_BT_RFCOMM_TTY=y M=net/ | + | |
| This will build only the rfcomm module with tty support. You will find it in / | This will build only the rfcomm module with tty support. You will find it in / | ||
| Now you can delete the old rfcomm module and replace it with your module: | Now you can delete the old rfcomm module and replace it with your module: | ||
| - | rm / | + | |
| - | cp / | + | |
| - | depmod -a | + | |
| Now that we have a working rfcomm module we must detect the channel where the phone dialup service is listening: | Now that we have a working rfcomm module we must detect the channel where the phone dialup service is listening: | ||
| - | sdptool browse 00: | + | |
| Where 00: | Where 00: | ||
| Service Name: Dial-up networking | Service Name: Dial-up networking | ||
| Line 84: | Line 89: | ||
| " | " | ||
| Version: 0x0100 | Version: 0x0100 | ||
| - | As you can see it is listening on channel 1, so you edit / | + | |
| + | ===== rfcomm.conf ===== | ||
| + | |||
| + | As you can see it is listening on channel 1, so you edit /// | ||
| + | < | ||
| # | # | ||
| # RFCOMM configuration file. | # RFCOMM configuration file. | ||
| Line 101: | Line 110: | ||
| # | # | ||
| } | } | ||
| + | </ | ||
| Now with: | Now with: | ||
| - | modprobe rfcomm | + | |
| - | rfcomm bind all | + | |
| You can use / | You can use / | ||
| You may want to check this guide http:// | You may want to check this guide http:// | ||
| + | ---- | ||
| + | \\ | ||
| + | ^ Page Review Section | ||
| + | |Quality| Good | | ||
| + | |Review| Minor Updates | ||
| + | |Priority| Medium | | ||
| + | |Problems| add a [[http:// | ||
| + | |::: | OR add a [[http:// | ||
| + | |How to Improve| Add tazhw setup bluetooth ; Please create " | ||
| + | |::: | | | ||
| + | |||
| + | \\ | ||
| + | ---- | ||