Affix HOWTO

Version 1.10

Last updated on Wednesday, 01-Sep-2004 08:28:14 UTC.

Copyright © 2001-2004 Nokia Corporation
Written by Dmitry Kasatkin <dmitry.kasatkin@nokia.com>.
Sections from four to six was added by Miklos Quartus <miklos.quartus@nokia.com>.
Updated 31.8.2004 by Henri Ranki.


Topics covered:

  1. How to find devices around me
  2. How to connect to device which requires PIN code
  3. How to find services available on remote device
  4. How to synchronise Palm with a PC using Affix
  5. How to setup LAN connection between two Affix PCs
  6. How to push a business card to a Nokia mobile phone

Keyword syntax

<address> := 00:01:02:03:04:05
<PIN> := "12345"

<service> := SERial | LAN | DUN | HEAdset

How to find devices around me

kds> btclt discovery 4
Searching ...
Address: 00:80:37:ee:38:9f, Class: 0x520204, Name: "KDS-T68"
done.

or if you do not want to resolve remote names. This is faster:
kds> btclt inquiry 4

How to connect to device which requires PIN code

  1. Set PIN code.
    kds> btctl addpin <address> "1234"
    or
    kds> btctl addpin default "12345"

    PIN code can be up to 16 symbols.

  2. Cconnect to device.
    kds> btclt connect <address> [<service>]
    Serial service is used if omit.

How to find services available on remote device

kds> btclt browse <address>
or
kds> btclt search <address>
if btclt browse does not return any results. It happens because some devices does not support browsing. At least I have seen it with Digianswer Windows Bluetooth Stack ver. 1.09.

How to synchronise Palm with a PC using Affix

You need a Bluetooth firmware capable of connecting through the Serial Port Profile on both sides. Make sure that the drivers are installed properly on each end. In this example, I used a PCMCIA Nokia Connectivity Card DTL-4 and a Palm Vx with a Blue5 add-on extension card.
  1. Insert the card and start btsrv and btsrv daemons on your PC.
  2. Issue the command
    btctl addpin default <your_favourite_pin_code>
  3. Pair your Palm with your PC.
    First go to System->Prefs->Bluetooth and add your PC to the list. Then select General->Properties from the drop-down menu and press Pair. If it asks for the pincode, enter your pincode given on the PC side. Select Serial Port from the list. Once it's paired, select this entry as a default Bluetooth device.
  4. Establish Bluetooth connection from Palm to PC.
    Go to HotSync and select Local, Bluetooth (Serial). Start the HotSync operation.
  5. Synchronise the Palm with the PC.
    The virtual device /dev/bty0..4 is created on the PC side when the Bluetooth connection is established. The last digit in the device's name may vary according to the line which Affix is connected to (though usually it's 0). You may check it out with btclt status command. Finally, use the sync function of your favourite software.

How to setup LAN connection between two Affix PCs

Make sure that the Affix drivers are loaded properly and bt interface is up. Check it out with 'ifconfig'. The local bluetooth address (BD_ADDR) can be extracted with btctl bdaddr. Make sure the python-tk and python-gtk is installed and enable X display authorisation to the btsrv program's user account OR setup pincode manually with btctl addpin default <pincode>.
On the server side do
  1. Run btsrv.
Since affix starts up pppd, a proper PPP needs to be installed on your system. You may need to add a 'noauth' option to /etc/ppp/options, or comment out 'auth'. That's all.
On the client side do
  1. btctl pair <address>
  2. btctl connect <address> LAN
  3. pppd /dev/bty0 (with root rights).
Yep. Your LAN should be fired up, look out for default gateway. The remote peer's IP address is most probably 192.168.0.1, that's where the 'btsrv' is running.

How to push a business card to a Nokia phone

In this example we will push a standard business card file (.vcf) into a Bluetooth capable Nokia 6310. This requires that the Bluetooth functionality would be enabled on the phone. Try <menu-10> and select 'On'.

  1. Run btsrv.
  2. btctl pair <address-of-the-phone>
  3. btctl push <address-of-the-phone> file.vcf

The file's content with the .vcf extension should correspond to the standards. It's a simple text file. Here's a brief example for Nokia mobile phone:

BEGIN:VCARD
VERSION:2.1
N:Kristiina
TEL;PREF;CELL;VOICE:040-1234567
EMAIL:she@secret.fi
LABEL:beautiful
END:VCARD

For Nokia 7650 and N-Gage phones the format is:

BEGIN:VCARD
VERSION:2.1
N:Kristiina
TEL;CELL:040-1234567
END:VCARD

After pushing, the phone will report that a business card was received in a regular way. This method described here is supposed to work with practically all Bluetooth-enabled phones which has 'OBEX Object Push Profile' support.

END OF DOCUMENT