View Single Post
  #1   (View Single Post)  
Old 6th August 2008
pax's Avatar
pax pax is offline
FreeBSD baby
 
Join Date: Jul 2008
Location: Serbia, Belgrade/Pozarevac
Posts: 9
Default Problem with lid switch Inspiron 1300 sysctl: unknown oid 'hw.acpi.video.lcd0.active'

As you can see from topic title, I have problem to set up my laptop (Dell Inspiron 1300) lid switch so system can turn off and on my monitor as I close and open lid... I added event to /etc/devd.conf:


Code:
notify 10 {
match "system" "ACPI";
match "subsystem" "Lid";
action "/etc/rc.lid $notify";
};
and created rc.lid file:

Code:
#!/bin/sh

if [ "$1" = "0x00" ]; then
logger -t Lid Closed
sysctl hw.acpi.video.lcd0.active=0
else
logger -t Lid Opened
sysctl hw.acpi.video.lcd0.active=1
fi
but I did not get the proper behavior... I looked up /var/log/messages (from other machine using ssh access to my FreeBSD system) and saw proper messages Lid: Closed and Lid: Opened as I closed and opened the lid... But monitor was turned off all time, so I needed to restart system...

After that I loaded acpi_video module using kldload and repeated the same procedure described above, with same results (display has been turned of first time I closed lid, and it have not turned on as I opened it...). Then I restarted system again, and try to see what will happen when I try to run sysctl command from console... The output was:

Code:
[root@technodrome ~]# sysctl hw.acpi.video.lcd0.active=1
sysctl: unknown oid 'hw.acpi.video.lcd0.active'
Now, I looked at:

Code:
sysctl -a | grep acpi | more
and found just this concerning laptop lid:

Code:
....
hw.acpi.lid_switch_state: NONE
....
dev.acpi_lid.0.%desc: Control Method Lid Switch
dev.acpi_lid.0.%driver: acpi_lid
dev.acpi_lid.0.%location: handle=\_SB_.LID_
dev.acpi_lid.0.%pnpinfo: _HID=PNP0C0D _UID=0
dev.acpi_lid.0.%parent: acpi0
dev.acpi_lid.0.wake: 1
...
As you can see, somehow I miss hw.acpi.video.lcd0.active so I can use lid closing an opening...

Do I need to load some kernel module, or need to recompile or install something to get this working?

Thank everyone for help.

Regards,
pax
Reply With Quote