bentrix;652658 Wrote:
> In the SB_priority file you have to wait for SqueezePlay to start the
> jive_alsa process. The "sleep xx" does this fine but a better way to do
> it - especially if you should ever want to run SB_priority manually - is
> to use a while loop.
>
> Insert these lines at the top of the SB_priority file:
>
> # Wait for the SqueezePlay process to start the jive_alsa process:
> jalsa=`ps -C jive_alsa -o pid=`
> while [ $? != 0 ]
> do
> # The jive_alsa process has not yet been started:
> sleep 1
> jalsa=`ps -C jive_alsa -o pid=`
> done
>
>
> (The "$?" variable returns the exit code of the last executed
> command).
>
> This works very nicely for me.
>
> bentrix
I would suggest
Code:
--------------------
while ! pidof jive_alsa
do
sleep 1
done
--------------------
--
Pilru
------------------------------------------------------------------------
Pilru's Profile: http://forums.slimdevices.com/member.php?userid=40204
View this thread: http://forums.slimdevices.com/showthread.php?t=89359
_______________________________________________
audiophiles mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/audiophiles