Questions tagged [dbus]

D-Bus is a message bus system, which allows client programs to call procedures on a service - basically, the machine-local equivalent to XML-RPC and SOAP.

D-Bus is a message bus system, designed to provide ways for programs to communicate with each other. D-Bus uses remote procedures to allow a client to call methods on a "service", and is conceptually similar to XML-RPC and SOAP. D-Bus, however, is designed for use in applications running on a single system. The FAQ offers a comparison to other well known IPC systems, as well as other general questions.

D-Bus is, in addition to an implementation, a specification - the document itself is freely available. In addition, an Introduction To D-Bus gives a high-level overview of how D-Bus is designed.

D-Bus, although used on POSIX systems (usually Linux and the *BSDs), has been ported to Windows and has been officially added to the specification.

D-Bus related questions will typically be how do I accomplish [X] in D-Bus - D-Bus is technical enough that most any question relating to it will be on topic.

1376 questions
20
votes
5 answers

How to compile a basic D-Bus/glib example?

I'm trying to learn how to use D-Bus with C bindings. I've never used D-Bus before. I'm following this tutorial, which I assume is the official one (Freedesktop.org). I've read it until this paragraph that gives a first sample program , but…
tvuillemin
  • 1,148
  • 3
  • 10
  • 25
18
votes
6 answers

How to export DBUS_SESSION_BUS_ADDRESS

I'm trying to run D-Bus on an embedded system (Yocto Linux) and connect to it from my application code. I get the following error when I call dbus_bus_get(DBUS_BUS_SESSION, &err); Using X11 for dbus-daemon autolaunch was disabled at compile time,…
User55412
  • 882
  • 2
  • 10
  • 27
17
votes
2 answers

USB devices UDev and D-BUS

I am trying to get a list of currently plugged in USB devices in Ubuntu 10.10 and monitor changes that happen, like devices being plugged in or out using UDev and D-BUS. I'm fairly new to programming using D-BUS. I saw one example: Linux : How to…
Calota Romeo
  • 173
  • 1
  • 1
  • 4
16
votes
1 answer

MPRIS + Python (dbus): reading and writing properties

I have already checked this link: How to handle properties of a dbus interface with python. However, that only lists an API... but I don't know where that API comes from. I just started working with dbus (pretty excited about this, to be honest ^__^…
Mamsaac
  • 6,173
  • 3
  • 21
  • 30
16
votes
2 answers

Getting signals working on PulseAudio's DBus interface?

I'm trying to get a D-Bus signal handler to be called whenever the state of a sink changes in PulseAudio (e.g. becomes inactive). Unfortunately, it isn't being called and I frankly am not sure why. import dbus import dbus.mainloop.glib from…
Yet Another User
  • 2,627
  • 3
  • 18
  • 27
15
votes
4 answers

How to use a variant dictionary (`a{sv}`) in dbus-send

I have some trouble with dbus-send when using a{sv} Calling a method with in_signature='a{ss}' seems to work using the following command line: dbus-send --dest="org.test.TestService" /org/test/TestService/object org.test.TestService.method1…
camino
  • 10,085
  • 20
  • 64
  • 115
15
votes
2 answers

Difference between DBus and other Interprocess Communications method

When i studied about Linux interprocess Communications, i have known there were some method as: pipe, message queue, socket, signal, shared memory, semaphore and there is no method named Dbus. But today, when i research about Dbus, i read that:…
Viet
  • 553
  • 1
  • 4
  • 18
14
votes
1 answer

BlueZ D-Bus C or C++ Sample

I am trying to write an application which searches Bluetooth devices nearby and communicates with them. My application is going to be written in C++, and intended to work under Linux. 4 years ago, I used BlueZ. But now, as I see, the API has been…
jnbrq -Canberk Sönmez
  • 1,790
  • 1
  • 17
  • 29
13
votes
3 answers

DBusWatch and DBusTimeout examples

I need to write an application in C for asynchronous sending and reading messages on the dbus message queue. I've read that for doing that I should use the DBusWatch and DBusTimeout objects that the connection provides, but I cannot find an example…
Ioanna
  • 1,311
  • 2
  • 23
  • 36
13
votes
4 answers

How do I use Emacs's DBUS interface?

I looked up the dbus package and it seems like all of the functions are built-in to the C source code and there's no documentation for them. How do I use the dbus-call-method function?
user9903
13
votes
2 answers

Python and d-bus: How to set up main loop?

I have a problem with python and dbus. I checked out the developer docs and specifications, but I don't understand how to set up a main loop. I want to listen for notification events. See http://dbus.freedesktop.org/doc/dbus-python/doc/…
f4lco
  • 3,728
  • 5
  • 28
  • 53
13
votes
6 answers

Temporarily prevent linux from shutting down

I have a backup script that runs in the background daily on my linux (Fedora 9) computer. If the computer is shut down while the backup is in progress the backup may be damaged so I would like to write a small script that temporarily disables the…
Jon Levell
13
votes
1 answer

D-Bus: Performance improvement practices

What are some good practices to obtain better time performance in applications that heavily utilize D-Bus? Here are a few that our team has learned through the school of hard knocks: Try to combine data entities together into a single, large…
J. Polfer
  • 12,251
  • 10
  • 54
  • 83
13
votes
1 answer

Using go.dbus with omxplayer on Raspberry Pi

I am trying to using the D-Bus interface on omxplayer in order to control the running video. I'm attempting this using the go.dbus library found here: https://github.com/guelfey/go.dbus The omxplayer documentation provides a dbuscontrol.sh script…
Majormjr
  • 183
  • 1
  • 2
  • 7
13
votes
2 answers

Waiting for a DBus service to be available in Qt

With a Qt DBus proxy built on QDbusAbstractInterface (via qdbusxml2cpp), what's the best way to handle the service/object you want to interface to not being available when you start? Note: I'm not interested in simply knowing it (you can use…
jesup
  • 6,765
  • 27
  • 32
1
2
3
91 92