View Full Version : AlienStream tidbits

Niek Jongerius
2004-08-14, 05:36

I've been playing around with AlienStream getting some Dutch radio
stations to play on the SB. RealAudio streams were no problem, but I
had difficulties playing WMA streams. There were two issues:

- After doing some debugging it turned out AlienStream3.pm exec's the
alienstream helper giving it the playlist file as its first argument.
This seems one level of indirection off, since now alienstream tries
to open the filename as URL, instead of opening what's _inside_ the
file. I've changed the helper app to check the first char of the
argument. If it is a '/' it assumes we want to play a URL inside a
file, so it reads the first line from the file and treats that as the
URL. This seems to work OK now.

- After listening to one of my favourite shows I stopped AlienStream
(and it confirmed that in the log: "AlienStream: trying to kill player
... Done", same for encoder). When I returned to the SB a few hours
later, the display was black. Seemed the slimserver died. However,
the slimserver process was still there. I did a "strace" on the process,
and it blocked trying to open the mp3 pipe in /tmp. After feeding some
junk in the pipe ("echo hi > /tmp/AlienStream3-fjjQ/AlienStream3.mp3"),
the slimserver continued and the SB came back. Checked the playlist,
the SB "last played" file showed the pipe (content of the file:
"file:///tmp/AlienStream3-mk0e/AlienStream3.mp3"). Somehow slimserver
tried to start playing this list again, and it blocked.
A quick-and-dirty solution for me was to do an "unlink" of both pipes
in "sub kill_children". Worst that can happen now if slimserver tries
to continue reading the pipe it won't find the file, and maybe throw
an error, but will not block or crash. If I decide to play another
alien stream, the plugin will create new pipes anyway.

I'll test some more, but for now things seem stable. Great plugin, Peter!