Bluez D-Bus API problems

Stuart Langridge sil at kryogenix.org
Mon Mar 12 17:40:31 PDT 2007


I've been playing with the Bluez D-Bus API, which unfortunately
doesn't support introspection, and I'm running into problems. For
example, when i try and use the RFCOMM interface, like so:

rfcomm = dbus.Interface(
    bus.get_object('org.bluez', manager.DefaultAdapter()),
    'org.bluez.RFCOMM')
devname = rfcomm.Connect(addr, 'ftp')

as per James at http://blogs.gnome.org/view/jamesh/2006/10/19/0, I get

Exception dbus_bindings.DBusException: 'Method "Connect" with
signature "ss" on interface "org.bluez.RFCOMM" doesn\'t exist' in
'dbus_bindings._GIL_safe_cmessage_function_handler' ignored

I've tried browsing the Bluez source, and I think that
http://bluez.cvs.sourceforge.net/bluez/utils/hcid/dbus-rfcomm.c?revision=1.45&view=markup#l_591
is the relevant function that gets called as Connect(), but I don't
know how to read that function to work out what its signature actually
is (because I'm not very good at C). What do I need to look for to
work out what the function signature is, so I don't have to keep
begging for help every time this problem comes up?

sil

-- 
"Willow hath gat hare off rede
 And doth geev soopurb heede.
 Buffy, as written by Geoffrey Chaucer, the dirty mediaeval git."
           -- Andy Spencer, after Certic


More information about the dbus mailing list