View Full Version : Lock Tablet via DBus
jgallen23
03-27-2008, 11:12 AM
anybody know what method to call to programatically lock the tablet?
Benson
03-28-2008, 11:03 AM
Well, if you have powerlaunch installed... you can use powertool. If you're using Nokia's mce, well, I can't say, I'm not even certain that it's possible (though it seems very likely).
cdmackay
03-29-2008, 08:41 AM
the systemui file makes it look tantalisingly possible, but not quite :)
qwerty12
04-13-2008, 07:03 AM
dbus-send --system --type=method_call --print-reply --dest='com.nokia.mce' /com/nokia/mce/request com.nokia.mce.request.req_locktouchscreen
Maybe that will work. I haven't tested it though.
jgallen23
04-14-2008, 11:38 AM
Error org.freedesktop.DBus.Error.UnknownMethod: Method "req_locktouchscreen" with signature "" on interface "com.nokia.mce.request" doesn't exist
jgallen23
04-14-2008, 11:41 AM
using dbus watcher, here's the output I get when locking the device:
signal sender=:1.3 -> dest=(null destination) path=/com/nokia/mce/signal; interface=com.nokia.mce.signal; member=tklock_mode_ind
string "unlocked"
signal sender=:1.0 -> dest=(null destination) path=/org/freedesktop/Hal/devices/platform_kb_lock; interface=org.freedesktop.Hal.Device; member=PropertyModified
int32 1
array [
struct {
string "button.state.value"
boolean false
boolean false
}
]
signal sender=:1.3 -> dest=(null destination) path=/com/nokia/mce/signal; interface=com.nokia.mce.signal; member=display_status_ind
string "on"
signal sender=:1.0 -> dest=(null destination) path=/org/freedesktop/Hal/devices/platform_kb_lock; interface=org.freedesktop.Hal.Device; member=Condition
string "ButtonPressed"
string "cover"
signal sender=:1.0 -> dest=(null destination) path=/org/freedesktop/Hal/devices/platform_kb_lock; interface=org.freedesktop.Hal.Device; member=PropertyModified
int32 1
array [
struct {
string "button.state.value"
boolean false
boolean false
}
]
so I tried to send something like this:
dbus-send --system --type=method_call --dest='org.freedesktop.Hal' --print-reply /org/freedesktop/Hal/devices/platform_kb_lock org.freedesktop.Hal.Device.Condition string:'ButtonPressed' string:'cover'
but I got back
Error org.freedesktop.DBus.Error.UnknownMethod: Method "Condition" with signature "ss" on interface "org.freedesktop.Hal.Device" doesn't exist
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.