1 Reply Latest reply on Jul 7, 2015 9:54 AM by arfoll

    How to check DBUS interfaces and methods on Edison

    kurtqiao

      hi,

      i try to write a c program which use DBUS(dbus-glib),

      i wrote a little sample to get bluetooth default adapter by 'org.bluez.Manager.DefaultAdapter',

      and it runs well on my linux, but fail on edison.

       

      when i use 'dbus-send --system --dest=org.bluez --print-reply / org.bluez.Manager.DefaultAdapter',

      it returns DBus.Error.UnknownMethod, obviously don't have such a method on Edison DBUS.

       

      due to i can't use python tool like 'd-feet', my questions is how do i know how many DBUS interfaces and methods

      supported on edison?

      anyone familar can show me a way, very appreciate!

        • 1. Re: How to check DBUS interfaces and methods on Edison
          arfoll

          You need to use dbus introspection, using dbus-send is a bit nasty but it looks like this:

          dbus-send --system --type=method_call --print-reply --dest=org.bluez /org/bluez org.freedesktop.DBus.Introspectable.Introspect

          My advice is to prototype using python-dbus, it's really nice and will let you do things on the python interpreter that are much harder to achieve via dbus-send.