Execute a PyQt app from an acpi event in linux
Posted
by alfredozn
on Stack Overflow
See other posts from Stack Overflow
or by alfredozn
Published on 2010-06-11T22:35:52Z
Indexed on
2010/06/11
22:43 UTC
Read the original article
Hit count: 318
Hi,
I want to use a PyQt application to display an image when some acpi event is triggered under linux.
I already setting up the configuration for the event and the python scrip is executed when the event is triggered, but when program reach the creation of the QApplication
app = QApplication(sys.argv)
it stops without error. I tried setting up the same DISPLAY and PATH environment variables as my current user but it doesn't work.
This is my event file:
event=sony/hotkey SNC 00000001 00000011
action=/etc/acpi/vaio-tools/brightness/sonybright.sh up 2>&1>/tmp/vaio-tools_brightness.log
I tried to find some error in the /tmp/vaio-tools_brightness.log but it doesn't log anything after it reach the QApp creation in code.
any hints??
© Stack Overflow or respective owner