public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: "Mahin Gupta" <mahingupta@gmail.com>
To: bluez-users@lists.sourceforge.net
Subject: [Bluez-users] problem in parking device. bluez-libs 3.14, bluez-utils-3.14
Date: Fri, 24 Aug 2007 13:06:22 +0530	[thread overview]
Message-ID: <c669a7c70708240036j38c8f42bhdcdb5ee15a8ae4be@mail.gmail.com> (raw)


[-- Attachment #1.1: Type: text/plain, Size: 2394 bytes --]

Hi
I am trying to park one bluetooth device.

First of all i have tried to use the bluez hci.c function hci_park_mode() to
park this device.
I have used the function in following manner


       if( hci_park_mode(dd, handle, 0x200, 0x100, 25000) < 0 )
      {
         printf("\n Unable to park ...\n");
      }
       I am getting the handle correct here.

These is the concerned part of code.. but I am not getting the device
parked...
then I tried to check whether I can park it using hcitool cmd or not

This is the hciconfig -a output of my Master device

// Master
# hciconfig -a
hci0:   Type: UART
        BD Address: 00:80:37:2E:4C:C3 ACL MTU: 339:11 SCO MTU: 93:14
        UP RUNNING PSCAN ISCAN
        RX bytes:152425 acl:2402 sco:0 events:10389 errors:0
        TX bytes:87079 acl:2791 sco:0 commands:3526 errors:0
        Features: 0xff 0xff 0x8f 0xfe 0x9b 0xf9 0x00 0x80
        Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
        Link policy: RSWITCH HOLD SNIFF PARK
        Link mode: SLAVE ACCEPT
        Name: 'LB:[unknown]'
        Class: 0x820116
        Service Classes: Networking
        Device Class: Computer, Palm
        HCI Ver: 2.0 (0x3) HCI Rev: 0x62b9 LMP Ver: 2.0 (0x3) LMP Subver:
0x62b9
        Manufacturer: Infineon Technologies AG (9)

Slave has the same configuration and its Link policy is also   Link policy:
RSWITCH HOLD SNIFF PARK

These is the output of hcitool con
# hcitool con
Connections:
        < ACL 11:11:11:11:11:11 handle 512 state 1 lm MASTER
        < ACL 00:80:37:2E:45:1E handle 256 state 1 lm MASTER

# hcitool cmd 0x02 0x005 0x0200 0x0090 0x000E
< HCI Command: ogf 0x02, ocf 0x0005, plen 3
  00 90 0E
> HCI Event: 0x0f plen 4
  12 01 05 08

# hcitool cmd 0x02 0x005 0x0100 0x0090 0x000E
< HCI Command: ogf 0x02, ocf 0x0005, plen 3
  00 90 0E
> HCI Event: 0x0f plen 4
  12 01 05 08

By searching into mailing list archieve ( link :
http://article.gmane.org/gmane.linux.bluez.devel/269/match=park )
I came to know that may be my parameters are wrong but I am not able to
understand what is wrong ..

One more thing.. hcitool con returns me handle as 256 ( hex 0x100 ).. Now
when I am giving this as first parameter in hcitool cmd the hex_dump
function in
hcitool.c prints only last two digits i.e. 00 . .. so I am a bit confused
that is my handle is passing correctly or not ?

Thnx for any help in advance...

Regards,
Mahin Gupta

[-- Attachment #1.2: Type: text/html, Size: 3633 bytes --]

[-- Attachment #2: Type: text/plain, Size: 315 bytes --]

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/

[-- Attachment #3: Type: text/plain, Size: 164 bytes --]

_______________________________________________
Bluez-users mailing list
Bluez-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-users

             reply	other threads:[~2007-08-24  7:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-24  7:36 Mahin Gupta [this message]
2007-08-24  8:24 ` [Bluez-users] problem in parking device. bluez-libs 3.14, bluez-utils-3.14 Marcel Holtmann
2007-08-25 19:26   ` Tom Allebrandi
2007-08-28 12:34     ` Mahin Gupta
2007-08-28 12:44       ` Marcel Holtmann
2007-08-29  7:35     ` Mahin Gupta
2007-08-29  8:23       ` Marcel Holtmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c669a7c70708240036j38c8f42bhdcdb5ee15a8ae4be@mail.gmail.com \
    --to=mahingupta@gmail.com \
    --cc=bluez-users@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox