You are not logged in.
Hi all, if i use backlight and volume keys of my laptop, strange characters appears in text tty when i use those acpi buttons.
For example, when touch the backglight controls, "^@" is written into the terminal, when i lower the volume it prints "[[26^"
acpid configuration:
$ cat /etc/acpi/events/anything
# Pass all events to our one handler script
event=.*
action=/etc/acpi/handler.sh %e
$ cat /etc/acpi/handler.sh
#!/bin/bash
# Default acpi script that takes an entry for all actions
case "$1" in
button/power)
case "$2" in
PBTN|PWRF)
logger 'PowerButton pressed'
;;
*)
logger "ACPI action undefined: $2"
;;
esac
;;
button/sleep)
case "$2" in
SLPB|SBTN)
logger 'SleepButton pressed'
;;
*)
logger "ACPI action undefined: $2"
;;
esac
;;
video/brightnessup)
bl_dev=/sys/class/backlight/intel_backlight
step=100
echo $(($(< $bl_dev/brightness) + $step)) >$bl_dev/brightness
;;
video/brightnessdown)
bl_dev=/sys/class/backlight/intel_backlight
bnow=$(<$bl_dev/brightness)
maxstep=2 #due vuol dire dimessa la luminosità attuale
step=$(($bnow/$maxstep))
echo $(( bnow - $step )) >$bl_dev/brightness
;;
ac_adapter)
case "$2" in
AC|ACAD|ADP0)
case "$4" in
00000000)
logger 'AC unpluged'
;;
00000001)
logger 'AC pluged'
;;
esac
;;
*)
logger "ACPI action undefined: $2"
;;
esac
;;
battery)
case "$2" in
BAT0)
case "$4" in
00000000)
logger 'Battery online'
;;
00000001)
logger 'Battery offline'
;;
esac
;;
CPU0)
;;
*) logger "ACPI action undefined: $2" ;;
esac
;;
button/lid)
case "$3" in
close)
logger 'LID closed'
;;
open)
logger 'LID opened'
;;
*)
logger "ACPI action undefined: $3"
;;
esac
;;
*)
logger "ACPI group/action undefined: $1 / $2"
;;
esac
# vim:set ts=4 sw=4 ft=sh et:
my kernel commandline
$ cat /proc/cmdline
BOOT_IMAGE=../vmlinuz-linux root=/dev/sda5 acpi_backlight=vendor threadirqs quiet i915.semaphores=1 i915.i915_enable_rc6=7 i915.i915_enable_fbc=1 i915.lvds_downclock=1 drm.vblankoffdelay=1 pcie_aspm=force resume=/dev/sda2 rw initrd=../initramfs-linux.img
ideas? thanks!
EDIT: it has nothing to do with acpid, happens even if the daemon is stopped
and some characters appears only if i'm not logged in to tty...
Last edited by kokoko3k (2014-05-30 13:54:55)
Help me to improve ssh-rdp !
Retroarch User? Try my koko-aio shader !
Offline