Bluetooth networking
Contents
On the module
The module is configured to attempt to start bluetooth networking automatically on boot. Thus activating bluetooth on the module is a simple matter of connecting a USB bluetooth dongle and rebooting.On the desktop
On the desktop side more configuration is required. You'll need a working bluetooth dongle and appropriate security permissions. If any of the following steps fail, please check your permissions with your system administrator.Finding the Bluetooth address
First we need to find the bluetooth address of the module (or more specifically the bluetooth dongle attached to the module). The hcitool scan command can be used to discover this. Suppose the module has the hostname "bartlebee", then you should see something like the following
# hcitool scan
Scanning ...
00:13:70:D8:40:68 beetlejuice (0)
00:0A:3A:66:3D:B1 bartlebee (0)
In this example, we've determined that the module "bartlebee" has a bluetooth address of 00:0A:3A:66:3D:B1.
Connecting to the module
Use the pand daemon to bring up an internet connection to the module:
# pand --role PANU --connect 00:0A:3A:66:3D:B1 --persist
On many systems you can follow the progress here with:
# tail -f /var/log/daemon.log
You should see something like this:
Jan 26 13:19:09 localhost pand[15264]: Bluetooth PAN daemon version 3.8 Jan 26 13:19:09 localhost pand[15264]: Connecting to 00:0A:3A:66:3D:B1 Jan 26 13:19:12 localhost pand[15264]: bnep0 connected
Once the connection is established you'll need to configure the IP connection:
# ifconfig bnep0 192.168.0.2 netmask 255.255.255.0
You should now be able to ping the module on its default IP address:
# ping 192.168.0.1
Troubleshooting
- Ensure the bluetooth dongle attached. Reboot the module.
- Restart the bluetooth system on the desktop.
- Ensure a root password is set on the module.
- Ensure that the module is within range using hcitool scan.
- To list PAN connections use: pan -l
- To kill all PAN connections use: pan -K
References
- BlueZ HOWTOs - http://www.holtmann.org/linux/bluetooth/
- PAND HOWTO - http://bluez.sourceforge.net/contrib/HOWTO-PAN
(c) 2006 Edinburgh Robotics Ltd.
Generated on Fri Feb 2 11:24:07 2007 for libbot by doxygen 1.5.1