This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
resources:tools-software:linux-drivers:backlight:adp8860 [05 Sep 2012 11:22] – change source git repo Michael Hennerich | resources:tools-software:linux-drivers:backlight:adp8860 [11 Feb 2016 21:13] (current) – [Status] Lars-Peter Clausen | ||
---|---|---|---|
Line 43: | Line 43: | ||
===== Status ===== | ===== Status ===== | ||
- | ^ Source | + | ^ Source ^ Mainlined? ^ |
- | | [[git.linux.org> | + | | [[git.linux.org> |
===== Files ===== | ===== Files ===== | ||
Line 103: | Line 103: | ||
{{page> | {{page> | ||
- | <note info> | + | <WRAP info> |
**platform_data: | **platform_data: | ||
Includes what LEDs are available, feature selections and default initialization. | Includes what LEDs are available, feature selections and default initialization. | ||
- | </note> | + | </WRAP> |
<code c> | <code c> | ||
Line 127: | Line 127: | ||
} | } | ||
</ | </ | ||
- | |||
====== Adding Linux driver support ====== | ====== Adding Linux driver support ====== | ||
Line 134: | Line 133: | ||
"make qconfig" | "make qconfig" | ||
- | <note tip> | + | <WRAP tip> |
The ADP8860 Backlight driver depends on I2C. | The ADP8860 Backlight driver depends on I2C. | ||
It therefore requires selected I2C support to show up during kernel configuration. | It therefore requires selected I2C support to show up during kernel configuration. | ||
- | </note> | + | </WRAP> |
< | < | ||
Device Drivers | Device Drivers | ||
Graphics support | Graphics support | ||
- | [*] Backlight & LCD device support | + | [*] Backlight & LCD device support |
+ | </ | ||
+ | |||
+ | ====== ADP8860 Back-light LED Linux Driver ====== | ||
===== Supported Devices ===== | ===== Supported Devices ===== | ||
Line 246: | Line 248: | ||
{{page> | {{page> | ||
- | <note info> | + | <WRAP info> |
**platform_data: | **platform_data: | ||
Includes what LEDs are available, feature selections and default initialization. | Includes what LEDs are available, feature selections and default initialization. | ||
- | </note> | + | </WRAP> |
<code c> | <code c> | ||
Line 277: | Line 279: | ||
"make qconfig" | "make qconfig" | ||
- | <note tip> | + | <WRAP tip> |
The ADP8860 Backlight driver depends on I2C. | The ADP8860 Backlight driver depends on I2C. | ||
It therefore requires selected I2C support to show up during kernel configuration. | It therefore requires selected I2C support to show up during kernel configuration. | ||
- | </note> | + | </WRAP> |
< | < | ||
Line 418: | Line 420: | ||
====== More Information ====== | ====== More Information ====== | ||
- | |||
- | > | ||
- | < | ||
- | < | ||
- | </ | ||
- | |||
- | ====== Hardware configuration ====== | ||
- | |||
- | During test and driver development we used the ADP8860 Evaluation Mother/ | ||
- | |||
- | {{: | ||
- | |||
- | It can be easily wired to the Blackfin STAMP TWI/I2C header. | ||
- | |||
- | ^ BF537-STAMP (P10) TWI/I2C header | ||
- | ^ PIN ^ Function ^ PIN/ | ||
- | | 5 | SCL | SCL | | ||
- | | 6 | SDA| SDA | | ||
- | | 20 | GND | GND | | ||
- | |||
- | Leave J31 and J32 open (these jumpers connect the SCL and SDA to the cypress chip used as USB bridge). | ||
- | |||
- | The ADP8860 chip still needs Vin (to power the chip), Vddio (to pull nRST and nINT high), and Vboard (to power the ALS sensor on the daughter card). | ||
- | |||
- | |||
- | ====== Driver testing ====== | ||
- | |||
- | ===== Driver compiled as a module ===== | ||
- | |||
- | **ADP8860 driver is build as a module** | ||
- | < | ||
- | root:/> **modprobe adp8860_bl** | ||
- | adp8860_bl 0-002a: Rev.7 Backlight | ||
- | Registered led device: adp8860-led7 | ||
- | root:/> | ||
- | </ | ||
- | |||
- | ==== Example Backlight usage ==== | ||
- | |||
- | < | ||
- | root:/> cd sys/ | ||
- | root:/ | ||
- | -r--r--r-- | ||
- | -r--r--r-- | ||
- | -rw-rw-r-- | ||
- | -rw-r--r-- | ||
- | -rw-r--r-- | ||
- | lrwxrwxrwx | ||
- | -rw-rw-r-- | ||
- | -rw-rw-r-- | ||
- | -rw-rw-r-- | ||
- | -rw-rw-r-- | ||
- | -rw-rw-r-- | ||
- | -rw-rw-r-- | ||
- | -r--r--r-- | ||
- | drwxr-xr-x | ||
- | lrwxrwxrwx | ||
- | -rw-r--r-- | ||
- | root:/ | ||
- | </ | ||
- | |||
- | === Set Backlight Intensity === | ||
- | |||
- | < | ||
- | root:/ | ||
- | </ | ||
- | |||
- | === Query Backlight Intensity === | ||
- | |||
- | < | ||
- | root:/ | ||
- | 42 | ||
- | </ | ||
- | |||
- | === Enable Ambient Light Sensing Feature === | ||
- | |||
- | < | ||
- | root:/ | ||
- | </ | ||
- | |||
- | === Query Ambient Light Level === | ||
- | |||
- | < | ||
- | root:/ | ||
- | 1276 | ||
- | </ | ||
- | |||
- | === Query Ambient Light Zone === | ||
- | |||
- | < | ||
- | root:/ | ||
- | 2 | ||
- | </ | ||
- | |||
- | === Adjust Intensity for Ambient Light Zone 2 (office) === | ||
- | |||
- | < | ||
- | root:/ | ||
- | 22 | ||
- | </ | ||
- | |||
- | < | ||
- | root:/ | ||
- | 22 | ||
- | </ | ||
- | |||
- | ==== Example LED usage ==== | ||
- | < | ||
- | root:/> cd / | ||
- | root:/ | ||
- | -rw-r--r-- | ||
- | lrwxrwxrwx | ||
- | -r--r--r-- | ||
- | drwxr-xr-x | ||
- | lrwxrwxrwx | ||
- | </ | ||
- | |||
- | === Set Intensity === | ||
- | |||
- | < | ||
- | root:/ | ||
- | </ | ||
- | === Turn LED OFF === | ||
- | < | ||
- | root:/ | ||
- | </ | ||
- | === Query Max Brightness === | ||
- | < | ||
- | root:/ | ||
- | 255 | ||
- | root:/ | ||
- | </ | ||
- | |||
- | ====== More Information ====== | ||
- | |||