Strange behaviour of mainloop and dbus on different platform?
Mukesh Savaliya
Mukesh.Savaliya at MatrixComSec.com
Wed Aug 25 05:57:47 PDT 2010
Hello, is it that no body understands my English? Or no body is interested
in giving the reply?
-----Original Message-----
From: Mukesh Savaliya [mailto:Mukesh.Savaliya at MatrixComSec.com]
Sent: Saturday, August 21, 2010 5:37 PM
To: 'dbus at lists.freedesktop.org'
Subject: Strange behaviour of mainloop and dbus on different platform?
Hello dear Friends,
I have found the solution , but its mysterious. While running application
on ARM board, if I run g_main_loop_run() inside main(), and
g_main_loop_quit() inside a GThread,than application works, and talks to
each other. But,this works very slow.
Qt application puts the data on dbus immediately, but dbus is not
delievering the data to opposite application immediately. It is taking
nearly 1 sec time to get the data at this side.
Ans, still I am in doubt why I dont need to run g_main_loop_quit() on PC?
With regards,
Mukesh.
-----Original Message-----
From: dbus-bounces+mukesh.savaliya=matrixcomsec.com at lists.freedesktop.org
[mailto:dbus-bounces+mukesh.savaliya=matrixcomsec.com at lists.freedesktop.org]
On Behalf Of Mukesh Savaliya
Sent: Saturday, August 21, 2010 9:38 AM
To: dbus at lists.freedesktop.org
Subject: RE:What is required to run GMainLoop inside GThread with
Dbusfunctionality.
Hello, please reply to this, I am helpless.
I am suspecting on GThread functionality and its dependency on other
libraries. As, I have tried all the way, but still its not working. The same
thing is working on PC very well. This means PC library has all the requires
files, where as something is missing on ARM board.
Can anybody provide me the dependency files required for running GMainLoop
and GThread with Dbus?
-----Original Message-----
From: dbus-bounces+mukesh.savaliya=matrixcomsec.com at lists.freedesktop.org
[mailto:dbus-bounces+mukesh.savaliya=matrixcomsec.com at lists.freedesktop.org]
On Behalf Of Mukesh Savaliya
Sent: Friday, August 20, 2010 9:19 AM
To: 'Alban Crequy'
Cc: dbus at lists.freedesktop.org
Subject: RE: working of g_main_loop_run() and GThread on different platform.
Dear, Alban Crequy,
I have used strace ,and observed that DBusGProxy *Proxy =0. And error
message shows "Connection is closed".
But,I am wondering why this is happening only on ARM board. It gets
DbusGConnection connection=(int)xyz. But proxy is 0. And this happens only
when I use g_main_loop_run(mainloop),inside a thread.
What is missing than?
Thanks for replying.
-----Original Message-----
From: Alban Crequy [mailto:alban.crequy at collabora.co.uk]
Sent: Thursday, August 19, 2010 4:46 PM
To: Mukesh Savaliya
Cc: dbus at lists.freedesktop.org
Subject: Re: working of g_main_loop_run() and GThread on different platform.
Le Wed, 18 Aug 2010 14:25:27 +0530,
"Mukesh Savaliya" <Mukesh.Savaliya at MatrixComSec.com> a écrit :
> G_main_loop_run() which is running inside GThread. Is there any
> particular things in dbus or glib, which prevents
> the remote events invoking the callback function of Glib?
Can you use strace on the thread which is supposed to receive the
D-Bus signal? You will know whether or not your thread receives the
D-Bus signal on the socket.
1. If it is received, dbus_g_proxy_connect_signal is not done correctly.
Is there any error on stderr or syslog?
2. If it is not received:
2.1. Is your thread blocked on select() or poll()? You can check if
the file descriptor for D-Bus is correctly specified in select/poll.
2.2. You can also check with dbus-monitor whether the D-Bus method
call "AddMatch" is done correctly on the right object with the right
match rule when you create the proxy and when you connect to the D-Bus
signal.
BR,
Alban
_______________________________________________
dbus mailing list
dbus at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dbus
_______________________________________________
dbus mailing list
dbus at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dbus
More information about the dbus
mailing list