瀏覽代碼

Update README to explain changes introduced in cd70ff5

Also add more examples
Abdullah ibn Nadjo 7 年之前
父節點
當前提交
5d3c89630c
共有 1 個檔案被更改,包括 27 行新增4 行删除
  1. 27
    4
      README.md

+ 27
- 4
README.md 查看文件

@@ -40,7 +40,7 @@ ACTION=="add", SUBSYSTEM=="backlight", RUN+="/bin/chmod g+w /sys/class/backlight
40 40
 
41 41
 ## Usage
42 42
 
43
-This application usually has 4 different criteria on flags to use, which are operation modes, value mode, target and controller mode. Flags from these different modes can never be used in conjunction, but all of them do not always have to be specified (although it is recommended to do so for verbosity).
43
+This application usually has 5 different criteria on flags to use, which are operation modes, value mode, target, field and controller mode. Flags from these different modes can never be used in conjunction, but all of them do not always have to be specified (although it is recommended to do so for verbosity).
44 44
 
45 45
 **Note:** This application will only print errors if you are using it incorrectly. If something goes wrong, and you can't figure out why, try setting the verbosity flag with -v:
46 46
 
@@ -74,12 +74,18 @@ Remember, this is the unit that will be used when you set, get, add or subtract
74 74
 
75 75
 ### Target
76 76
 
77
-As you can not only handle the **brightness** of controllers, you may also specify a target to read/write from/to:
77
+You can choose which target to act on:
78
+
79
+* -l: Act on screen backlight
80
+* -k: Act on keyboard backlight and LEDs
81
+
82
+### Field
83
+
84
+As you can not only handle the **brightness** of controllers, you may also specify a field to read/write from/to:
78 85
 
79 86
 * -b: Current brightness of selected controller
80 87
 * -m: Maximum brightness of selected controller
81 88
 * -c: Minimum brightness (cap) of selected controller
82
-* -k: Set keyboard brightness instead of display brightness
83 89
 
84 90
 The minimum brightness is a feature implemented as some controllers make the screen go pitch black at 0%, if you have a controller like that, it is recommended to set this value (in either percent or in raw mode). These values will be saved in raw mode though, so if you specify it in percent it might not be too accurate depending on your controller.
85 91
 
@@ -93,7 +99,7 @@ Finally, you can either use the built-in controller selection to get the control
93 99
 
94 100
 Get the current brightness in percent
95 101
 
96
-`light -G`
102
+`light -G`, or simply `light`
97 103
 
98 104
 Increase brightness by 5 percent
99 105
 
@@ -103,3 +109,20 @@ Set the minimum cap to 2 in raw value on the acpi_video0 controller:
103 109
 
104 110
 `light -Scrs "acpi_video0" 2`
105 111
 
112
+Try to set the brightness to 0 after that, it will be changed to the minimum 2
113
+
114
+`light -Srs "acpi_video0" 0`
115
+
116
+Find keyboard controllers
117
+
118
+`light -Lk`
119
+
120
+Activate `ScrollLock` LED
121
+
122
+`light -Sks "input15::scrolllock" 100`
123
+
124
+Usually, LEDs only take 0 or 1 in raw value (i.e. for off/on), so you can write
125
+
126
+`light -Skrs "input15::scrolllock" 1`
127
+
128
+Verify this with `light -v3 -mkrs input15::scrolllock`, you should get a max. brightness of 1