LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-27-2006, 05:00 PM   #1
gbowden
Member
 
Registered: Dec 2003
Location: Spain
Distribution: Slackware 14.1 64bit - multilib
Posts: 148

Rep: Reputation: 28
Question Bluetooth File Transfer Problem


I'm having problems sending files to my mobile phone using bluetooth.

I've downloaded and compiled the following:

Code:
23:26:59 root@gbnet:~# lah /var/log/packages/ | grep bluez
-rw-r--r--  1 root   root  645 2006-12-27 22:15 bluez-hcidump-1.33-i386-1
-rw-r--r--  1 root   root 1.3K 2006-12-27 22:13 bluez-libs-3.8-i386-1
-rw-r--r--  1 root   root 1.8K 2006-12-27 22:18 bluez-utils-3.8-i386-1
23:27:02 root@gbnet:~# lah /var/log/packages/ | grep kdeblue*
-rw-r--r--  1 root   root  30K 2006-12-27 22:30 kdebluetooth-1.0_beta2-i386-1
My /etc/bluetooth/hcid.conf file has the following:

Code:
#
# HCI daemon configuration file.
#

# HCId options
options {
        # Automatically initialize new devices
        autoinit yes;

        # Security Manager mode
        #   none - Security manager disabled
        #   auto - Use local PIN for incoming connections
        #   user - Always ask user for a PIN
        #
        security user;

        # Pairing mode
        #   none  - Pairing disabled
        #   multi - Allow pairing with already paired devices
        #   once  - Pair once and deny successive attempts
        pairing multi;

        # Default PIN code for incoming connections
        passkey "1234";
}

# Default settings for HCI devices
device {
        # Local device name
        #   %d - device id
        #   %h - host name
        name "BlueZ (%d)";

        # Local device class
        class 0x3e0100;

        # Default packet type
        #pkt_type DH1,DM1,HV1;

        # Inquiry and Page scan
        iscan enable; pscan enable;

        # Default link mode
        #   none   - no specific policy
        #   accept - always accept incoming connections
        #   master - become master on incoming connections,
        #            deny role switch on outgoing connections
        lm accept;

        # Default link policy
        #   none    - no specific policy
        #   rswitch - allow role switch
        #   hold    - allow hold mode
        #   sniff   - allow sniff mode
        #   park    - allow park mode
        lp rswitch,hold,sniff,park;
}
My rfcomm.conf file is the following:

Code:
#
# RFCOMM configuration file.
#

rfcomm0 {
        # Automatically bind the device at startup
        bind yes;

        # Bluetooth address of the device
        device 00:18:A4:62:D5:8C;

        # RFCOMM channel for the connection
        channel 2;

        # Description of the connection
        comment "My Mobile";
}
My rc.bluetooth does the following:

Code:
#!/bin/sh
# Start/stop/restart the bluetooth services:
ISDBUS_RUNNING=`ps -A | grep dbus-daemon | cut -d '-' -f 2`
if [ "$ISDBUS_RUNNING" = "daemon" ]; then
if [ "$1" = "stop" ]; then
  echo "Stopping bluetooth services..."
  killall hcid > /dev/null
  killall hcid > /dev/null
  killall sdpd > /dev/null
  killall hidd > /dev/null
  killall rfcomm > /dev/null
  killall dund > /dev/null
  killall rmmod bnep
  killall pand > /dev/null
  killall hciconfig > /dev/null

elif [ "$1" = "restart" ]; then
  echo "Restarting bluetooth services..."
  killall hcid > /dev/null
  sleep 1
  /usr/sbin/hcid -f /etc/bluetooth/hcid.conf
#  /usr/local/sbin/hciconfig hci0 up
#  /usr/local/sbin/hciconfig hci0 iscan
else # assume $1 = start:
  echo "Starting bluetooth, configuration from /etc/bluetooth/hcid.conf"
/usr/local/sbin/hid2hci -0 -q
/bin/sleep 1
/usr/local/sbin/hcid -f /etc/bluetooth/hcid.conf
/usr/local/sbin/sdpd
/usr/local/bin/hidd --server
/usr/local/bin/rfcomm -f /etc/bluetooth/rfcomm.conf bind all
/usr/local/bin/dund --listen --persist --msdun call ppc
modprobe bnep
/usr/local/bin/pand --listen --role GN
/usr/local/sbin/hciconfig hci0 piscan BlueZ class 0x100100
#  /usr/sbin/hcid -f /etc/bluetooth/hcid.conf
#  /usr/local/sbin/hciconfig hci0 up
#  echo "Executing: hciconfig hci0 iscan"
#  /usr/local/sbin/hciconfig hci0 iscan
fi
else
  echo "Trying to initialize DBUS"
  if [ -x /etc/rc.d/rc.messagebus -a -x /var/run/dbus/pid ]; then
        rm -f /var/run/dbus/pid
        /etc/rc.d/rc.messagebus restart
  elif [ -x /usr/bin/dbus-daemon ]; then
        /usr/bin/dbus-daemon --system
        echo "Initialized dbus, restarting bluetooth services"
        /etc/rc.d/rc.bluetooth
  fi
