Reply
Thread Tools
Posts: 21 | Thanked: 14 times | Joined on Feb 2011
#31
I had a reflash yesterday, and didn't installed Python yet. I now installed Python 2.5 but still nothing happens
 
Tiboric's Avatar
Posts: 433 | Thanked: 312 times | Joined on Nov 2009 @ U.K
#32
so what happens exactly when you click the icon?

It should:

1. launch xterm,
2. then it should say 'Desktop sms shortcut creator'
3. 'name:' than waits for your input
4. then say 'Enter phone number' then waits for your input
5. it will then close and you'll have a new shortcut in your app menu that you can also place on your desktop.

what happens too with your device?
 
Posts: 21 | Thanked: 14 times | Joined on Feb 2011
#33
It opens X-term
In X-term only displayed is: Password:
When tab enter X-term closed, when type letters X-term closed, when type numbers i got the message Sorry try again.

Is it possible i miss another application which is needed, as told i reflashed my N900, and i don't have a lot of applications installed
 
Tiboric's Avatar
Posts: 433 | Thanked: 312 times | Joined on Nov 2009 @ U.K
#34
can you do me a favour and type
'sudo python /opt/shortcutmkr/scm.py' into a new xterm window,

and then try 'sudo gainroot' enter
then 'python /opt/shortcutmkr/scm.py'
if that doesn't work

Edit: so is anyone else having trouble getting this running or is it just Kershaw?

Last edited by Tiboric; 2011-02-08 at 00:43.
 
Posts: 2,225 | Thanked: 3,822 times | Joined on Jun 2010 @ Florida
#35
If you have rootsh installed, your system may to ask you for a password when you run sudo [command]. Some N900s don't do this, some do - it depends on some system settings of other... I never bothered tracking it down, though it's a known issue. This is what explains the previous page's "text doesn't appear when I type password" issue - when you get password prompts in X-Term, it just doesn't show you typed anything. It DOES, however, register all your key presses, so just carefully type your password as normal. If you don't know your password, from X-Term, type:

Code:
sudo gainroot
passwd user [password you want to use when you use "sudo"]
Because of this, I recommend that you instead add your applications to the sudoers file (don't ask me how I don't know, I just know what doing so would do), and let it run commands that way. OR just have it "sudo gainroot" (only once have I read of that asking for a password on the N900) - and run all your other commands without "sudo".

I can't help on the Qt side of things though. I know a broad range of topics on this forum, only Python marginally well enough to code in it... sorta.
 
Tiboric's Avatar
Posts: 433 | Thanked: 312 times | Joined on Nov 2009 @ U.K
#36
I thought this was all sorted in the latest version of rootsh.. dam
guessed it was privileges but thought maybe rootsh just wasn't installed

Theres only a few commands to the whole script and it only needs rights so it can write the .desktop file, does anyone know how to gainroot half way through a script? as Mentalist Traceur has suggested? or should i play around with peoples suders file?
 
oKtosiTe's Avatar
Posts: 47 | Thanked: 14 times | Joined on Jul 2010
#37
Originally Posted by Swimm12984 View Post
is there a similar variation on this code for phonecalls, emails, etc? And how do you embed an icon for such a shortcut?
I'm also interested in a phone call version. Tried several variations, but since I'm totally unfamiliar with Python, I could not get it to word.
Nicolai, any hints?
 
Tiboric's Avatar
Posts: 433 | Thanked: 312 times | Joined on Nov 2009 @ U.K
#38
well try
[Desktop Entry]
Encoding=UTF-8
Version=0.1
Type=Application
Name=Dialpad
Exec=dbus-send --type=method_call --dest=com.nokia.CallUI /com/nokia/CallUI com.nokia.CallUI.ShowDialpad string:"999999999"
Icon=call_dialpad
where 999999999 is put your number
Thanks go to nicolai

Hope that works as I haven't had time to test I'm learning QT + python and doing work at the moment

Last edited by Tiboric; 2011-02-09 at 15:53.
 

The Following User Says Thank You to Tiboric For This Useful Post:
nicolai's Avatar
Posts: 1,637 | Thanked: 4,424 times | Joined on Apr 2009 @ Germany
#39
not well tested, but worth a try:
Code:
[Desktop Entry]
Encoding=UTF-8
Version=0.1
Type=Application
Name=phone short cut
Exec=python -c 'import dbus; print dbus.Bus().call_blocking("org.freedesktop.Telepathy.AccountManager","/org/freedesktop/Telepathy/Account/ring/tel/ring", "com.nokia.Account.Interface.ChannelRequests","Create","a{sv}ts", ({"org.freedesktop.Telepathy.Channel.TargetHandleType":dbus.UInt32(1),"org.freedesktop.Telepathy.Channel.TargetID":"000000000","org.freedesktop.Telepathy.Channel.ChannelType":"org.freedesktop.Telepathy.Channel.Type.StreamedMedia"},0,""))'
Icon=general_call
Replace 000000000 with the receivers phone number
 

The Following 3 Users Say Thank You to nicolai For This Useful Post:
Tiboric's Avatar
Posts: 433 | Thanked: 312 times | Joined on Nov 2009 @ U.K
#40
Thanks nicolai,

That'll be useful when I eventually finish all these tutorials and I can write a UI for Shortcutmaker.

P.S the Sms one you posted is really useful I'm using all the time for writing my txt's.
 

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


 
Forum Jump


All times are GMT. The time now is 00:51.