aboutsummaryrefslogtreecommitdiffstats
path: root/info/adjbacklight.texinfo
blob: 199c64b8629c1756d64a6a850da301f72c98b991 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
\input texinfo   @c -*-texinfo-*-

@c %**start of header
@setfilename adjbacklight.info
@settitle adjbacklight
@afourpaper
@documentencoding UTF-8
@documentlanguage en
@finalout
@c %**end of header


@c @defindex op
@c @synindex op vr
@c @synindex cp pg


@copying
This manual is for @command{adjbacklight}.

Copyright @copyright{} 2013, 2014 Mattias Andrée  (maandree@@member.fsf.org)

@quotation
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
any later version published by the Free Software Foundation; with no
Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
Texts. A copy of the license is included in the section entitled
``GNU Free Documentation License''.
@end quotation
@end copying


@ifnottex
@node Top
@top adjbacklight
@insertcopying
@end ifnottex

@titlepage
@title adjbacklight 5
@subtitle Convient method for adjusting the backlight on your portable computer.
@author Mattias Andrée, maandree@@member.fsf.org
@page
@vskip 0pt plus 1filll
@insertcopying
@page
@*@*
@center And sometimes the portable computers' adjustment keys arn't even wired to the hardware…
@end titlepage

@contents


@menu
* Overview::                        Overview of @command{adjbacklight}
* Invoking::                        How to start @command{adjbacklight}
* Using::                           How to use @command{adjbacklight}
* Behind the scenes::               How @command{adjbacklight} works
* License of adjbacklight::         Summary of the license of the program
* GNU General Public License::      The license of the program
* GNU Free Documentation License::  The license of this manual
* Concept index::                   Concept index
@end menu



@node Overview
@chapter Overview
@cindex overview
@cindex description

@command{adjbacklight} is convient method for adjusting the backlight on your
portable computer. Depending on your computer, the details of @command{adjbacklight}
differs.

For some computers program will adjust the same parameters as the keys on your
keyboard, one other computers this program will adjust an independent parameter
allowing more detailed adjustment and may not be affected by the battery status
change. One some computers the keys for the suns does not do anything and is
expected to be binded by the OS, for thoses computers this may be the best choice
if you are in the TTY.

@command{adjbacklight} allows 0.5 % precision, assuming that the firmware allows
at least that. If you want higher precision, it is simple to modify the source
code. Just run @code{sed -i s/200/400/g src/adjbacklight.c}, if you want
0.25 % precision.


@node Invoking
@chapter Invoking
@cindex invoking
@cindex starting
@cindex options
@cindex arguments
@cindex device
@cindex selecting device
@cindex @command{adjbacklight}
@cindex @option{-c}
@cindex @option{--copying}
@cindex @option{--copyright}
@cindex @option{-w}
@cindex @option{--warranty}
@cindex @option{-a}
@cindex @option{--all}

@command{adjbacklight} can be started with @option{-c}, @option{--copying} or
@option{--copyright} for displaying copyright information, @option{-w} or
@option{--warranty} for displaying a warranty disclaimer. If any other options
is used, help information is displayed.

To actually use the program, just execute @command{adjbacklight} without any
arguments, or with @option{-a} or @option{--all} to not limit the devices to
those that are not ACPI video devices. Alternatively you can list the devices
either by full path or just the name in the directory @file{/sys/class/backlight}.


@node Using
@chapter Using
@cindex usage
@cindex keyboard
@cindex darken screen
@cindex brighten screen
@cindex quit
@cindex exit
@cindex close
@cindex next screen
@cindex password
@cindex @command{sudo}

These key commands work when you start @command{adjbacklight} without
arguments and can see a bar. Due to restricted write permissions in
@file{/sys} you are required to enter your password and need to be a
sudoer; if you do not want this you could make your init sequence
give you write permissions to @file{/sys/class/backlight/*/brightness},
and just remove the @command{sudo} in the bash script @file{adjbacklight}.

The @kbd{left} and @kbd{down} arrow keys are used to darken the screen.
The @kbd{right} and @kbd{up} arrow keys are used to brighten the screen.

@kbd{q}, @kbd{enter} and @kbd{<control>d} continues to the next backlight
controller, or if you are at the last one, quits the program.


@node Behind the scenes
@chapter Behind the scenes
@cindex behind the scenes
@cindex inner workings

On normally configured Linux systems, the kernel mounts a virtual
partition on @file{/sys}. If you have screens using backlight,
you should find backlight device in @file{/sys/class/backlight}.
These devices are directories containing control files which you
can read the current values from or write to (perhaps using @command{echo})
to modify the value. In a directory in @file{/sys/class/backlight}
you will find @file{brightness} and @file{max_brightness}.
Just read from @file{max_brightness} to get the maximum allowed integer
value in @file{brightness}, the minimum value is 0.



@node License of adjbacklight
@appendix License of adjbacklight
@flushleft
adjbacklight – Convient method for adjusting the backlight on your portable computer

Copyright © 2012, 2013, 2014  Mattias Andrée (maandree@@member.fsf.org)

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.
@end flushleft

@node GNU General Public License
@appendix GNU General Public License
@include gpl.texinfo

@node GNU Free Documentation License
@appendix GNU Free Documentation License
@include fdl.texinfo

@node Concept index
@appendix Concept index
@printindex cp

@c @node Concept and program index
@c @appendix Concept and program index
@c @printindex pg

@c @node Variable and option index
@c @appendix Variable and option index
@c @printindex vr


@bye