asus-laptop.txt 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258
  1. Asus Laptop Extras
  2. Version 0.1
  3. August 6, 2009
  4. Corentin Chary <corentincj@iksaif.net>
  5. http://acpi4asus.sf.net/
  6. This driver provides support for extra features of ACPI-compatible ASUS laptops.
  7. It may also support some MEDION, JVC or VICTOR laptops (such as MEDION 9675 or
  8. VICTOR XP7210 for example). It makes all the extra buttons generate input
  9. events (like keyboards).
  10. On some models adds support for changing the display brightness and output,
  11. switching the LCD backlight on and off, and most importantly, allows you to
  12. blink those fancy LEDs intended for reporting mail and wireless status.
  13. This driver supercedes the old asus_acpi driver.
  14. Requirements
  15. ------------
  16. Kernel 2.6.X sources, configured for your computer, with ACPI support.
  17. You also need CONFIG_INPUT and CONFIG_ACPI.
  18. Status
  19. ------
  20. The features currently supported are the following (see below for
  21. detailed description):
  22. - Fn key combinations
  23. - Bluetooth enable and disable
  24. - Wlan enable and disable
  25. - GPS enable and disable
  26. - Video output switching
  27. - Ambient Light Sensor on and off
  28. - LED control
  29. - LED Display control
  30. - LCD brightness control
  31. - LCD on and off
  32. A compatibility table by model and feature is maintained on the web
  33. site, http://acpi4asus.sf.net/.
  34. Usage
  35. -----
  36. Try "modprobe asus-laptop". Check your dmesg (simply type dmesg). You should
  37. see some lines like this :
  38. Asus Laptop Extras version 0.42
  39. L2D model detected.
  40. If it is not the output you have on your laptop, send it (and the laptop's
  41. DSDT) to me.
  42. That's all, now, all the events generated by the hotkeys of your laptop
  43. should be reported via netlink events. You can check with
  44. "acpi_genl monitor" (part of the acpica project).
  45. Hotkeys are also reported as input keys (like keyboards) you can check
  46. which key are supported using "xev" under X11.
  47. You can get information on the version of your DSDT table by reading the
  48. /sys/devices/platform/asus-laptop/infos entry. If you have a question or a
  49. bug report to do, please include the output of this entry.
  50. LEDs
  51. ----
  52. You can modify LEDs be echoing values to /sys/class/leds/asus::*/brightness :
  53. echo 1 > /sys/class/leds/asus::mail/brightness
  54. will switch the mail LED on.
  55. You can also know if they are on/off by reading their content and use
  56. kernel triggers like disk-activity or heartbeat.
  57. Backlight
  58. ---------
  59. You can control lcd backlight power and brightness with
  60. /sys/class/backlight/asus-laptop/. Brightness Values are between 0 and 15.
  61. Wireless devices
  62. ---------------
  63. You can turn the internal Bluetooth adapter on/off with the bluetooth entry
  64. (only on models with Bluetooth). This usually controls the associated LED.
  65. Same for Wlan adapter.
  66. Display switching
  67. -----------------
  68. Note: the display switching code is currently considered EXPERIMENTAL.
  69. Switching works for the following models:
  70. L3800C
  71. A2500H
  72. L5800C
  73. M5200N
  74. W1000N (albeit with some glitches)
  75. M6700R
  76. A6JC
  77. F3J
  78. Switching doesn't work for the following:
  79. M3700N
  80. L2X00D (locks the laptop under certain conditions)
  81. To switch the displays, echo values from 0 to 15 to
  82. /sys/devices/platform/asus-laptop/display. The significance of those values
  83. is as follows:
  84. +-------+-----+-----+-----+-----+-----+
  85. | Bin | Val | DVI | TV | CRT | LCD |
  86. +-------+-----+-----+-----+-----+-----+
  87. + 0000 + 0 + + + + +
  88. +-------+-----+-----+-----+-----+-----+
  89. + 0001 + 1 + + + + X +
  90. +-------+-----+-----+-----+-----+-----+
  91. + 0010 + 2 + + + X + +
  92. +-------+-----+-----+-----+-----+-----+
  93. + 0011 + 3 + + + X + X +
  94. +-------+-----+-----+-----+-----+-----+
  95. + 0100 + 4 + + X + + +
  96. +-------+-----+-----+-----+-----+-----+
  97. + 0101 + 5 + + X + + X +
  98. +-------+-----+-----+-----+-----+-----+
  99. + 0110 + 6 + + X + X + +
  100. +-------+-----+-----+-----+-----+-----+
  101. + 0111 + 7 + + X + X + X +
  102. +-------+-----+-----+-----+-----+-----+
  103. + 1000 + 8 + X + + + +
  104. +-------+-----+-----+-----+-----+-----+
  105. + 1001 + 9 + X + + + X +
  106. +-------+-----+-----+-----+-----+-----+
  107. + 1010 + 10 + X + + X + +
  108. +-------+-----+-----+-----+-----+-----+
  109. + 1011 + 11 + X + + X + X +
  110. +-------+-----+-----+-----+-----+-----+
  111. + 1100 + 12 + X + X + + +
  112. +-------+-----+-----+-----+-----+-----+
  113. + 1101 + 13 + X + X + + X +
  114. +-------+-----+-----+-----+-----+-----+
  115. + 1110 + 14 + X + X + X + +
  116. +-------+-----+-----+-----+-----+-----+
  117. + 1111 + 15 + X + X + X + X +
  118. +-------+-----+-----+-----+-----+-----+
  119. In most cases, the appropriate displays must be plugged in for the above
  120. combinations to work. TV-Out may need to be initialized at boot time.
  121. Debugging:
  122. 1) Check whether the Fn+F8 key:
  123. a) does not lock the laptop (try a boot with noapic / nolapic if it does)
  124. b) generates events (0x6n, where n is the value corresponding to the
  125. configuration above)
  126. c) actually works
  127. Record the disp value at every configuration.
  128. 2) Echo values from 0 to 15 to /sys/devices/platform/asus-laptop/display.
  129. Record its value, note any change. If nothing changes, try a broader range,
  130. up to 65535.
  131. 3) Send ANY output (both positive and negative reports are needed, unless your
  132. machine is already listed above) to the acpi4asus-user mailing list.
  133. Note: on some machines (e.g. L3C), after the module has been loaded, only 0x6n
  134. events are generated and no actual switching occurs. In such a case, a line
  135. like:
  136. echo $((10#$arg-60)) > /sys/devices/platform/asus-laptop/display
  137. will usually do the trick ($arg is the 0000006n-like event passed to acpid).
  138. Note: there is currently no reliable way to read display status on xxN
  139. (Centrino) models.
  140. LED display
  141. -----------
  142. Some models like the W1N have a LED display that can be used to display
  143. several items of information.
  144. LED display works for the following models:
  145. W1000N
  146. W1J
  147. To control the LED display, use the following :
  148. echo 0x0T000DDD > /sys/devices/platform/asus-laptop/
  149. where T control the 3 letters display, and DDD the 3 digits display,
  150. according to the tables below.
  151. DDD (digits)
  152. 000 to 999 = display digits
  153. AAA = ---
  154. BBB to FFF = turn-off
  155. T (type)
  156. 0 = off
  157. 1 = dvd
  158. 2 = vcd
  159. 3 = mp3
  160. 4 = cd
  161. 5 = tv
  162. 6 = cpu
  163. 7 = vol
  164. For example "echo 0x01000001 >/sys/devices/platform/asus-laptop/ledd"
  165. would display "DVD001".
  166. Driver options:
  167. ---------------
  168. Options can be passed to the asus-laptop driver using the standard
  169. module argument syntax (<param>=<value> when passing the option to the
  170. module or asus-laptop.<param>=<value> on the kernel boot line when
  171. asus-laptop is statically linked into the kernel).
  172. wapf: WAPF defines the behavior of the Fn+Fx wlan key
  173. The significance of values is yet to be found, but
  174. most of the time:
  175. - 0x0 should do nothing
  176. - 0x1 should allow to control the device with Fn+Fx key.
  177. - 0x4 should send an ACPI event (0x88) while pressing the Fn+Fx key
  178. - 0x5 like 0x1 or 0x4
  179. The default value is 0x1.
  180. Unsupported models
  181. ------------------
  182. These models will never be supported by this module, as they use a completely
  183. different mechanism to handle LEDs and extra stuff (meaning we have no clue
  184. how it works):
  185. - ASUS A1300 (A1B), A1370D
  186. - ASUS L7300G
  187. - ASUS L8400
  188. Patches, Errors, Questions:
  189. --------------------------
  190. I appreciate any success or failure
  191. reports, especially if they add to or correct the compatibility table.
  192. Please include the following information in your report:
  193. - Asus model name
  194. - a copy of your ACPI tables, using the "acpidump" utility
  195. - a copy of /sys/devices/platform/asus-laptop/infos
  196. - which driver features work and which don't
  197. - the observed behavior of non-working features
  198. Any other comments or patches are also more than welcome.
  199. acpi4asus-user@lists.sourceforge.net
  200. http://sourceforge.net/projects/acpi4asus