Stoppt die Vorratsdatenspeicherung! Jetzt klicken & handeln!
niemueller.de::home niemueller.de
Open Software. Open Knowledge.




 
Difference (from revision 1 to current revision) (minor diff)
(The revisions are identical or unavailable.)

Copy files to a Nokia 6230 via Bluetooth



What is this about?

Here is a short description how to copy files via OBEX File Transport to a Nokia 6230 on a Linux machine. Note that this is not OBEX Push, which is used pretty often. OBEX File Transfer allows you to retrieve and copy files from and to all available directories. On the 6230 This is the complete Gallery directory and the MMC for example.

Requirements

I used a Fedora Core 2 with Linux kernel 2.6.5 and the [BlueZ Bluetooth stack] which is the default in the Linux Kernel. This may or may not work with different distros, kernels and bluetooth stack - try for yourself. You will also need openobex libraries and headers as we will use ObexFTP to transfer the files.

Setup

I will not discuss how to setup bluetooth on your system. This is described in many other documents. See the BlueZ homepage for tons of HOWTOs. Now install openobex. On Fedora Core with apt installed this is as simple as typing apt-get install openobex openobex-devel openobex-apps as root. Make sure that bluez-libs, bluez-libs-devel, bluez-sdp and bluez-utils are installed. Set your phone now to be discoverable by anybody in the bluetooth settings menu. Then type as root on the linux machine hcitool scan. This will hopefully show your mobile phone and its device ID like 00:11:22:33:44:55 (If not read the pages on the BlueZ homepage for more info). I will call the device ID now always 00:11:22:33:44:55, replace it everytime with the one you found out. Now we are going to browse the phones services to get a pairing done. Type sdptool browse 00:11:22:33:44:55. If you are running X this will bring up a prompt asking for a pairing key. Type a 4-digit number. Enter the same number on the phone. Now you should see a list of available services on your phone. Look out for something like
Service Name: OBEX File Transfer
Service RecHandle: 0x1000f
Service Class ID List:
  "OBEX File Transfer" (0x1106)
Protocol Descriptor List:
  "L2CAP" (0x0100)
  "RFCOMM" (0x0003)
    Channel: 10
  "OBEX" (0x0008)
Language Base Attr List:
  code_ISO639: 0x656e
  encoding:    0x6a
  base_offset: 0x100
Profile Descriptor List:
  "OBEX File Transfer" (0x1106)
    Version: 0x0100
You will need the channel that is shown for the OBEX File Transfer service.

Then edit /etc/bluetooth/rfcomm.conf and add the following entry:
rfcomm0 {
        device 00:11:22:33:44:55;
        channel 9;
        comment "Nokia 6230 OBEX File Transport";
}
Replace 00:11:22:33:44:55 and channel with the data you got from the scan. You will need the device ID again below. I will always write down the place holder value. Replace it everytime.

Getting ObexFTP

Get the software from the [ObexFTP] webpage. I have build RPMs for Fedora Core 2 that you can get at http://www.niemueller.de/projects/extrpms/. Build these packages as described in the package. With the newest snapshot there is no longer a patch needed for subdir transfers.

Transferring files

Now that you have ObexFTP on your machine you can start transferring files. You can get files from your mobile with
obexftp -b 00:11:22:33:44:55 -c PATH -g FILE
where path is the path on your mobile, for example "Gallery/Sounds?" and FILE the actual filename like "background.gif". You can copy files to your mobile phone with
obexftp -b 00:11:22:33:44:55 -c PATH -p FILE
Note: With the version I am using it seems that you must be in the directory that the file you want to copy is in. PATH and FILE have the same meanings as above.

To copy file to and from the MMC just give the name of the MMC as path. For example if the MMC is named "MemoryCard?" then you would use "Gallery/MemoryCard?" as the path.
    Home     Contents     Search     View other revisions     Recent changes    




Top 5 Pages
Wiki
WebLog
SquidGuard Webmin Module
Network Utilities Webmin Module
IPtables Webmin Module


Palm Software
UniMatrix UniMensa UniSorter
UniChat OHS Mobile Onager


My Bookshelf




Valid XHTML 1.1!

RSS Copyright © 2000-2009 by Tim Niemueller