summaryrefslogtreecommitdiff
path: root/firmware/backlight.c
diff options
context:
space:
mode:
authorDave Chapman <dave@dchapman.com>2005-11-07 23:07:19 +0000
committerDave Chapman <dave@dchapman.com>2005-11-07 23:07:19 +0000
commit77372d12189c70cb810a7e88bc2ee7a56f64646c (patch)
tree057d0d474042874850b6262b78f80d2335cb0629 /firmware/backlight.c
parent3cd5c646d03089df8d58b773d4a1bc8323021adc (diff)
downloadrockbox-77372d12189c70cb810a7e88bc2ee7a56f64646c.zip
rockbox-77372d12189c70cb810a7e88bc2ee7a56f64646c.tar.gz
rockbox-77372d12189c70cb810a7e88bc2ee7a56f64646c.tar.bz2
rockbox-77372d12189c70cb810a7e88bc2ee7a56f64646c.tar.xz
Initial commit of work-in-progress iPod port
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7781 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/backlight.c')
-rw-r--r--firmware/backlight.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/firmware/backlight.c b/firmware/backlight.c
index ecd4403..eafa501 100644
--- a/firmware/backlight.c
+++ b/firmware/backlight.c
@@ -212,6 +212,10 @@ static void __backlight_off(void)
and_b(~0x40, &PADRH); /* drive it low */
#elif CONFIG_BACKLIGHT == BL_GMINI
P1 &= ~0x10;
+#elif CONFIG_BACKLIGHT == BL_IPOD4G
+ /* fades backlight off on 4g */
+ outl(inl(0x70000084) & ~0x2000000, 0x70000084);
+ outl(0x80000000, 0x7000a010);
#endif
}
@@ -235,6 +239,12 @@ static void __backlight_on(void)
or_b(0x40, &PADRH); /* drive it high */
#elif CONFIG_BACKLIGHT == BL_GMINI
P1 |= 0x10;
+#elif CONFIG_BACKLIGHT == BL_IPOD4G
+ /* brightness full */
+ outl(0x80000000 | (0xff << 16), 0x7000a010);
+
+ /* set port b bit 3 on */
+ outl(((0x100 | 1) << 3), 0x6000d824);
#endif
}