Notices


Reply
Thread Tools
somebody's Avatar
Posts: 128 | Thanked: 487 times | Joined on Oct 2010 @ Novosibirsk, Russia
#461
Originally Posted by kl2010 View Post
thanks alot. trying it now.

i guess this will start someplayer and automatically play whatever someplayer was playing as at the last time(the playlist in this case)?
To start and play use:
Code:
someplayer && sleep 20 && dbus-send --type=method_call --dest=ru.somebody.someplayer / ru.somebody.someplayer.toggle
This command runs someplayer, waits for 20 seconds and starts playing last played song or first song in playlist.
__________________
Donate for SomePlayer
 
kl2010's Avatar
Posts: 35 | Thanked: 2 times | Joined on Jul 2010 @ lagos, Nigeria
#462
Originally Posted by kl2010 View Post
thanks alot. trying it now.

i guess this will start someplayer and automatically play whatever someplayer was playing as at the last time(the playlist in this case)?
someplayer starts uite all right, but it does not play any file, and does not even show my playlist.
the x-terminal show --segmentation fault.
__________________
C. Shirky: Everybody has something strange they are trying to accomplish.
 
somebody's Avatar
Posts: 128 | Thanked: 487 times | Joined on Oct 2010 @ Novosibirsk, Russia
#463
Oh, yes, I'm still sleepy
Create a script file (e.g. start_someplayer.sh) in /home/user directory:

Code:
#!/bin/sh
someplayer &
sleep 20 
dbus-send --type=method_call --dest=ru.somebody.someplayer / ru.somebody.someplayer.toggle
then add permissions to execute:
Code:
$ chmod +x /home/user/start_someplayer.sh
then add this command to alarmd (or try to invoke this in terminal):
Code:
/home/user/start_someplayer.sh
__________________
Donate for SomePlayer
 
kl2010's Avatar
Posts: 35 | Thanked: 2 times | Joined on Jul 2010 @ lagos, Nigeria
#464
Originally Posted by somebody View Post
Oh, yes, I'm still sleepy
Create a script file (e.g. start_someplayer.sh) in /home/user directory:

Code:
#!/bin/sh
someplayer &
sleep 20 
dbus-send --type=method_call --dest=ru.somebody.someplayer / ru.somebody.someplayer.toggle
then add permissions to execute:
Code:
$ chmod +x /home/user/start_someplayer.sh
then add this command to alarmd (or try to invoke this in terminal):
Code:
/home/user/start_someplayer.sh
thanks alot! will guve feedback soonest. hnmm sorry for keeping u up with this.
__________________
C. Shirky: Everybody has something strange they are trying to accomplish.
 
kl2010's Avatar
Posts: 35 | Thanked: 2 times | Joined on Jul 2010 @ lagos, Nigeria
#465
1. maybe am the one not doing something right! it now show playlist, but does not automatically play them.

2. i will like it to be able to automatically play so that i don"t need to press the play button manually. this code (mplayer -playlist mylist.txtworks) for mplayer. i guess this is because mplayer is a command line player.

3. thanks alot for your help.

what i really want to accomplish is fairly simple: i drive to work about 8am each day so as soon as i enter the car (8am) i put on the fm radio in the car and i want the my n900 to start playing a specified song or audiobook (in a playlist).

i know the code for the fm transmitter on the n900.

i want to use alarmed to schedule it such that it everything ends/stops after about 45 mins- which is about the time i take to commute to work.
__________________
C. Shirky: Everybody has something strange they are trying to accomplish.
 
kl2010's Avatar
Posts: 35 | Thanked: 2 times | Joined on Jul 2010 @ lagos, Nigeria
#466
somebody, thanks alot. everything now work fine. it is now automatically playing the files. i reduce the sleep time considerably to 4, hope thats ok?
i forgot to ask, what is the command line to stop it? grrrhhhhhhhh

is it ok to use killall someplayer? i intend to use this as a script following ur earlier steps, and then input it into someplayer.

thanks. so very much.
__________________
C. Shirky: Everybody has something strange they are trying to accomplish.
 
Posts: 669 | Thanked: 433 times | Joined on May 2010
#467
Originally Posted by somebody View Post
Oh, yes, I'm still sleepy
Create a script file (e.g. start_someplayer.sh) in /home/user directory:

Code:
#!/bin/sh
someplayer &
sleep 20 
dbus-send --type=method_call --dest=ru.somebody.someplayer / ru.somebody.someplayer.toggle
then add permissions to execute:
Code:
$ chmod +x /home/user/start_someplayer.sh
then add this command to alarmd (or try to invoke this in terminal):
Code:
/home/user/start_someplayer.sh
I tried creating the sh script but when i execute it it launches someplayer with an empty playlist - why is that? when it is executed from the hildon desktop shortcut it works fine...
 
somebody's Avatar
Posts: 128 | Thanked: 487 times | Joined on Oct 2010 @ Novosibirsk, Russia
#468
Originally Posted by impeham View Post
I tried creating the sh script but when i execute it it launches someplayer with an empty playlist - why is that? when it is executed from the hildon desktop shortcut it works fine...
different user.
If you start someplayer via shortcut - user is 'user', but (looks like) alarmd starts as root. Try to add sudo -u user before:
Code:
sudo -u user someplayer
__________________
Donate for SomePlayer
 
somebody's Avatar
Posts: 128 | Thanked: 487 times | Joined on Oct 2010 @ Novosibirsk, Russia
#469
Originally Posted by kl2010 View Post
i forgot to ask, what is the command line to stop it? grrrhhhhhhhh
the same command:
Code:
dbus-send --type=method_call --dest=ru.somebody.someplayer / ru.somebody.someplayer.toggle
or
Code:
dbus-send --type=method_call --dest=ru.somebody.someplayer / ru.somebody.someplayer.stop
__________________
Donate for SomePlayer
 
dr_frost_dk's Avatar
Posts: 1,503 | Thanked: 2,688 times | Joined on Oct 2010 @ Denmark
#470
bumping again....

I have noticed a bug.

when browsing the list of mp3's, i notice that some files are just displayed as the first letter of the file.

this is only for files where "." is the second letter of the file
Example:
"R.E.M. - Drive" is displayed as "R"
"M.M.A.I. - Pete Yorn - Strange Condition" is displayed as "M"
NOTE: M.M.A.I = Me Myself and Irene

Also i do not have any ID3 Tags (really hate ID3 tags, yes im weird i know...)
 
Reply

Tags
music player, nokia n900, someplayer


 
Forum Jump


All times are GMT. The time now is 12:15.