diff options
author | lcapriotti <lcapriotti@svn> | 2010-01-19 16:07:49 +0000 |
---|---|---|
committer | lcapriotti <lcapriotti@svn> | 2010-01-19 16:07:49 +0000 |
commit | 2a84ac5802c77596338171e695fdeea856c14d76 (patch) | |
tree | 7988021d2da43910086513c121ccd7db14d2ff86 /tools | |
parent | 50a3f381cebc9ebd5f43456c9a51cfdf7a305af8 (diff) |
simpler version, tks AlTheKiller
git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/trunk@27014 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/XBMCLive/SDK/buildLive/Files/chroot_local-includes/etc/pm/sleep.d/99lirc-resume | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/tools/XBMCLive/SDK/buildLive/Files/chroot_local-includes/etc/pm/sleep.d/99lirc-resume b/tools/XBMCLive/SDK/buildLive/Files/chroot_local-includes/etc/pm/sleep.d/99lirc-resume index 66a641e3a9..b40861ed87 100755 --- a/tools/XBMCLive/SDK/buildLive/Files/chroot_local-includes/etc/pm/sleep.d/99lirc-resume +++ b/tools/XBMCLive/SDK/buildLive/Files/chroot_local-includes/etc/pm/sleep.d/99lirc-resume @@ -1,17 +1,19 @@ -#!/bin/sh +#!/bin/bash -# This script will restart lirc drivers, Lirc, and XBMC's lirc interpreter upon resume. +# This script will restart Lirc upon resume. + +. /usr/lib/pm-utils/functions + +case "$1" in + hibernate|suspend) + /etc/init.d/lirc stop + ;; + thaw|resume) + /etc/init.d/lirc start + ;; + *) + ;; -case "$1" in - resume) - lircDriver=$(dmesg | grep usbcore | grep -i 'lirc' | sed -e "s/.* \(lirc*\)/\1/" | head -n 1) - curl "http://127.0.0.1:8080/xbmcCmds /xbmcHttp?command=ExecBuilt&Inparameter=LIRC.Stop" - /etc/init.d/lirc stop - rmmod $lircDriver - modprobe $lircDriver - /etc/init.d/lirc start - #remove the comment if the computer automatically sleeps after resume - #irw & sleep 1; killall irw - curl "http://127.0.0.1:8080/xbmcCmds/xbmcHttp?command=ExecBuiltIn¶meter=LIRC.Start" - ;; esac + +exit $?
\ No newline at end of file |