kernel: Nuke the old (and deprecated) ata(4) driver and atacontrol(8).
[dragonfly.git] / share / man / man4 / aps.4
1 .\"     $OpenBSD: aps.4,v 1.8 2007/12/23 22:09:19 jmc Exp $
2 .\"
3 .\" Copyright (c) 2005 Jonathan Gray <jsg@openbsd.org>
4 .\"
5 .\" Permission to use, copy, modify, and distribute this software for any
6 .\" purpose with or without fee is hereby granted, provided that the above
7 .\" copyright notice and this permission notice appear in all copies.
8 .\"
9 .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 .\"
17 .Dd March 18, 2010
18 .Dt APS 4
19 .Os
20 .Sh NAME
21 .Nm aps
22 .Nd ThinkPad Active Protection System accelerometer
23 .Sh SYNOPSIS
24 To compile this driver into the kernel,
25 place the following lines in your
26 kernel configuration file:
27 .Bd -ragged -offset indent
28 .Cd "device isa"
29 .Cd "device aps0 at isa? port 0x1600"
30 .Ed
31 .Pp
32 Alternatively, to load the driver as a
33 module at boot time, place the following line in
34 .Xr loader.conf 5 :
35 .Bd -literal -offset indent
36 aps_load="YES"
37 .Ed
38 .Sh DESCRIPTION
39 The
40 .Nm
41 driver provides support for several sensors found in some
42 .Tn ThinkPad
43 laptops.
44 .Pp
45 The sensors currently supported are:
46 .Bl -column "Sensor         " "Units  " "Typical" -offset indent
47 .It Sy "Sensor" Ta Sy "Units" Ta Sy "Typical Use"
48 .It Li "X_ACCEL" Ta "Unknown" Ta "X Acceleration"
49 .It Li "Y_ACCEL" Ta "Unknown" Ta "Y Acceleration"
50 .It Li "X_VAR" Ta "Unknown" Ta "Weighted X Acceleration?"
51 .It Li "Y_VAR" Ta "Unknown" Ta "Weighted Y Acceleration?"
52 .It Li "Temp1" Ta "uK" Ta "Unknown"
53 .It Li "Temp2" Ta "uK" Ta "Unknown"
54 .It Li "Keyboard Active" Ta "boolean" Ta "Keyboard activity"
55 .It Li "Mouse Active" Ta "boolean" Ta "Mouse activity"
56 .It Li "Lid Open" Ta "boolean" Ta "Lid state"
57 .El
58 .Pp
59 Sensor values are made available through the
60 .Dv HW_SENSORS
61 .Xr sysctl 3
62 interface,
63 and can be monitored with the
64 .Xr systat 1
65 .Ar sensors
66 display,
67 .Xr sensorsd 8
68 and
69 .Xr sysctl 8
70 .Ar hw.sensors .
71 For example, on a ThinkPad R51:
72 .Bd -literal -offset indent
73 %sysctl hw.sensors.aps0
74 hw.sensors.aps0.raw0: 488 (X_ACCEL)
75 hw.sensors.aps0.raw1: 481 (Y_ACCEL)
76 hw.sensors.aps0.raw2: 488 (X_VAR)
77 hw.sensors.aps0.raw3: 481 (Y_VAR)
78 hw.sensors.aps0.temp0: 52.00 degC
79 hw.sensors.aps0.temp1: 52.00 degC
80 hw.sensors.aps0.indicator0: Off (Keyboard Active)
81 hw.sensors.aps0.indicator1: Off (Mouse Active)
82 hw.sensors.aps0.indicator2: On (Lid Open)
83 .Ed
84 .Sh SEE ALSO
85 .Xr systat 1 ,
86 .Xr sysctl 3 ,
87 .Xr intro 4 ,
88 .Xr isa 4 ,
89 .Xr sensorsd 8 ,
90 .Xr sysctl 8
91 .Sh HISTORY
92 The
93 .Nm
94 driver first appeared in
95 .Ox 3.8 .
96 .Dx
97 support was added in
98 .Dx 2.5 .
99 .Sh AUTHORS
100 .An -nosplit
101 The
102 .Nm
103 driver was written by
104 .An Jonathan Gray Aq jsg@openbsd.org .
105 It was adapted to
106 .Dx
107 by
108 .An Constantine A. Murenin ,
109 University of Waterloo.
110 .Sh CAVEATS
111 The
112 .Nm
113 driver does not yet maintain state and subsequently does not take
114 evasive action when it thinks the hard drive is in danger.
115 .Pp
116 The Y axis on X40 and possibly other models seems to be inverted.
117 It is unknown how to distinguish between different versions of the
118 accelerometer to compensate for this in the driver at this time.
119 .Pp
120 As IBM provides no documentation, it is not known what all the available
121 sensors are used for.