acpilid(4) - NetBSD Manual Pages

Command: Section: Arch: Collection:  
ACPILID(4)              NetBSD Kernel Interfaces Manual             ACPILID(4)

acpilid -- ACPI Lid Switch
acpilid* at acpi?
The acpilid driver supports ACPI ``lid switches''. The powerd(8) daemon can be used to control actions against the events of opening or closing the lid. The script used is /etc/powerd/scripts/lid_switch, and the events are either pressed (the lid was closed) or released (the lid was opened).
The following example modifies the mentioned script in order to put the system into (S3) sleep when the lid is closed: ... case "${2}" in pressed) logger -p info "${0}: suspending..." # As in sleep_button, kill some daemons. # /etc/rc.d/dhcpcd stop /etc/rc.d/network stop /etc/rc.d/wpa_supplicant stop # Suspend. # if /sbin/sysctl hw.acpi.sleep.state >/dev/null 2>&1; then /sbin/sysctl -w hw.acpi.sleep.state=3 fi # Waking up. # /etc/rc.d/wpa_supplicant start /etc/rc.d/network start /etc/rc.d/dhcpcd start ...
acpi(4), powerd(8), sysmon_pswitch(9)
The acpilid driver appeared in NetBSD 1.6. NetBSD 9.99 January 9, 2011 NetBSD 9.99
Powered by man-cgi (2020-09-24). Maintained for NetBSD by Kimmo Suominen. Based on man-cgi by Panagiotis Christias.