Active Topics

 


Reply
Thread Tools
calvin_42's Avatar
Posts: 286 | Thanked: 219 times | Joined on Feb 2010 @ France
#1
Hi!

Here is my question : how to check if the device is locked using dbus. I don't want to trigger an action when the signal "locked" is send, I just want to check the current state using dbus-send.

So the following code locks the device :

Code:
dbus-send --system --type=method_call --dest=com.nokia.mce /com/nokia/mce/request com.nokia.mce.request.req_tklock_mode_change string:"locked"
Which makes dbus send the following signal :

Code:
signal sender=:1.9 -> dest=(null destination) serial=342 path=/com/nokia/mce/signal; interface=com.nokia.mce.signal; member=tklock_mode_ind
   string "locked"
But I have no idea which method to call to get the status. I would like to run something like :

Code:
dbus-send --system --type=method_call --print-reply --dest=com.nokia.mce /com/nokia/mce/ string:"com.nokia.mce.signal.tklock_mode_ind"
Any idea ? Thanks
__________________
AutoDisconnect automatically closes your idle connections (Wifi/3G/Bluetooth) and switches the network mode to 2G when 3G is not used. [ Thread ] [ Wiki ] [ Donate ]
 
qwerty12's Avatar
Posts: 4,274 | Thanked: 5,358 times | Joined on Sep 2007 @ Looking at y'all and sighing
#2
 

The Following User Says Thank You to qwerty12 For This Useful Post:
calvin_42's Avatar
Posts: 286 | Thanked: 219 times | Joined on Feb 2010 @ France
#3
Once again, you are my saviour qwerty12!

Thanks a lot! Where can I find this kind of information in the future? Like this doc.
__________________
AutoDisconnect automatically closes your idle connections (Wifi/3G/Bluetooth) and switches the network mode to 2G when 3G is not used. [ Thread ] [ Wiki ] [ Donate ]
 

The Following User Says Thank You to calvin_42 For This Useful Post:
qwerty12's Avatar
Posts: 4,274 | Thanked: 5,358 times | Joined on Sep 2007 @ Looking at y'all and sighing
#4
Originally Posted by calvin_42 View Post
Once again, you are my saviour qwerty12!


Originally Posted by calvin_42 View Post
Thanks a lot! Where can I find this kind of information in the future? Like this doc.
Despite being closed source, MCE does have a nice page listing the signals it'll emit and the D-Bus methods that are available for you to call: http://maemo.org/api_refs/5.0/5.0-fi...-names_8h.html
 

The Following User Says Thank You to qwerty12 For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 03:45.