summaryrefslogtreecommitdiff
path: root/firmware/target/arm/philips/sa9200/backlight-sa9200.c
diff options
context:
space:
mode:
authorDave Chapman <dave@dchapman.com>2008-10-31 00:16:42 +0000
committerDave Chapman <dave@dchapman.com>2008-10-31 00:16:42 +0000
commit42f77d4eb027afed4f4ef80f10c16112c2b7fe2b (patch)
tree2da09bcab257322dce48ddccc4a71d915318aa3a /firmware/target/arm/philips/sa9200/backlight-sa9200.c
parent324816f0190dec308f3496a288820a47926b1c17 (diff)
downloadrockbox-42f77d4eb027afed4f4ef80f10c16112c2b7fe2b.tar.gz
rockbox-42f77d4eb027afed4f4ef80f10c16112c2b7fe2b.zip
Abstract the PortalPlayer AS3514 handling with an "ascodec" API - inspired by the wmcodec API used with the Wolfson codecs. The intention is to implement this API for the AS3525 and then share code with the Sansa V2 ports.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18940 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/philips/sa9200/backlight-sa9200.c')
-rw-r--r--firmware/target/arm/philips/sa9200/backlight-sa9200.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/firmware/target/arm/philips/sa9200/backlight-sa9200.c b/firmware/target/arm/philips/sa9200/backlight-sa9200.c
index 33342d19f1..b3984ca9ad 100644
--- a/firmware/target/arm/philips/sa9200/backlight-sa9200.c
+++ b/firmware/target/arm/philips/sa9200/backlight-sa9200.c
@@ -23,7 +23,7 @@
23#include "system.h" 23#include "system.h"
24#include "lcd.h" 24#include "lcd.h"
25#include "backlight.h" 25#include "backlight.h"
26#include "i2c-pp.h" 26#include "ascodec.h"
27#include "as3514.h" 27#include "as3514.h"
28 28
29static unsigned short backlight_brightness = DEFAULT_BRIGHTNESS_SETTING; 29static unsigned short backlight_brightness = DEFAULT_BRIGHTNESS_SETTING;
@@ -46,12 +46,12 @@ void _backlight_on(void)
46#ifdef HAVE_LCD_ENABLE 46#ifdef HAVE_LCD_ENABLE
47 lcd_enable(true); /* power on lcd + visible display */ 47 lcd_enable(true); /* power on lcd + visible display */
48#endif 48#endif
49 pp_i2c_send(AS3514_I2C_ADDR, AS3514_DCDC15, backlight_brightness); 49 ascodec_write(AS3514_DCDC15, backlight_brightness);
50} 50}
51 51
52void _backlight_off(void) 52void _backlight_off(void)
53{ 53{
54 pp_i2c_send(AS3514_I2C_ADDR, AS3514_DCDC15, 0x0); 54 ascodec_write(AS3514_DCDC15, 0x0);
55#ifdef HAVE_LCD_ENABLE 55#ifdef HAVE_LCD_ENABLE
56 lcd_enable(false); /* power off visible display */ 56 lcd_enable(false); /* power off visible display */
57#endif 57#endif