summaryrefslogtreecommitdiff
path: root/firmware/target/arm/sandisk/sansa-e200/backlight-e200.c
diff options
context:
space:
mode:
authorBarry Wardell <rockbox@barrywardell.net>2007-02-03 13:39:20 +0000
committerBarry Wardell <rockbox@barrywardell.net>2007-02-03 13:39:20 +0000
commita7af649766ff3a673783ac375a264ab69fbbe104 (patch)
tree50c8f5430557424af3c53398e84ce30c76d28617 /firmware/target/arm/sandisk/sansa-e200/backlight-e200.c
parent1a2dddc346e60211210c8f3b0b378be54108f652 (diff)
Backlight support for Sansa, including brightness. Thanks to Rene
Peinthor and FS#6608. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12186 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/sandisk/sansa-e200/backlight-e200.c')
-rw-r--r--firmware/target/arm/sandisk/sansa-e200/backlight-e200.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/firmware/target/arm/sandisk/sansa-e200/backlight-e200.c b/firmware/target/arm/sandisk/sansa-e200/backlight-e200.c
index 492942361a..787f14b1a6 100644
--- a/firmware/target/arm/sandisk/sansa-e200/backlight-e200.c
+++ b/firmware/target/arm/sandisk/sansa-e200/backlight-e200.c
@@ -16,10 +16,26 @@
* KIND, either express or implied.
*
****************************************************************************/
+#include "config.h"
+#include "backlight-target.h"
+#include "system.h"
+#include "backlight.h"
+#include "i2c-pp.h"
+
+static unsigned short backlight_brightness;
+
+void __backlight_set_brightness(int brightness)
+{
+ backlight_brightness = brightness;
+ pp_i2c_send( 0x46, 0x23, backlight_brightness);
+}
+
void __backlight_on(void)
{
+ pp_i2c_send( 0x46, 0x23, backlight_brightness);
}
void __backlight_off(void)
{
+ pp_i2c_send( 0x46, 0x23, 0x0);
}