Fedora Linux Support Community & Resources Center
  #1  
Old 31st July 2005, 12:07 AM
blinksilver Offline
Registered User
 
Join Date: Jan 2005
Posts: 86
acpi event

i have this little script that sets the brightness of my screen deepending on if my laptop is plugged in or not, but sadly, it does not work, I have no idea why.

the file is /etc/acpi/events/smartdimmer.sh
i chmod +x smartdimmer.sh as root

and this is the file itself, i don't kno w why it is not working.

#! /bin/sh

ACSTATE=`cat /proc/acpi/ac_adapter/ACAD/state | cut-d: -f2 | sed -e 's/^ *//g'`

if [ $ACSTATE == "on-line" ]; then
smartdimmer -s 21

elif [ $ACSTATE == "off-line" ]; then
smartdimmer -s 2
fi
Reply With Quote
  #2  
Old 31st July 2005, 10:26 PM
Jman Offline
Registered User
 
Join Date: Mar 2004
Location: Minnesota, USA
Age: 27
Posts: 7,909
On my machine I don't have a cut-d: command.

What errors are you getting?
Reply With Quote
  #3  
Old 1st August 2005, 03:32 AM
blinksilver Offline
Registered User
 
Join Date: Jan 2005
Posts: 86
http://www.hmug.org/man/1/cut.php

here's a link to the man file, does fedora not have a cut command?
Reply With Quote
Reply

Tags
acpi, event

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
acpi must be off during installation and using Fedora 11, why and how to enable acpi? ngonchan Hardware & Laptops 4 31st March 2010 08:49 AM
acpi=off, kernel failure/acpi on, udev timeout vandervecken Hardware & Laptops 0 4th December 2008 07:57 AM
log out on lid event? duni Hardware & Laptops 3 16th January 2007 11:05 PM
get up/dwn arrow key event ptlchetan Programming & Packaging 0 5th September 2006 08:04 AM


Current GMT-time: 08:02 (Friday, 24-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat