My ongoing experiences with Ubuntu, and later Mythbuntu, as a media center with MythTV. I'm also using the system for a virtual machine server, a mediawiki server and a general all around home infrastructure base.

Showing posts with label dpms. Show all posts
Showing posts with label dpms. Show all posts

Saturday, October 25, 2008

Turning off screen saving (one more time)...

I've been wrangling with the screensaver and DPMS on my Mythbuntu box (see here and here).

At this point I've got DPMS off but still have one nagging issue - some screensaver is kicking on and I have to press a button on the remote to get it to turn off. Better than having to hit a key on the keyboard, but still not what I want - I just want to turn on the monitor and see my MythTV dammit.

First, I figured out that I could disable DPMS with the ~/.xsessionrc file, e.g:
$ cat ~/.xsessionrc
xset s noblank
xset s off
xset -dpms

Now, that should turn off the X screensaver too, but seems like something is still running. Ah, poking around I find I have gnome-screensaver running:
$ ps auxwww | grep gnome-screensaver
user 6086 0.0 0.1 15420 4908 ? Ss Oct19 0:32 gnome-screensaver

Poking around the net, I came across this thread, and I followed the directions to kill the gnome-screensaver:
$ killall gnome-screensaver
$ ps auxwww | grep gnome-screensaver
user 32499 0.0 0.0 3004 764 pts/1 R+ 08:34 0:00 grep gnome-screensaver

After that I played around a little and that did the trick - no more screensaver kicking on! So, following the directions a little further down in the thread I turned it off permanently:
$ gconftool-2 --type boolean -s /apps/gnome_settings_daemon/screensaver/start_screensaver false

So at this point I think I finally have all the screensavers, DPMS, etc. turned off on my MythBuntu box using the directions above.

Update 11/3/2008: Well, the gconftool-2 command above didn't persist through a reboot. So following these directions, I did the following (will update when I've confirmed if it worked or didn't):

gconftool-2 --type bool --set /apps/gnome-screensaver/idle_activation_enabled false

Update 1/10/2009: Well, the above didn't work. Next I tried directions in this post. First, I ran "gconf-editor" from a command-line. Then I selected "Apps" and "gnome-screensaver". Under the options for "gnome-screensaver" I deselected the option for "idle_activation_enabled".

After that, I rebooted and re-ran gconf-editor to make sure the "idle-activation_enabled" variable was still de-selected and it was. I've been watching my mythtv system idle now for over an hour and no screensaver. Success finally.

Wednesday, September 24, 2008

MythBuntu MythTV Tweaks

After getting MythBuntu installed, I did the following tweaks to MythTV:
  • Disabling DPMS (screen power saver): Previously I did it with the session manager, but Mythbuntu doesn't have the equivalent. So based on this thread, I did the following:
    $ vi ~/.xsessionrc
    $ cat ~/.xsessionrc
    xset s noblank
    xset s off
    xset -dpms
    Now restart desktop so changes take effect
    $ sudo /etc/init.d/gdm restart
    Updated Oct 24, 2008: I later also disabled the gnome-screensaver
  • I was still getting commercials during playback of recorded shows. Poking around it seemed like all the options for commercial remove were select, but then I found under Utilities/Setup -> Setup -> TV Settings -> Playback on screen 8 "Automatically Skip Commercials" which I set to "Automatically Skip"
  • I wanted my familiar Blootube theme back. I found this under Utilities/Setup -> Setup -> Appearance on screen 1.
  • I wanted channel changing during live TV to take effect immediately. This was done with a combination of two options: Utilities/Setup -> Setup -> TV Settings -> General screen 1, select "Change channels immediately without select", and Utilities/Setup -> Setup -> TV Settings -> Playback OSD screen 1, unselect "Always use Browse Mode"
  • Under Utilities/Setup -> Setup -> TV Settings -> Playback, screen 2, I set "Action on playback exit" to "Save Position and exit" and "Prompt at end of Recording".
  • Configured MythFillDatbase to run automatically. Utilities/Setup -> Setup -> TV Settings -> General screen 6, enable "Automatically run mythfilldatabase". For "Arguments" I used "--refresh-all --quiet" and for "Log Path" I used "/tmp/mythfilldatabase.log". Everything else I left as is.
  • Next I wanted to get the extra buttons on my remote working. So under Utilities/Setup -> Edit Keys I bound keys to the various screens I wanted shortcuts to under "JumpPoints". (Hint: to jump to the "Watch Recordings" screen, use the "TV Recording Playback" action as the target.)

    A hint, run "irw" as root and press keys on your remote to figure out their names, e.g. the following shows me pressing the Blue and Go keys:
    # irw
    00000000000017a9 00 Blue Hauppauge_350
    00000000000017a9 01 Blue Hauppauge_350
    00000000000017a9 02 Blue Hauppauge_350
    00000000000017bb 00 Go Hauppauge_350
    00000000000017bb 01 Go Hauppauge_350
    00000000000017bb 02 Go Hauppauge_350


    The I edited ~/.lirc/mythtv and bound the remote commands to those keys (the "config" option).
    $ cd ~/.lirc
    $ cp mythtv mythtv.orig
    $ vi mythtv
    $ diff -c mythtv.orig mythtv
    *** mythtv.orig 2008-09-24 21:05:35.000000000 -0500
    --- mythtv 2008-09-24 21:39:34.000000000 -0500
    ***************
    *** 733,738 ****
    --- 733,774 ----
    begin
    remote = Hauppauge_350
    prog = mythtv
    + button = Blue
    + config = d
    + repeat = 0
    + delay = 0
    + end
    +
    + begin
    + remote = Hauppauge_350
    + prog = mythtv
    + button = Videos
    + config = r
    + repeat = 0
    + delay = 0
    + end
    +
    + begin
    + remote = Hauppauge_350
    + prog = mythtv
    + button = TV
    + config = l
    + repeat = 0
    + delay = 0
    + end
    +
    + begin
    + remote = Hauppauge_350
    + prog = mythtv
    + button = RED
    + config = m
    + repeat = 0
    + delay = 0
    + end
    +
    + begin
    + remote = Hauppauge_350
    + prog = mythtv
    button = 7
    config = 7
    repeat = 0

    Next I tried restarting lirc:

    sudo /etc/init.d/lirc restart

    But that just caused my remote to stop working with mythtv all together, so I rebooted and all worked fine.


Wow, if it is possible for something to have too many options, MythTV is guilty...

Monday, August 25, 2008

Disabling Monitor Power Saver

Update October 25, 2008: I've made improvements on what I describe in this post - please see this later post.

So after upgraded to Hardy Heron I'm having an annoying problem that the system keeps putting the monitor into power save mode after a couple hours. This is a problem because I turn on the monitor with my remote but I still have to go hit a key on the keyboard to then use MythTV. Not ideal. It's definitely power saving (as opposed to a screen saver) since the monitor goes into a power-off mode with the power LED blinking.

First thing I did was check System/Preferences/Power Management. But both "Put computer to sleep when inactive for:" and "Put display to sleep when inactive for:" were set to Never.

So, I tried the directions here for installing bum. A couple of notes:
  • After installing the Bootup Manager, you'll find it under System Administration
  • The Gnome-Power-Manager is just called Power Manager.

Then I rebooted and still no luck, after a couple of hours the monitor is asleep again.

Poking around on the web, I found this useful page on screen blanking under X. I verified that I can reproduce the screen blanking I'm experiencing with the following command:

% sleep 1; xset dpms force off


So, I poked a little deeper at my settings. I believe the "0" values indicate that X shouldn't be turning the monitor off:

% xset q
...
DPMS (Energy Star):
Standyby: 0 Suspend: 0 Off: 0
DPMS is Enabled
Monitor is On
...


But I pushed ahead and next I tried turning off dpms:

% xset -dpms


That seemed to do the trick! Several hours have passed and the screen is still awake.

Ok, now how do I make it permanent. I launched System/Preferences/Sessions. Then I clicked on "Add". For Name I put "Disable DPMS", for Command "xset -dpms" and left Comment blank. Clicked on OK and then Close and then I rebooted the system (I probably could have just logged out and back in, but I like to make sure things work from a boot).

And that seems to have worked, at least 'xset q' now shows DPMS as disabled. Hopefully that ends this tale.