[prev in list] [next in list] [prev in thread] [next in thread]
List: mythtv-users
Subject: Re: [mythtv-users] MythTV and the "average" user...
From: Yeechang Lee <ylee () pobox ! com>
Date: 2008-05-20 19:57:58
Message-ID: 18483.11590.302266.526391 () dobiegillis ! ylee ! org
[Download RAW message or body]
jedi <jedi@mishnet.org> says:
> Mapping one of the remote buttons as a kill switch works very well.
> If any sort of frontend shenanigan is going on you just hit the kill
> switch and "reboot" the thing in a sort of Windows-esque fashion.
Here's what I do. (The following updates
<URL:http://www.gossamer-threads.com/lists/mythtv/users/235105#235105>.)
From .lircrc:
begin
prog = irexec
remote = mx600_cable_043
button = On
repeat = 0
delay = 10
config = /usr/bin/xscreensaver-command -deactivate; echo 'Press
button again within three seconds to restart MythTV' |
/usr/local/bin/putfifo /tmp/onscreen && ~/bin/mythpowerbutton &
end
The kill button only functions if it is pushed twice within three
seconds; otherwise it simply displays a message on the screen through
putfifo (a little utility I found for this purpose since I didn't like
mythtvosd's output) and, incidentally, also turns off the screensaver
if running. The contents of my mythpowerbutton script:
#!/bin/bash
PROG=mythfrontend
STATUS=`ps -e | grep $PROG | grep -v grep | wc -l | awk '{print $1}'`
if [ `echo $DISPLAY | grep -c ":0"` -ge 1 ]
then
if [ $STATUS -eq 0 ]
then
( $PROG & )
else
# play /usr/share/sounds/gtk-events/toggled.wav
if [ -a /tmp/mythpowerbutton-off ]
then
touch /tmp/mythpowerbutton-on;
exit;
else
touch /tmp/mythpowerbutton-off;
sleep 3;
if [ -a /tmp/mythpowerbutton-on ]
then
play /usr/share/sounds/gtk-events/activate.wav
rm -rf /tmp/mythpowerbutton-o* && killall $PROG
fi
rm -rf /tmp/mythpowerbutton-o*
fi
rm -rf /tmp/mythpowerbutton-o*
fi
fi
exit 0
--
Frontend: P4 3.0GHz, 1.5TB software RAID 5 array
Backend: Quad-core Xeon 1.6GHz, 6.6TB sw RAID 6
Video inputs: Four high-definition over FireWire/OTA
Accessories: 47" 1080p LCD, 5.1 digital, and MX-600
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic