One trick to try is to start up a version of utaudio with $DISPLAY
set in its environment to correspond to the current session which
is attached to the target Sun Ray. Don't worry about Xsecurity
(i.e. xhosts), this doesn't actually open the display but it does
use the display number to identify the Sun Ray.
Attached is a little script I wrote to do this, no warranty attached
or implied :-).
You must be root and run it as 'remote_audio <mac_address> <cmd>
[<cmd_args> ...]'.
It's possible this will work as non-root if you manage the Xsecurity
properly, I never tried that.
Play nice :-)
-Bob
Andreas Höschler wrote:
Hello all,
I would like to write a program running on the Sun Ray Server that
opens a device (the line-out of a given Sun Ray) and pushes audio data
to this device. This does not seem to be a problem after a session has
been created by the Sun Ray. We already learned that a corresponding
device is created in /tmp/SUNWut/dev/utaudio when a user logs in and
that audio data can be pushed with something like
cat Test.wav > $AUDIODEV
However, our Sun Ray is supposed to run headless (no monitor, no
keyboard). We will misuse it as a ethernet to line-out adaptor (any
cheaper solution for this?). How can we manually create the device by
just knowing the MAC address of the Sun Ray without the need of
plugging in a keyboard and logging in after each reboot of the server?
Thanks a lot!
Regards,
Andreas
_______________________________________________
SunRay-Users mailing list
[email protected]
http://www.filibeto.org/mailman/listinfo/sunray-users
#!/bin/ksh
cleanup() {
pkill -f "Remote to $DISP from $DISPLAY"
}
trap cleanup 0
DISP="`/opt/SUNWut/bin/utwho -ac | sed -n /$1/'s/ *\([^\.]*\).*/\1/p'`"
shift
env AUDIODEV=`env DISPLAY=:$DISP /opt/SUNWut/bin/utaudio Remote to $DISP from
$DISPLAY` $*
exit 0
_______________________________________________
SunRay-Users mailing list
[email protected]
http://www.filibeto.org/mailman/listinfo/sunray-users