Posts: 139
Joined: Jun 2009
Reputation:
0
I have set up several Squeezeplayers around the house and control them all via Ipeng. For who doesn't know: Squeezeplayers are software audio streaming players that work with the Logitech Squeezebox system. There is a server, wich you actually controll remotely, that sends audio-streams to your various clients. Great, now I have a bunch of synced audio clients around my house and control them all from an ipod in my pocket (that's the Ipeng part).
In my living room there naturely is an xbmc. Since it is connected to a beamer, I really don't want to turn that one on for browsing music. There is a simple daemon - squeezeslave - that plays the audio just fine and in sync with the other squeezeplayers. If I put squeezeslave in my rc.local it comes up fine and I can hear music and don't need any monitor.
If now I want to watch a movie, I get an audio device error, since the daemon blocks the audio interface no mater if music is playing or not. What I am looking for is a way to gently end squeezeslave when I start a movie and to restart it after having stopped the movie (or better after a certain time, I might want to see another one.).
Does anyone have an idea how I could achieve this? Using a different audio output is no option, because I want to use HDMI for audio as well.
Posts: 1,399
Joined: Aug 2009
Reputation:
23
There is caffeine but it is specific to screensavers/power saving daemons. Dunno about your situation.
Posts: 139
Joined: Jun 2009
Reputation:
0
If I only knew more about the internals of xbmc... I just got it to change refresh rates according to the content, so that is actually the right moment... Used a guide and a script to set it up, though..
Posts: 2,710
Joined: Feb 2009
Reputation:
12
ppic
Skilled Python Coder
Posts: 2,710
you'll need to alter the skin xml to launch a script that will send stop command to syour squeeze program then launch the movie.
Posts: 2,710
Joined: Feb 2009
Reputation:
12
ppic
Skilled Python Coder
Posts: 2,710
no skins are made of more than one xml !
if you don't know this kind of things, you'd better learn how a skin work before trying to do this modification, also you'll need to write the python code to do the behave you want.
Posts: 139
Joined: Jun 2009
Reputation:
0
I don't understand: I find three skins: CDArts, Subtitles and Lyrics. These look like sub-parts of something. Where is the default skin, like the entire xbmc GUI?
Anyway, I am very bad with coding, so learning to write a python script will not work.
I was hoping for a very simple solution. sqeezeslave itself is ver simple to launch: /usr/local/bin/squeezeslave -M -o2 atom
That's it already. -M daemonizes, -02 chooses the hdmi audio aoutput and atom is the host running the squeezebox server.
Hmm, what now?
Posts: 80
Joined: Oct 2007
Reputation:
1
I wonder if altering your command line to use padsp might work:
/usr/bin/padsp /usr/local/bin/squeezeslave -M -o2 atom
Using pulseaudio might fix the blocking problem. Just a thought, I have no way to test this.
Posts: 139
Joined: Jun 2009
Reputation:
0
Too bad, when installing, I disabled pulseaudio somewhere globally. I think to remember there was an issue with it not working in the ubuntu 10.10 release. I'd rather stick with my alsa setup. It tookk quite a while to make it work flawlessly. Also I wonder, what would happen if a playing pcm-stream would meet a ac3-passthrough, surely something nasty.. Also there is mostly music playing in the kitchen and bathroom, while someone wants to watch a movie, so it's necesary to disable squeezeplay before launching a movie.
Posts: 2,710
Joined: Feb 2009
Reputation:
12
ppic
Skilled Python Coder
Posts: 2,710
just take a lot at your skin directory, there's plenty of xml, not just skin.xml, all these xml are for the skin.
Posts: 139
Joined: Jun 2009
Reputation:
0
Whoo, thx for trying to encourage me, but I have been down that road before with C, the shell and python, too. It's just not for me, all the way to cryptic. I used to write shell scripts by myself but it always took ages to debug all the little typos and such.. I am not afraid to edit things, if I know what to do, but challenging the xbmc skin blindly won't do any good..
Posts: 139
Joined: Jun 2009
Reputation:
0
So... for now I solved it with lirc and irexec, so the player starts up with xbmc and I have to press a ertain btton on my remote to turn it off or on again. Not very nice but working..