fi
The following happens when using kbtobexclient:

Code:
23:55:13 root@gbnet:/etc/rc.d# kbtobexclient
Using hci0 as default bluetooth device.
Using hci0 as default bluetooth device.
kbtobexclient: HciSocket::open()
kbtobexclient: Item -1
kbtobexclient: Send HCI inquiry command..
kbtobexclient: HciSocket::readStatus()
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=1 cmdOpcode=1025
kbtobexclient: HciSocket::readStatus(ogf=1,ocf=1,timeout=1000) = 0
kbtobexclient: Inquiry started successfully
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: INQUIRY_RESULT_WITH_RSSI: 00:18:A4:62:D5:8C
kbtobexclient: Item -1
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=34 packetLength=15
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=12 numPkts=1 cmdOpcode=1025
kbtobexclient: Inquiry: hci packet received: eventCode=1 packetLength=1
kbtobexclient: EVT_INQUIRY_COMPLETE status=\x00
kbtobexclient: Inquiry ended successfully
kbtobexclient: appended sdp uuid: 0x00001105:00001000:80000080:5f9b34fb
kbtobexclient: Added service
kbtobexclient: Using default language base
kbtobexclient: Decode string with UTF-8 codec
kbtobexclient: Service updated: addr=00:18:A4:62:D5:8C aVer=1 cVer=1 devCl=262736 ch=2 uuids=0x00001105:00001000:80000080:5f9b34fb
kbtobexclient: Item -1
kbtobexclient: Service 'OPP' used (Wed Dec 27 23:55:25 2006)
kbtobexclient: Service 'OPP' used (Wed Dec 27 23:55:25 2006)
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=1 cmdOpcode=1029
kbtobexclient: Inquiry: hci packet received: eventCode=3 packetLength=11
kbtobexclient: Inquiry: hci packet received: eventCode=19 packetLength=5
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=0 cmdOpcode=1051
kbtobexclient: Inquiry: hci packet received: eventCode=27 packetLength=3
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=1 cmdOpcode=0
kbtobexclient: Inquiry: hci packet received: eventCode=19 packetLength=5
kbtobexclient: Inquiry: hci packet received: eventCode=14 packetLength=6
kbtobexclient: Inquiry: hci packet received: eventCode=11 packetLength=11
kbtobexclient: Inquiry: hci packet received: eventCode=19 packetLength=5
kbtobexclient: Inquiry: hci packet received: eventCode=19 packetLength=5
kbtobexclient: Inquiry: hci packet received: eventCode=19 packetLength=5
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=1 cmdOpcode=1049
kbtobexclient: Inquiry: hci packet received: eventCode=19 packetLength=5
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=0 cmdOpcode=1049
kbtobexclient: Inquiry: hci packet received: eventCode=7 packetLength=255
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=1 cmdOpcode=0
kbtobexclient: Inquiry: hci packet received: eventCode=7 packetLength=255
kbtobexclient: insertItem
slotNewItem
kbtobexclient: Inquiry: hci packet received: eventCode=15 packetLength=4
kbtobexclient: EVT_CMD_STATUS status=0 numPkts=1 cmdOpcode=1030
kbtobexclient: Inquiry: hci packet received: eventCode=5 packetLength=4
kbtobexclient: RfcommSocket::connectToHost(00:18:A4:62:D5:8C, 2)
And kbtobexclient stops responding.

Any ideas anyone?

Regards,

Greg

Last edited by gbowden; 12-27-2006 at 05:27 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
pc to mobile file transfer problem nbb Linux - Software 1 12-26-2006 10:13 AM
Problem with file transfer and SATA Blue1K MEPIS 4 07-26-2005 11:54 PM
Yahoo Messenger File Transfer Problem njugs79 Linux - Newbie 1 06-23-2005 05:47 PM
Gaim file transfer problem Wynd Linux - Software 3 09-08-2003 11:56 AM
File transfer problem aldaeron Linux - Networking 3 08-05-2002 09:01 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 06:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration