Linux bluetooth development
 help / color / mirror / Atom feed
* problem to disconnect with bluez-test
@ 2010-12-21  8:53 Goubert, TonyX
  2010-12-21  9:24 ` Johan Hedberg
  0 siblings, 1 reply; 6+ messages in thread
From: Goubert, TonyX @ 2010-12-21  8:53 UTC (permalink / raw)
  To: linux-bluetooth@vger.kernel.org

Hi all,

I use bluez-4.76.2.6 i586.rpm and bluez-test-4.76.2.6.i586.rpm in order to discover, connect, ...  

Link : repo.meego.com/MeeGo/builds/trunk/1.1.80.10.20101214.1/core/repos/ia32/packages/i586/

I have paired a handset with a laptop by using 'simple-agent' bluez-test script
BUT I can't disconnect it when I use the bluez stack.
I can remove it (./test-device remove xx:xx:xx:xx:xx:xx) but I want to be able to connect/disconnect/connect...

Is there a command?

Some handset traces:
[root@localhost test]# ./list-devices
    [ /org/bluez/369/hci0/dev_xx_xx_xx_xx_xx_xx ]
        Name = tllab54
        Paired = 1
        Adapter = /org/bluez/369/hci0
        Alias = tllab54
        Connected = 1
        UUIDs = 0x110a 0x110c 0x110e 0x1112 0x1115 0x1116 0x1117 0x111f 
        Address = xx:xx:xx:xx:xx:xx
        Services = dbus.Array([], signature=dbus.Signature('o'), variant_level=1)
        Class = 0x000000
        Trusted = 0
        Blocked = 0

[root@localhost test]# ./test-device disconnect xx:xx:xx:xx:xx:xx
Unknown command

[root@localhost test]# ./test-input disconnect xx:xx:xx:xx:xx:xx 
Traceback (most recent call last):
  File "./test-input", line 42, in <module>
    input.Disconnect()
  File "/usr/lib/python2.6/site-packages/dbus/proxies.py", line 68, in __call__
    return self._proxy_method(*args, **keywords)
  File "/usr/lib/python2.6/site-packages/dbus/proxies.py", line 140, in __call__
    **keywords)
  File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 630, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.UnknownMethod: Method "Disconnect" wt

BR

--
Tony Goubert
tonyx.goubert@intel.com

---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris, 
92196 Meudon Cedex, France
Registration Number:  302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: problem to disconnect with bluez-test
  2010-12-21  8:53 problem to disconnect with bluez-test Goubert, TonyX
@ 2010-12-21  9:24 ` Johan Hedberg
  2010-12-21 15:57   ` Goubert, TonyX
  0 siblings, 1 reply; 6+ messages in thread
From: Johan Hedberg @ 2010-12-21  9:24 UTC (permalink / raw)
  To: Goubert, TonyX; +Cc: linux-bluetooth@vger.kernel.org

Hi Tony,

On Tue, Dec 21, 2010, Goubert, TonyX wrote:
> I have paired a handset with a laptop by using 'simple-agent'
> bluez-test script BUT I can't disconnect it when I use the bluez
> stack.

I suppose you mean you can't disconnect it using the test scripts that
come with BlueZ (since I'm sure you *can* disconnect it with BlueZ as
long as you use the D-Bus interface directly).

> I can remove it (./test-device remove xx:xx:xx:xx:xx:xx) but I
> want to be able to connect/disconnect/connect...

The Device.Disconnect method is indeed something that should be added to
the test-device script. I just went ahead and pushed a patch for it
upstream.

> [root@localhost test]# ./test-device disconnect xx:xx:xx:xx:xx:xx
> Unknown command

This command should work with latest git now.

Johan

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: problem to disconnect with bluez-test
  2010-12-21  9:24 ` Johan Hedberg
@ 2010-12-21 15:57   ` Goubert, TonyX
  2010-12-21 22:24     ` Johan Hedberg
  2011-01-07  9:21     ` Developing app on top of nohands aji.kumar
  0 siblings, 2 replies; 6+ messages in thread
From: Goubert, TonyX @ 2010-12-21 15:57 UTC (permalink / raw)
  To: Johan Hedberg; +Cc: linux-bluetooth@vger.kernel.org

Hi Johan,
Thank you for your answer.

Yes, in fact, I want to use the test scripts in bluez to disconnect a device.

Well, I download the latest version of bluez (Bluez-4.82) and I have not find the command 'disconnect' in the script 'test-device'.
There are : list, create, remove, ... no disconnect.

> I just went ahead and pushed a patch for it upstream.

Can you give me your patch?

BR


--
Tony Goubert
tonyx.goubert@intel.com


-----Original Message-----
From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth-owner@vger.kernel.org] On Behalf Of Johan Hedberg
Sent: Tuesday, December 21, 2010 10:24 AM
To: Goubert, TonyX
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: problem to disconnect with bluez-test

Hi Tony,

On Tue, Dec 21, 2010, Goubert, TonyX wrote:
> I have paired a handset with a laptop by using 'simple-agent'
> bluez-test script BUT I can't disconnect it when I use the bluez
> stack.

I suppose you mean you can't disconnect it using the test scripts that
come with BlueZ (since I'm sure you *can* disconnect it with BlueZ as
long as you use the D-Bus interface directly).

> I can remove it (./test-device remove xx:xx:xx:xx:xx:xx) but I
> want to be able to connect/disconnect/connect...

The Device.Disconnect method is indeed something that should be added to
the test-device script. I just went ahead and pushed a patch for it
upstream.

> [root@localhost test]# ./test-device disconnect xx:xx:xx:xx:xx:xx
> Unknown command

This command should work with latest git now.

Johan
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris, 
92196 Meudon Cedex, France
Registration Number:  302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: problem to disconnect with bluez-test
  2010-12-21 15:57   ` Goubert, TonyX
@ 2010-12-21 22:24     ` Johan Hedberg
  2010-12-22 11:02       ` Goubert, TonyX
  2011-01-07  9:21     ` Developing app on top of nohands aji.kumar
  1 sibling, 1 reply; 6+ messages in thread
From: Johan Hedberg @ 2010-12-21 22:24 UTC (permalink / raw)
  To: Goubert, TonyX; +Cc: linux-bluetooth@vger.kernel.org

Hi Tony,

On Tue, Dec 21, 2010, Goubert, TonyX wrote:
> Yes, in fact, I want to use the test scripts in bluez to disconnect a
> device.
> 
> Well, I download the latest version of bluez (Bluez-4.82) and I have
> not find the command 'disconnect' in the script 'test-device'.
> There are : list, create, remove, ... no disconnect.

Obviously that's the case since 4.82 was released before I created the
patch.

> > I just went ahead and pushed a patch for it upstream.
> 
> Can you give me your patch?

As I said, it's upstream. You can get it from there:

http://git.kernel.org/?p=bluetooth/bluez.git;a=summary
http://git.kernel.org/?p=bluetooth/bluez.git;a=commitdiff;h=dd109a698c149a805f19cd2a7ddd0cbb8434f965

Johan

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: problem to disconnect with bluez-test
  2010-12-21 22:24     ` Johan Hedberg
@ 2010-12-22 11:02       ` Goubert, TonyX
  0 siblings, 0 replies; 6+ messages in thread
From: Goubert, TonyX @ 2010-12-22 11:02 UTC (permalink / raw)
  To: Johan Hedberg; +Cc: linux-bluetooth@vger.kernel.org

Hello,
Thank you for your answer.
This command is ok, I can disconnect.

Well, I'm a newbie in python but I'm interesting to contribute.
Is there a documentation which describes the command that we can develop?
For example, now I want to be able to connect after a disconnect.
BR. 

--
Tony Goubert
tonyx.goubert@intel.com

-----Original Message-----
From: Johan Hedberg [mailto:johan.hedberg@gmail.com] 
Sent: Tuesday, December 21, 2010 11:24 PM
To: Goubert, TonyX
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: problem to disconnect with bluez-test

Hi Tony,

On Tue, Dec 21, 2010, Goubert, TonyX wrote:
> Yes, in fact, I want to use the test scripts in bluez to disconnect a
> device.
> 
> Well, I download the latest version of bluez (Bluez-4.82) and I have
> not find the command 'disconnect' in the script 'test-device'.
> There are : list, create, remove, ... no disconnect.

Obviously that's the case since 4.82 was released before I created the
patch.

> > I just went ahead and pushed a patch for it upstream.
> 
> Can you give me your patch?

As I said, it's upstream. You can get it from there:

http://git.kernel.org/?p=bluetooth/bluez.git;a=summary
http://git.kernel.org/?p=bluetooth/bluez.git;a=commitdiff;h=dd109a698c149a805f19cd2a7ddd0cbb8434f965

Johan
---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris, 
92196 Meudon Cedex, France
Registration Number:  302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Developing app on top of nohands..
  2010-12-21 15:57   ` Goubert, TonyX
  2010-12-21 22:24     ` Johan Hedberg
@ 2011-01-07  9:21     ` aji.kumar
  1 sibling, 0 replies; 6+ messages in thread
From: aji.kumar @ 2011-01-07  9:21 UTC (permalink / raw)
  To: linux-bluetooth

Hi All,

Please clarify my basic questions below on using bluez.

1. For developing a application on top of nohands I need to make use of    hfpd provided DBus Apis?
2. For developing an application for PBAP or OPP..etc I need to make use of obexd provided DBus Apis?

3. When I need to run the developed application, I need to ensure my application is linked to the nohands(libhfp.so), openobex(similar ".so" file ) and add to these the daemons like hfpd,obexd etc..running


Please correct me if I am wrong in any of the above statements.

With thanks and regards
Aji.


This message is for the designated recipient only and may contain privileged, proprietary, or otherwise private information.  If you have received it in error, please notify the sender immediately and delete the original.  Any other use of the email by you is prohibited.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2011-01-07  9:21 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-21  8:53 problem to disconnect with bluez-test Goubert, TonyX
2010-12-21  9:24 ` Johan Hedberg
2010-12-21 15:57   ` Goubert, TonyX
2010-12-21 22:24     ` Johan Hedberg
2010-12-22 11:02       ` Goubert, TonyX
2011-01-07  9:21     ` Developing app on top of nohands aji.kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox