Results 1 to 2 of 2

Thread: pm-utils config help for my openSUSE 11.4 (gnome) Mythtvbox

  1. #1

    Wink pm-utils config help for my openSUSE 11.4 (gnome) Mythtvbox

    Hi

    Hope this is a quick one, i need to do two things now to finally get my media center waking up to record and shutting down (never got so far, im so close).

    i can write a time in to the future to the /sys/class/rtc/rtc0/wakealarm, then hibernate (acpi-S4) and it will wake up as long as the bios RTC, and Hpet is disabled.


    so only issue right now that
    1) my ralink wifi card driver is dead on resume - just a simple rmmod and modprobe brings back the wlan0 interface and all is connected up fine again. - how can i script it? i looked at duplicating a 'hook' file to do just this looking at the pm-utils docs but and i coped it from a file that was already there, (/etc/pm/sleep.d/99at), but that crashes when the hibernate starts.

    2) i need to finish my config, which would be for a normal user to run a script i have created to set the rtc time called /usr/bin/wakeup.sh, and being able to run the /usr/sbin/pm-hibernate, so they can then S4 the system ready for the next wakeup. can anyone please bang out a sudoers line to add to the file as i am seriously **** at them!

    cheers

  2. #2

    Default Re: pm-utils config help for my openSUSE 11.4 (gnome) Mythtvbox

    ok, so i've sorted how to unload and reload by wifi driver using a hook script. dunno were i went wrong before but essentially if you need to do this, I Put a new file in at /etc/pm/sleep.d/ directory called 66reload (maybe it was a number clash as the last file started with 99), made it an executable and then this is all it is:-

    Code:
    #!/bin/bash
    case $1 in
        hibernate)
            /sbin/rmmod rt2870sta
            ;;
        suspend)
            /sbin/rmmod rt2870sta
            ;;
        thaw)
            modprobe rt2870sta
            ;;
        resume)
            modprobe rt2870sta
            ;;
    esac
    obviously, sub the rt2870 module with whatever you need to do. nice and easy!

    still having issues with sudo still

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •