/[gentoo]/xml/htdocs/doc/en/bluetooth-guide.xml
Gentoo

Contents of /xml/htdocs/doc/en/bluetooth-guide.xml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.15 - (hide annotations) (download) (as text)
Mon Oct 22 05:28:14 2007 UTC (7 years, 2 months ago) by nightmorph
Branch: MAIN
Changes since 1.14: +1 -2 lines
File MIME type: application/xml
coding style, no content changes

1 fox2mike 1.1 <?xml version='1.0' encoding="UTF-8"?>
2     <!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
3 nightmorph 1.15 <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/bluetooth-guide.xml,v 1.14 2007/10/22 05:27:37 nightmorph Exp $ -->
4 fox2mike 1.1
5     <guide link="/doc/en/bluetooth-guide.xml">
6     <title>Gentoo Linux Bluetooth Guide</title>
7    
8     <author title="Author">
9     <mail link="deathwing00@gentoo.org">Ioannis Aslanidis</mail>
10     </author>
11     <author title="Contributor">
12     <mail link="puggy@gentoo.org">Douglas Russell</mail>
13     </author>
14     <author title="Contributor">
15     <mail link="marcel@holtmann.org">Marcel Holtmann</mail>
16     </author>
17 neysx 1.3 <author title="Author">
18 fox2mike 1.1 <mail link="fox2mike@gentoo.org">Shyam Mani</mail>
19     </author>
20     <author title="Editor">
21     <mail link="rane@gentoo.org">Ɓukasz Damentko</mail>
22     </author>
23    
24     <abstract>
25     This guide will explain how to successfully install a host Bluetooth device,
26     configure the kernel properly, explain all the possibilities that the Bluetooth
27 neysx 1.3 interconnection offers and how to have some fun with Bluetooth.
28 fox2mike 1.1 </abstract>
29    
30     <!-- The content of this document is licensed under the CC-BY-SA license -->
31     <!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
32     <license/>
33    
34 nightmorph 1.14 <version>1.10</version>
35     <date>2007-10-21</date>
36 fox2mike 1.1
37     <chapter id="introduction">
38     <title>Introduction</title>
39     <section>
40     <title>What is Bluetooth?</title>
41     <body>
42    
43     <p>
44     Bluetooth is an industrial specification that provides users a way to connect
45     and exchange information between devices like personal computers, PDAs or
46     mobile phones. Using the Bluetooth technology, users can achieve wireless voice
47     and data transmission between devices at a low cost. Bluetooth also offers the
48     possibility to create small wireless LANs and to synchronize devices.
49     </p>
50    
51     </body>
52     </section>
53     <section>
54     <title>About the content of this guide</title>
55     <body>
56    
57     <p>
58     The first part of this guide is to identify qualified and non-qualified devices
59     that support the Bluetooth technology. This way, users can purchase Bluetooth
60     devices that are known to work. After that, the guide explains how to configure
61     the system kernel, identify the Bluetooth devices installed on the system and
62     detected by the kernel and install the necessary basic Bluetooth tools.
63     </p>
64    
65     <p>
66     The second part covers how to detect remote devices and how to establish a
67     connection from or to them by either setting up radio frequency communication
68     (RFCOMM) or by setting up a personal area network (PAN).
69     </p>
70    
71     <p>
72     The last part of the guide lists in detail applications that can take
73     advantage of all the possibilities offered by the Bluetooth technology.
74     </p>
75    
76     </body>
77     </section>
78     </chapter>
79    
80     <chapter id="devices">
81     <title>Supported Devices</title>
82     <section>
83     <title>Qualified and non-qualified devices that support Bluetooth</title>
84     <body>
85    
86     <impo>
87     These products might work even though some are not qualified Bluetooth
88     products. Gentoo does not support them in any way, they might just work.
89     </impo>
90    
91     <p>
92     A list of the currently supported devices can be found at: <uri
93     link="http://www.holtmann.org/linux/bluetooth/features.html">Bluetooth device
94     features and revision information by Marcel Holtmann</uri>.
95     </p>
96    
97     </body>
98     </section>
99     </chapter>
100    
101     <chapter id="kernel">
102     <title>Configuring the system</title>
103     <section>
104     <title>Kernel Configuration</title>
105     <body>
106    
107     <p>
108     As the latest Linux stable kernel is 2.6, the configuration will be done for
109     these series of the kernel. Most Bluetooth devices are connected to a USB port,
110 nightmorph 1.12 so USB will be enabled too. Please refer to the <uri
111     link="/doc/en/usb-guide.xml"> Gentoo Linux USB Guide</uri>.
112 fox2mike 1.1 </p>
113    
114     <pre caption="Configuration for 2.6 kernels">
115 swift 1.5 Networking ---&gt;
116 fox2mike 1.1
117     &lt;*&gt; Bluetooth subsystem support ---&gt;
118    
119     --- Bluetooth subsystem support
120     &lt;M&gt; L2CAP protocol support
121     &lt;M&gt; SCO links support
122     &lt;M&gt; RFCOMM protocol support
123     [*] RFCOMM TTY support
124     &lt;M&gt; BNEP protocol support
125     [*] Multicast filter support
126     [*] Protocol filter support
127     &lt;M&gt; HIDP protocol support
128    
129     Bluetooth device drivers ---&gt;
130     &lt;M&gt; HCI USB driver
131     [*] SCO (voice) support
132     &lt;M&gt; HCI UART driver
133     [*] UART (H4) protocol support
134     [*] BCSP protocol support
135     [*] Transmit CRC with every BCSP packet
136     &lt;M&gt; HCI BCM203x USB driver
137     &lt;M&gt; HCI BPA10x USB driver
138     &lt;M&gt; HCI BlueFRITZ! USB driver
139     <comment>(The four drivers below are for PCMCIA Bluetooth devices and will only
140     show up if you have also selected PCMCIA support in your kernel.)</comment>
141     &lt;M&gt; HCI DTL1 (PC Card) driver
142     &lt;M&gt; HCI BT3C (PC Card) driver
143     &lt;M&gt; HCI BlueCard (PC Card) driver
144 neysx 1.3 &lt;M&gt; HCI UART (PC Card) device driver
145 fox2mike 1.1 <comment>(The driver below is intended for HCI Emulation software.)</comment>
146     &lt;M&gt; HCI VHCI (Virtual HCI device) driver
147    
148     <comment>(Move back three levels to Device Drives and then check if USB is
149     enabled. This is required if you use a Bluetooth dongle, which are mostly USB
150     based.)</comment>
151     USB support ---&gt;
152    
153     &lt;*&gt; Support for Host-side USB
154     --- USB Host Controller Drivers
155     &lt;M&gt; EHCI HCD (USB 2.0) support
156     [ ] Full speed ISO transactions (EXPERIMENTAL)
157     [ ] Root Hub Transaction Translators (EXPERIMENTAL)
158     &lt;*&gt; OHCI HCD support
159     &lt;*&gt; UHCI HCD (most Intel and VIA) support
160     &lt; &gt; SL811HS HCD support
161     </pre>
162    
163     <p>
164     Now we'll reboot with our new kernel. If everything went fine, we will have a
165     system that is Bluetooth ready.
166     </p>
167    
168     <impo>
169     Your USB device may have two modes the default of which may not be HCI, but HID.
170     If this is your case, use <c>hid2hci</c> to switch to HCI mode. Your system
171     will not remember this change when you next reboot.
172     </impo>
173    
174     <pre caption="Checking the Bluetooth devices">
175     <comment>(One way to check for the device)</comment>
176     # <i>cat /proc/bus/usb/devices | grep -e^[TPD] | grep -e Cls=e0 -B1 -A1</i>
177     <comment>(The Cls=e0(unk. ) identifies the Bluetooth adapter.)</comment>
178     T: Bus=02 Lev=02 Prnt=03 Port=00 Cnt=01 Dev#= 4 Spd=12 MxCh= 0
179     D: Ver= 1.10 Cls=e0(unk. ) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
180 neysx 1.3 P: Vendor=0a12 ProdID=0001 Rev= 5.25
181 fox2mike 1.1 <comment>(Some might show up on lsusb from sys-apps/usbutils)</comment>
182     # <i>lsusb</i>
183     Bus 003 Device 002: ID 046d:c00e Logitech, Inc. Optical Mouse
184     Bus 003 Device 001: ID 0000:0000
185     Bus 002 Device 002: ID 0db0:1967 Micro Star International Bluetooth Dongle
186     </pre>
187    
188     </body>
189     </section>
190     </chapter>
191    
192     <chapter id="bluez">
193     <title>BlueZ - The Bluetooth Stack</title>
194     <section>
195     <title>Installing BlueZ</title>
196     <body>
197    
198     <p>
199     Now that the device is detected by the kernel, we need a layer that lets
200     applications communicate with the Bluetooth device. BlueZ provides the official
201     Linux Bluetooth stack. The ebuilds that provide what we need are
202     <c>bluez-libs</c> and <c>bluez-utils</c>. Devices that need Broadcom firmware
203     files or the like may need <c>bluez-firmware</c>.
204     </p>
205    
206     <pre caption="Installing bluez-libs and bluez-utils">
207     # <i>emerge net-wireless/bluez-libs net-wireless/bluez-utils</i>
208     </pre>
209    
210     </body>
211     </section>
212     <section>
213     <title>BlueZ configuration and PIN pairing</title>
214     <body>
215    
216     <p>
217     Now it's time to see if the Bluetooth device is being picked up correctly by the
218     system. We start up the required Bluetooth services first.
219     </p>
220    
221     <pre caption="Running hciconfig">
222     <comment>(Start up Bluetooth)</comment>
223     # <i>/etc/init.d/bluetooth start</i>
224     * Starting Bluetooth ...
225     * Starting hcid ... [ ok ]
226     * Starting sdpd ... [ ok ]
227     * Starting rfcomm ... [ ok ]
228    
229     # <i>hciconfig</i>
230     hci0: Type: USB
231     BD Address: 00:01:02:03:04:05 ACL MTU: 192:8 SCO MTU: 64:8
232     DOWN
233     RX bytes:131 acl:0 sco:0 events:18 errors:0
234 neysx 1.3 TX bytes:565 acl:0 sco:0 commands:17 errors:0
235 fox2mike 1.1 </pre>
236    
237     <p>
238     This shows that the Bluetooth device has been recognised. As you might have
239     noticed the device is <e>DOWN</e>. Let's configure it so that we can bring it
240     up. The configuration file is at <path>/etc/bluetooth/hcid.conf</path>. The
241     required changes to the config file are shown below. For additional details
242     please refer to <c>man hcid.conf</c>.
243     </p>
244    
245     <pre caption="Editing /etc/bluetooth/hcid.conf">
246     <comment>(Recommended changes to be made to the file are shown)</comment>
247    
248 neysx 1.6 # HCId options
249     options {
250     # Automatically initialize new devices
251     autoinit yes;
252    
253 fox2mike 1.1 <comment>(Change security to "auto")</comment>
254     # Security Manager mode
255     # none - Security manager disabled
256     # auto - Use local PIN for incoming connections
257     # user - Always ask user for a PIN
258     #
259     security auto;
260    
261 neysx 1.6 # Pairing mode
262     pairing multi;
263    
264 nightmorph 1.13 <comment>(You only need a pin helper if you are using &lt;=bluez-libs-2.x and &lt;=bluez-utils-2.x)
265     (Change pin_helper to use /etc/bluetooth/pin-helper)</comment>
266 fox2mike 1.1 # PIN helper
267     pin_helper /etc/bluetooth/pin-helper;
268 neysx 1.6 }
269 fox2mike 1.1
270 neysx 1.6 # Default settings for HCI devices
271     device {
272 fox2mike 1.1 <comment>(Set your device name here, you can call it anything you want)</comment>
273     # Local device name
274     # %d - device id
275     # %h - host name
276     name "BlueZ at %h (%d)";
277    
278 neysx 1.6 # Local device class
279     class 0x3e0100;
280    
281     # Inquiry and Page scan
282     iscan enable; pscan enable;
283    
284     # Default link mode
285     lm accept;
286    
287     # Default link policy
288     lp rswitch,hold,sniff,park;
289    
290 fox2mike 1.1 <comment>(Leave as is, if you don't know what exactly these do)</comment>
291     # Authentication and Encryption (Security Mode 3)
292     #auth enable;
293     #encrypt enable;
294     }
295     </pre>
296    
297     <p>
298     After that, we have to configure the Bluetooth device PIN. That will help in
299     pairing this device with another one.
300     </p>
301    
302     <pre caption="Editing /etc/bluetooth/pin">
303 nightmorph 1.13 <comment>(Replace 123456 with your desired pin number.)</comment>
304 fox2mike 1.1 123456
305     </pre>
306    
307     <impo>
308     This number (of your choice) must be the same in all your hosts with Bluetooth
309     devices so they can be paired. This number must also be kept secret since anyone
310     with knowledge of this number can essentially establish connections with your
311     devices.
312     </impo>
313    
314 nightmorph 1.13 <note>
315     If you are using <c>&lt;=bluez-libs-2.x</c> and <c>&lt;=bluez-utils-2.x</c> you
316     can choose from different pin helpers, depending on what you want to use.
317     Available pin helpers are: <c>/usr/lib/kdebluetooth/kbluepin</c>
318     (net-wireless/kdebluetooth), <c>/usr/bin/bluepin</c> or
319     <c>/etc/bluetooth/pin-helper</c> among others.
320     </note>
321    
322     <note>
323     Beginning with <c>>=bluez-libs-3.x</c> and <c>>=bluez-utils-3.x</c>, pin helpers
324     have been replaced by passkey agents. There are a few different graphical
325     passkey agents available to help manage your PIN, such as <c>bluez-gnome</c> and
326     <c>kdebluetooth</c>. You can also use <c>passkey-agent</c> (found in
327     <c>bluez-utils</c>) from the command line.
328     </note>
329    
330 fox2mike 1.1 </body>
331     </section>
332     <section>
333     <title>Services configuration</title>
334     <body>
335    
336     <p>
337     Now that we have concluded with the configuration of BlueZ, it's time to restart
338     the necessary services.
339     </p>
340    
341     <pre caption="Starting the Bluetooth daemons">
342     # <i>/etc/init.d/bluetooth restart</i>
343     <comment>(We can also add it to the default runlevel.)</comment>
344     # <i>rc-update add bluetooth default</i>
345     * bluetooth added to runlevel default
346     * rc-update complete.
347     </pre>
348    
349     <p>
350     Let's be sure that the Bluetooth daemons started correctly. If we can see that
351     both <c>hcid</c> and <c>sdpd</c> are running, then we configured Bluetooth the
352 yoswink 1.4 right way. After that, we can see if the devices are now up and running with
353 fox2mike 1.1 the configured options.
354     </p>
355    
356 swift 1.2 <pre caption="Checking whether Bluetooth daemons started correctly">
357 fox2mike 1.1 <comment>(Check to see if the services are running)</comment>
358     # <i>ps -ae | grep hcid</i>
359     26050 ? 00:00:00 hcid
360     # <i>ps -ae | grep sdpd</i>
361     26054 ? 00:00:00 sdpd
362    
363     # <i>hciconfig -a</i>
364     hci0: Type: USB
365     BD Address: 00:0A:0B:0C:0D:0E ACL MTU: 192:8 SCO MTU: 64:8
366 neysx 1.6 UP RUNNING PSCAN ISCAN
367 fox2mike 1.1 RX bytes:125 acl:0 sco:0 events:17 errors:0
368     TX bytes:565 acl:0 sco:0 commands:17 errors:0
369     Features: 0xff 0xff 0x0f 0x00 0x00 0x00 0x00 0x00
370     Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
371     Link policy: RSWITCH HOLD SNIFF PARK
372     Link mode: SLAVE ACCEPT
373     Name: 'BlueZ at bluehat (0)'
374     Class: 0x3e0100
375     Service Classes: Networking, Rendering, Capturing, Object Transfer,
376     Audio
377     Device Class: Computer, Uncategorized
378     HCI Ver: 1.1 (0x1) HCI Rev: 0x1e7 LMP Ver: 1.1 (0x1) LMP Subver: 0x1e7
379     Manufacturer: Cambridge Silicon Radio (10)
380     </pre>
381    
382     </body>
383     </section>
384     </chapter>
385    
386     <chapter id="detect">
387     <title>Detecting and Connecting to Remote Devices</title>
388     <section>
389     <title>Detecting Bluetooth devices in other hosts</title>
390     <body>
391    
392     <p>
393     At this point we are now ready to detect Bluetooth devices installed in other
394     machines. This is independent of the host Operating System. We will make use of
395     the <c>hcitool</c> command for the same.
396     </p>
397    
398     <pre caption="Checking for local devices">
399     # <i>hcitool dev</i>
400     Devices:
401     hci0 00:01:02:03:04:05
402     </pre>
403    
404     <pre caption="Scanning for remote devices">
405     # <i>hcitool scan</i>
406     Scanning ...
407 neysx 1.3 00:0A:0B:0C:0D:0E Grayhat
408 fox2mike 1.1 </pre>
409    
410     <pre caption="Inquiring remote devices">
411     # <i>hcitool inq</i>
412     Inquiring ...
413 neysx 1.3 00:0A:0B:0C:0D:0E clock offset: 0x5579 class: 0x72010c
414 fox2mike 1.1 </pre>
415    
416     <p>
417 yoswink 1.4 Now that we know the MAC address of the remote Bluetooth devices, we can check
418 fox2mike 1.1 if we paired them correctly.
419     </p>
420    
421     <pre caption="Running l2ping">
422     # <i>l2ping 00:0A:0B:0C:0D:0E</i>
423     Ping: 00:0A:0B:0C:0D:0E from 00:01:02:03:04:05 (data size 20) ...
424     20 bytes from 00:0A:0B:0C:0D:0E id 200 time 69.85ms
425     20 bytes from 00:0A:0B:0C:0D:0E id 201 time 9.97ms
426     20 bytes from 00:0A:0B:0C:0D:0E id 202 time 56.86ms
427     20 bytes from 00:0A:0B:0C:0D:0E id 203 time 39.92ms
428 neysx 1.3 4 sent, 4 received, 0% loss
429 fox2mike 1.1 </pre>
430    
431     </body>
432     </section>
433     <section>
434     <title>Setting up Radio Frequency Communication (RFCOMM)</title>
435     <body>
436    
437     <note>
438     Please note that setting up radio frequency communication is optional.
439     </note>
440    
441     <p>
442     We can establish a radio frequency connection to another Bluetooth device using
443     the <c>rfcomm</c> command. To make things a little easier especially for users
444     with multiple devices that support Bluetooth, it is advisable to make a few
445     changes to the default rfcomm config at <path>/etc/bluetooth/rfcomm.conf</path>.
446     </p>
447    
448     <p>
449     The whole segment of the config starting from <c>rfcomm0 {</c> and ending with
450     <c>}</c> is the config for the device that will establish a connection at
451     <path>/dev/rfcomm0</path>. In this case, we will only show one example, rfcomm0.
452     You can add more devices as you see fit.
453     </p>
454    
455     <pre caption="Editing /etc/bluetooth/rfcomm.conf">
456     <comment>(Only changes that might be needed are shown)</comment>
457     rfcomm0 {
458     # Automatically bind the device at startup
459     <comment>(Creates the device node, /dev/rfcomm0 at start up)</comment>
460     bind yes;
461    
462     # Bluetooth address of the device
463     <comment>(Enter the address of the device you want to connect to)</comment>
464     device 00:0A:0B:0C:0D:0E;
465    
466 neysx 1.3 }
467 fox2mike 1.1 </pre>
468    
469     <p>
470     After configuring RFCOMM, we can connect to any device. Since we've made the
471     required settings to the <path>/etc/bluetooth/rfcomm.conf</path> file, we just
472     issue the command shown below. In case you've not made changes to the config
473     file, an alternative method is also shown in the code listing that follows
474     </p>
475    
476     <pre caption="Establishing an RFCOMM connection">
477     <comment>(The 0 refers to the rfcomm0 in the config file)</comment>
478     # <i>rfcomm connect 0 </i>
479     Connected /dev/rfcomm0 to 00:0A:0B:0C:0D:0E on channel 1
480     Press CTRL-C for hangup
481    
482     <comment>(If you did not edit /etc/bluetooth/rfcomm.conf)</comment>
483     # <i>rfcomm connect 0 00:0A:0B:0C:0D:0E 1</i>
484     Connected /dev/rfcomm0 to 00:0F:DE:69:50:24 on channel 1
485     Press CTRL-C for hangup
486     </pre>
487    
488     <p>
489     The first parameter after the connect command is the RFCOMM TTY device node
490     that will be used (usually 0). The second parameter is the MAC address of the
491     remote device. The third parameter is optional and specifies the channel to be
492     used. Please, note that in order to connect to a device, that device must be
493     listening for incoming connections. To do that, we have to explicitly tell it
494     to listen. We can cancel the communication at any moment by just hitting
495     CTRL+C.
496     </p>
497    
498     <pre caption="Listening for incoming RFCOMM connections">
499     # <i>rfcomm listen 0 1</i>
500 neysx 1.3 Waiting for connection on channel 1
501 fox2mike 1.1 </pre>
502    
503     <p>
504     In a similar way to the connect command, the listen command can receive two
505     parameters. The first one explicits the RFCOMM TTY device node (usually 0) that
506     will be used to accept a connection, while the second is the channel that will
507 neysx 1.3 be used.
508 fox2mike 1.1 </p>
509    
510     <p>
511     Each time you call the <c>rfcomm</c> command, you can also specify the physical
512     device you want to use. Below you can see a small example specifiying the
513     physical device on the above two commands.
514     </p>
515    
516     <pre caption="RFCOMM connections specifying physical device">
517     # <i>rfcomm -i hci0 listen 0 1</i>
518     Waiting for connection on channel 1
519     <comment>(To listen to a determined device) </comment>
520     # <i>rfcomm -i hci0 connect 0 00:0A:0B:0C:0D:0E 1</i>
521     <comment>(To use a determined device when connecting to another one)</comment>
522     </pre>
523    
524     </body>
525     </section>
526     <section>
527     <title>Setting up a Personal Area Network (PAN)</title>
528     <body>
529    
530     <note>
531     Please note that setting up a Personal Area Network is optional. This section
532     describes how to set up and connect to a Network Access Point, though setting
533     up a Group Ad-Hoc Network follows a similar way.
534     </note>
535    
536     <p>
537     First of all, we need the <c>bnep</c> module loaded. And probably we want it
538     loaded each time the computer starts.
539     </p>
540    
541     <pre caption="Loading the bnep module">
542     # <i>modprobe bnep</i>
543     # <i>echo "bnep" &gt;&gt; /etc/modules.autoload.d/kernel-2.6</i>
544     </pre>
545    
546     <p>
547     We have to start the <c>pand</c> daemon in the host that will provide the NAP.
548     We'll have to specify that we want to provide a NAP service and that this host
549     will be the master, thus the other hosts that connect to it, the slaves.
550     Another possible service is GN (Group ad-hoc Network).
551     </p>
552    
553     <pre caption="Running the pand daemon">
554     # <i>pand --listen --role NAP --master --autozap</i>
555     </pre>
556    
557     <p>
558     After doing that, we have a host listening, so the rest of hosts just have to
559     connect to that one.
560     </p>
561    
562     <pre caption="Connecting to the Network Access Point">
563     # <i>pand --connect 00:0A:0B:0C:0D:0E --service NAP --autozap</i>
564     </pre>
565    
566     <p>
567     If everything went fine, we can now configure the IP addresses of our hosts.
568     </p>
569    
570     <pre caption="bnep IP address configuration">
571     host0 #<i> ifconfig bnep0 192.168.2.1</i>
572     host1 #<i> ifconfig bnep0 192.168.2.2</i>
573    
574     host0 #<i> ifconfig bnep0</i>
575 neysx 1.3 bnep0 Link encap:Ethernet HWaddr 00:0A:0B:0C:0D:0E
576 fox2mike 1.1 inet addr:192.168.2.1 Bcast:192.168.2.255 Mask:255.255.255.0
577     inet6 addr: fe80::210:60ff:fea3:cb41/64 Scope:Link
578     UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
579     RX packets:0 errors:0 dropped:0 overruns:0 frame:0
580     TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
581     collisions:0 txqueuelen:1000
582     RX bytes:208 (208.0 b) TX bytes:188 (188.0 b)
583    
584     host1 #<i> ifconfig bnep0</i>
585 neysx 1.3 bnep0 Link encap:Ethernet HWaddr 00:01:02:03:04:05
586 fox2mike 1.1 inet addr:192.168.2.2 Bcast:192.168.2.255 Mask:255.255.255.0
587     inet6 addr: fe80::210:60ff:fea2:dd2a/64 Scope:Link
588     UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
589     RX packets:0 errors:0 dropped:0 overruns:0 frame:0
590     TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
591     collisions:0 txqueuelen:1000
592     RX bytes:208 (208.0 b) TX bytes:188 (188.0 b)
593     </pre>
594    
595     <p>
596     Finally, we can do a simple test to see that the network is working fine.
597     </p>
598    
599     <pre caption="IP ping between bnep interfaces">
600     host1 #<i> ping 192.168.2.1</i>
601     PING 192.168.2.1 (192.168.2.1) 56(84) bytes of data.
602     64 bytes from 192.168.2.1: icmp_seq=1 ttl=64 time=34.0 ms
603     64 bytes from 192.168.2.1: icmp_seq=2 ttl=64 time=37.3 ms
604    
605     --- 192.168.2.1 ping statistics ---
606     2 packets transmitted, 2 received, 0% packet loss, time 1000ms
607 neysx 1.3 rtt min/avg/max/mdev = 34.045/35.690/37.336/1.656 ms
608 fox2mike 1.1 </pre>
609    
610     </body>
611     </section>
612     </chapter>
613    
614     <chapter id="apps">
615     <title>Desktop Applications for Bluetooth</title>
616     <section>
617     <title>Introduction</title>
618     <body>
619    
620     <p>
621     We have quite a few Bluetooth applications that run on the desktop and this
622     chapter has been divided into 3 parts, one each for Gnome, KDE and Miscellaneous
623     applications.
624     </p>
625    
626     </body>
627     </section>
628     <section>
629     <title>For Gnome</title>
630     <body>
631    
632     <p>
633     If you are a gnome user, you will most probably go with <c>gnome-bluetooth</c>.
634     It provides the most basic yet most used functionalities, as you can see below.
635     </p>
636    
637     <ul>
638     <li><c>gnome-bluetooth-manager</c>: To manage Bluetooth remote devices.</li>
639     <li><c>gnome-obex-send</c>: To send files to other devices.</li>
640     <li><c>gnome-obex-server</c>: To receive files.</li>
641     </ul>
642    
643     <pre caption="Installing gnome-bluetooth">
644     # <i>emerge gnome-bluetooth</i>
645     </pre>
646    
647     <p>
648     This adds menu entries under Applications &gt; System Tools from where you can
649     easily start up the manager or File sharing to transfer files between devices.
650     </p>
651    
652     <p>
653 neysx 1.3 To transfer files (the easy way):
654 fox2mike 1.1 </p>
655    
656     <ul>
657     <li>
658     From the Phone to the Computer - Send the file from the phone via Bluetooth
659     and it will be picked up and saved to your <path>/home</path> always.
660     </li>
661     <!--FIXME : Doesn't work on Nautilus 2.10.x. Bug #103464 for details -->
662     <!--
663     <li>
664     From the Computer to the Phone - Fire up <c>nautilus</c> and select the
665     file you want to send and right click on it. Select the Send via Bluetooth
666     option and ask your phone to accept the file.
667     </li>
668     -->
669     </ul>
670    
671     <p>
672     <c>gnome-phone-manager</c> is a nifty app that you can use to send and receive
673     messages to and from your phone, using only your system. You do not have to
674     touch your phone to read or send messages since all that happens through the
675     application. You are also notified of a new message on your screen if the option
676     is enabled under Preferences. Installation is a breeze as always.
677     </p>
678    
679     <pre caption="Installing gnome-phone-manager">
680     # <i>emerge gnome-phone-manager</i>
681     </pre>
682    
683     </body>
684     </section>
685     <section>
686     <title>For KDE</title>
687     <body>
688    
689     <p>
690     KDE makes use of <c>kdebluetooth</c> and provides more utilities than its Gnome
691     counterpart as seen below.
692     </p>
693    
694     <ul>
695     <li><c>kbluetoothd</c>: Bluetooth Meta Server.</li>
696     <li><c>kbtsearch</c>: Bluetooth device/service search utility.</li>
697     <li><c>khciconfig</c>: KDE Bluetooth Monitor.</li>
698     <li><c>kioclient</c>: KIO command line client.</li>
699     <li><c>qobexclient</c>: Swiss army knife for obex testing/development.</li>
700     <li><c>kbtobexclient</c>: A KDE Bluetooth Framework Application.</li>
701     <li><c>kioobex_start</c></li>
702     <li><c>kbtserialchat</c></li>
703     <li><c>kbemusedsrv</c>: KDE Bemused Server.</li>
704     <li><c>kbtobexsrv</c>: KDE OBEX Push Server for Bluetooth.</li>
705     <li><c>kbluepin</c>: A KDE KPart Application.</li>
706     <li>
707     <c>auth-helper</c>: A helper program for kbtobexsrv that sends an
708     authentication request for a given ACL link.
709     </li>
710     </ul>
711    
712     <pre caption="Installing kdebluetooth">
713     # <i>emerge kdebluetooth</i>
714     </pre>
715    
716     </body>
717     </section>
718     <section>
719     <title>Other Interesting Applications</title>
720     <body>
721    
722     <ul>
723     <li>
724     <c>app-mobilephone/obexftp</c>: File transfer over OBEX for mobile phones
725     </li>
726     <li>
727     <c>app-mobilephone/bemused</c>: Bemused is a system which allows you to
728     control your music collection from your phone, using Bluetooth.
729     </li>
730     <li>
731     <c>app-pda/multisync</c>: Multisync allows you to sync contacts, calendar
732     entries and notes from your mobile phone with your computer, over a
733     Bluetooth connection (amongst other things). It includes such features as
734     backing up this information and restoring it later, and syncing with the
735     Evolution e-mail client. You will need the <c>irmc</c> USE flag set to
736     ensure that <c>multisync</c> has Bluetooth support.
737     </li>
738 nightmorph 1.10 <li>
739     <c>net-wireless/opd</c> and <c>net-wireless/ussp-push</c> are command line
740     tools (server and client) that can be used to send files to your mobile
741     phone.
742     </li>
743 fox2mike 1.1 </ul>
744    
745     </body>
746     </section>
747     </chapter>
748    
749     <chapter>
750     <title>Acknowledgements</title>
751     <section>
752     <body>
753    
754     <p>
755     Special thanks to <mail link="marcel@holtmann.org">Marcel Holtmann</mail>
756     for his time and dedication to the Bluetooth development and for reviewing this
757     guide. And big thanks to <mail link="puggy@gentoo.org">Douglas Russell</mail>
758     for performing additional hardware tests and improving this guide.
759     </p>
760    
761     </body>
762     </section>
763     </chapter>
764     </guide>

  ViewVC Help
Powered by ViewVC 1.1.20