Skip to content

Apple Cinema Display Control Utility for Linux -- clone of upstream with some minor updates

License

Notifications You must be signed in to change notification settings

taylor/acdcontrol

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

<html>
  <head>
    <title>
      Apple Cinema Display Brightness Control
  </title></head>
  <body>
  <h3 id="usage">Usage</h3>
  <code>./acdcontrol [--silent|-s] [--brief|-b] [--help|-h] [--about|-a] 
    [--detect|-d] [--list-all|-l]
    &lt;hid device(s)&gt; [&lt;brightness&gt;]
  </code><br />
  <h4>Parameters</h4>
  <dl>
    <dt class="option">--silent,-s</dt>
    <dd> Suppress non-functional program output</dd>
    
    <dt id="opt-brief" class="option">--brief,-b</dt>
    <dd>Print brightness value only when in query mode, 
    otherwise ignored. </dd>
    
    <dt class="option">--help,-h</dt>
    <dd>Show short help message and quit.</dd>
    
    <dt class="option">--about,-a</dt>
    <dd>Show information about the program, some credits 
    and thanks.</dd>

  <dt class="option">--detect,-d</dt>
  <dd>Run program in the detection mode. In this mode
    no writes are performed to device so you can use any
    number of files if you are not sure that your monitor(s)
    are supported.</dd>
  <dt class="option">--list-all,-l</dt>
  <dd>Lists all "officially" supported monitors and quits.
    If you do not see the device, this does not mean that it won't work
    it simply means that I did not tested it on such a device. I'll appreiciate
    if you submit your information in the <a href="http://sourceforge.net/forum/forum.php?thread_id=1215781&forum_id=431570">forum</a> for any display that works</dd>
    
    <dt class="param">hid device</dt>
    <dd>device that represents your Apple Cinema display. It should be one
    of <code class="filename">/dev/usb/hiddev<b>X</b></code> or 
    <code class="filename">/dev/hiddev<b>X</b></code>. 
    <h4>Note</h4> 
      You must have write permissions to this device in order to control 
      the display being <em>user</em>,
      not <em>root</em>. If you have no such permissions, you can either grant
      read/write permission to <em>world</em>:<br />
      <kbd>chmod a+rw /dev/usb/hiddev<b>X</b></kbd><br />
      or change an ownership:<br />
      <kbd>chown &lt;<em>your user name</em>&gt;:users /dev/usb/hiddev<b>X</b></kbd><br />
      under <em>root</em>. Or ask your Linux guru friend to do so ;)
      
    <h4>Note</h4>
      It should be safe to run the program on other device than Apple Cinema/Studio display as
      the program checks whether the device is Apple display and warns about it.
    </dd>
    <dt class="param">brightness</dt>
    <dd>When this option is specified, the operation is <strong>set brightness</strong>,
    otherwise, current brightness is retrieved. If brightness starts with '+' or '-', 
    the current brightness is increased or decreased by that value. (<b>Note:</b> You have to place <code>--</code> before the negative value!) <br />
    Brightness is a parameter ranged [0-255]. <br />
    Note, that not every value toggles the backlight power; different Apple Display
    models have different granularity. I use Apple Cinema 20" (clear plastic) and I'm 
    feeling comfortable with the value of 160. I set 0, however, to see films in the 
    darkness. See also: <a href="#opt-brief">--brief</a>
    option and <a href="#limitations">Known Limitations</a> section.</dd>
  </dl>

  <h3 id="examples">Examples</h3>
    In the following examples I assume that your HID device is /dev/hiddev0. You may 
    have it as /dev/hiddevX or /dev/usb/hiddevX.
    

      
    <dl>
    <dt><code>acdcontrol</code><br />
          <code>acdcontrol --help</code></dt>
      <dd>Show long help message.</dd>
    
      <dt><code>acdcontrol --detect /dev/hiddev*</code></dt>
      <dd>Perform detection, which HID device is actually your display to be controlled.</dd>
    
      <dt><code>acdcontrol /dev/hiddev0</code></dt>
      <dd>Read current brightness parameter</dd>
    
      <code>acdcontrol /dev/hiddev0 160</code>
      <dd>Set brightness to 160. Note, that brightness setting depends on your model. 
        Generally, this parameter may get values in the range [0-255].</dd>
    
      <dt><code>acdcontrol /dev/hiddev0 +10</code></dt>
      <dd>Increment current brightness by 10.</dd>
    
      <dt><code>acdcontrol /dev/hiddev0 -- -10</code></dt>
      <dd>Decrement current brightness by 10. Please,note <code>--</code>!</dd>
  <h3 id="limitations">Known Limitations</h3>
  <ul>
    <li>Currently, the display detection process is not fully automated as you need to specify an 
      <abbr TITLE="Human Interface Device">HID</abbr> device(s) file name(s).
    </li> 
    <li>First time (after boot up) brightness is retrieved <em>incorrectly</em> (zero value), 
      however, after it is set, the return value is correct. It shouldn't concern
      you much as Cinema/Studio Display stores actual brightness settings between
      the sessions.
    </li>
  </ul> 
  
  </body>


</html>

About

Apple Cinema Display Control Utility for Linux -- clone of upstream with some minor updates

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages