Reply
Thread Tools
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#6771
Yeeeeeessssss ! Finally I got it !!!
Checking Call status without mcetool !
Code:
qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get | sed -n 4p | cut -d ':' -f2 | cut -d ' ' -f2
0 - Incomming call
1 - Dialing
3 - Call active (speaking)
4 - Hold call
5 - Call ended by other side
6 - Phone (call mode) not active



Here is a simple example how we can use it in script:
Code:
#!/bin/sh

Call=$(qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get | sed -n 4p | cut -d ':' -f2 | cut -d ' ' -f2)

if [[ $Call == "0" ]]; then
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
else
if [[ $Call == "1" ]]; then
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
else 
if [[ $Call == "3" ]]; then
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
else 
if [[ $Call == "4" ]]; then
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
  else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone NOT active !
You can do what you want...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
fi
fi
fi
fi
or vice versa:
Code:
#!/bin/sh

Call=$(qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get | sed -n 4p | cut -d ':' -f2 | cut -d ' ' -f2)

if [[ $Call == "6" ]]; then
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone NOT active !
You can do what you want...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
fi

And I think this is a final version of auto-back1.sh script:
Code:
#!/bin/sh

while true
do
Call=$(qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get | sed -n 4p | cut -d ':' -f2 | cut -d ' ' -f2)
GPS=$(qdbus com.nokia.positioningd.context /org/maemo/contextkit/Location/SatPositioningState org.maemo.contextkit.Property.Get | sed -n 1p)

   if [ $Call == "6" ]; then
     if [ ! -f /var/lib/aegis/dpkg-journal ]; then
        if [ $GPS == "off" ]; then
        bash /opt/N9QTweak/Autowall/auto-back2.sh >/dev/null
        else
        dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'GPS is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
        fi
        else
        dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone in installation process !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
     fi
     else
     dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
   fi
sleep 10800
done

Last edited by Schturman; 2013-06-06 at 23:54.
 

The Following 3 Users Say Thank You to Schturman For This Useful Post:
Ancelad's Avatar
Posts: 1,552 | Thanked: 3,108 times | Joined on Jun 2012 @ Russia, 96
#6772
OMG, I love my desktop <3
 
MK99's Avatar
Posts: 644 | Thanked: 480 times | Joined on Jul 2012 @ Finland
#6773
Originally Posted by Ancelad View Post
OMG, I love my desktop <3
What are those green numbers?
 
Ancelad's Avatar
Posts: 1,552 | Thanked: 3,108 times | Joined on Jun 2012 @ Russia, 96
#6774
Originally Posted by MK99 View Post
What are those green numbers?
It's my USSD balance
 

The Following User Says Thank You to Ancelad For This Useful Post:
Posts: 142 | Thanked: 72 times | Joined on Jan 2013
#6775
Originally Posted by Ancelad View Post
OMG, I love my desktop <3
I love it too!
 
Ancelad's Avatar
Posts: 1,552 | Thanked: 3,108 times | Joined on Jun 2012 @ Russia, 96
#6776
If you want transparent icon folder - download it, put it into MyDocs and go to your terminal

Code:
devel-su
password
cp -rf /home/user/MyDocs/icon-transparent.png /usr/share/themes/blanco/meegotouch/icons/icon-l-folder.png
/sbin/initctl restart xsession/mthome

Last edited by Ancelad; 2013-06-07 at 19:51.
 

The Following 2 Users Say Thank You to Ancelad For This Useful Post:
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#6777
I found something interesting...
If you run this command:
Code:
qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get
and get this output:
Code:
RM696-21-3_PR_001:~# qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get
displayName: Bob Marley
muted: false
startTime: 122880
state: 6
status: true
122906803168305
RM696-21-3_PR_001:~#
That mean your phone had used for call at least one time..
If you will run Full refresh or reboot and run this command again, you will get this output:
Code:
RM696-21-3_PR_001:~# qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get
status: false
121922979285263
RM696-21-3_PR_001:~#
That mean you still not used your phone for calls.
This is a reason that I changed this script to:
Code:
#!/bin/sh

while true
do
Call=$(qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get | sed -n 4p | cut -d ':' -f2 | cut -d ' ' -f2)
Call2=$(qdbus com.nokia.CallUi.Context /com/nokia/CallUi/ActiveCall org.maemo.contextkit.Property.Get | sed -n 1p | cut -d ':' -f1 | awk '{print $1}')
GPS=$(qdbus com.nokia.positioningd.context /org/maemo/contextkit/Location/SatPositioningState org.maemo.contextkit.Property.Get | sed -n 1p)

   if [ $Call == "6" ]; then
     if [ ! -f /var/lib/aegis/dpkg-journal ]; then
        if [ $GPS == "off" ]; then
        bash /opt/N9QTweak/Autowall/auto-back2.sh >/dev/null
        else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'GPS is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
        fi
        else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone in installation process !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
     fi
     else
   if [ $Call2 == "status" ]; then
     if [ ! -f /var/lib/aegis/dpkg-journal ]; then
        if [ $GPS == "off" ]; then
        bash /opt/N9QTweak/Autowall/auto-back2.sh >/dev/null
        else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'GPS is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
        fi
        else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone in installation process !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
     fi
     else
dbus-send --print-reply --dest=com.meego.core.MNotificationManager /notificationmanager com.meego.core.MNotificationManager.addNotification uint32:1000 uint32:0 string:'x-nokia.internet' string:'' string:'Phone is active now !
Waiting to another circle...' string:'' string:'/usr/share/icons/hicolor/64x64/apps/auto-back-on64.png' uint32:0 > /dev/null
    fi
   fi
sleep 21600
done
But it still not work from auto-background button, it work only if you run this script directly...
i will check it after repackage.. Will see...
 

The Following 2 Users Say Thank You to Schturman For This Useful Post:
Posts: 29 | Thanked: 0 times | Joined on Apr 2013
#6778
[QUOTE=Schturman;1350085]lacro, sorry.. I really don't know what the problem and why you can't install n9qt.. For now, as far as i know you only one with this problem..
You sure dev. mode and installation from other sources is activated ?


Thanks Schturman, I'm afraid yes, both dev mode and installation from other sources are activated.
 
Posts: 509 | Thanked: 626 times | Joined on Jul 2012 @ Mexico/Germany
#6779
Hy Schturmann,

i have the problem that removing billboard and meecast, i can change the color on LockScreen and LPS into blue (F-2 #0000FF).
Installing Billboard the color of the clock is back in white.
Some solutions?
 
MK99's Avatar
Posts: 644 | Thanked: 480 times | Joined on Jul 2012 @ Finland
#6780
[QUOTE=lacro;1350372]
Originally Posted by Schturman View Post
lacro, sorry.. I really don't know what the problem and why you can't install n9qt.. For now, as far as i know you only one with this problem..
You sure dev. mode and installation from other sources is activated ?


Thanks Schturman, I'm afraid yes, both dev mode and installation from other sources are activated.
What changes you made manually?
Run this as root and then install N9QTweak.
Code:
rm -fr /opt/N9QTweak
 

The Following 2 Users Say Thank You to MK99 For This Useful Post:
Reply

Tags
hebrew vkb, n9 qtweak, n9 quick tweak, n9 quicktweak, root-ssh

Thread Tools

 
Forum Jump


All times are GMT. The time now is 05:31.