Bluetooth Connection between Linux and Nokia 6820 Cell Phone

Bluetooth Connection between Linux and Nokia 6820 Cell Phone

Bluetooth creates a wireless connection between phone and computer, allowing transfer of calendar events, contacts, ringtones and background images. Bluetooth is more practical than wires but less secure.

© 2005 Tero Karvinen


Enable bluetooth on phone. Connect USB dongle to computer.

Choose a password (PIN) in /etc/bluetooth. The same password must be set in phone.

# /etc/bluetooth/pin -

Pin (password) use must be enabled in hcid.conf. (It was not default in Ubuntu 5.04).

# /etc/bluetooth/hcid.conf -
options {
        autoinit yes;
        security user;
        pairing multi;
        pin_helper /usr/bin/bluez-pin;
device {
        name "%h-%d";
        class 0x100;
        iscan enable; pscan enable;
        lm accept;
        lp rswitch,hold,sniff,park;

Install gammu, the free phone manager similar to gnokii:

$ sudo apt-get install gammu

Setup gammu to use bluetooth. Note that

  • Model is set to 6800 (not 6820), because 6800 works and gammu does not (yet) know about 6820.
  • Port is the bluetooth hardware address of phone
# ~/.gammurc -
port = 00:02:FE:A2:F3:GF
model = 6800
connection = bluephonet
synchronizetime = yes
logfile = /home/tee/.gammulog
logformat = textalldate
use_locking =
gammuloc =

Test connection.

$ gammu --identify
Manufacturer  : Nokia
Model         : 6820 (NHL-9)

If gammu printed your phone model, it works.

It Works, Now What?

Backup everything

$ echo "ALL" | gammu --backup foo

File suffix matters. That’s why we are using “foo” as a filename here. Because we chose unicode (UTF-8) characters, it is easier to edit the file with vim than nano

$ vim foo

Use “<esc>:wq” to exit vim.

Gammu also allows transfer of calendar or contacts separately. The file suffix (.vcf or .vcs) defines which one is transferred.

If you get multisync to work with 6820, please drop me a line.


Backup (download) calendar to computer

$ echo "ALL" | gammu --backup calendar.vcs

Edit it

$ nano calendar.vcs

And restore (upload) it back to phone

$ echo "ALL" | gammu --restore calendar.vcs

The ‘echo “ALL”’ just answers yes to the question “Restore phone calendar notes” or “Backup phone calendar notes”.

To convert between different implementations of calendar standards, use vcalone.


Backup (download) contacts to computer

$ echo "ALL" |gammu --backup contacts.vcf



You have all the settings as above, but phone does not answer.

$ gammu --identify
"No response in specified timeout. Probably phone not connected."

Even more weirdly, gammu logfile shows phone name that it must have got from the phone.

Tue 2006/07/25 18:01:43: Device 00:02:FE:A2:F3:GF ("tero")
[ERROR 14: No response in specified timeout. Probably phone not connected.]

Fix: start bluetooth daemon:

$ sudo /etc/init.d/bluez-utils start
 * Starting Bluetooth services...
 hcid sdpd   ...done.

Now it works:

$ gammu --identify
Manufacturer  : Nokia
Model         : 6820 (NHL-9)


Configuration files can be printed without comments and empty lines using:

$ cat ~/.gammurc|grep -v '^s*#'|grep -v '^s*$'

Test setup: Nokia 6820 (phone), Ubuntu 5.04 Hoary (distro), Billionton Bluetooth (USB Bluetooth dongle). Tested by Tero 2005-09-25

Posted in Old Site | Tagged , , , , , , | Comments Off on Bluetooth Connection between Linux and Nokia 6820 Cell Phone

Comments are closed.