From f34cd80f638a6ca3b336f6ebd14cd958974b2760 Mon Sep 17 00:00:00 2001 From: Mark Arigo Date: Wed, 18 Feb 2009 02:19:22 +0000 Subject: Backlight brightness and button lights for the Philips HDD1630 git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20035 a1c6a512-1295-4272-9138-f99709370657 --- .../target/arm/philips/hdd1630/power-hdd1630.c | 23 +++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'firmware/target/arm/philips/hdd1630/power-hdd1630.c') diff --git a/firmware/target/arm/philips/hdd1630/power-hdd1630.c b/firmware/target/arm/philips/hdd1630/power-hdd1630.c index 22e11c803a..02279fd560 100755 --- a/firmware/target/arm/philips/hdd1630/power-hdd1630.c +++ b/firmware/target/arm/philips/hdd1630/power-hdd1630.c @@ -28,6 +28,7 @@ #include "power.h" #include "logf.h" #include "usb.h" +#include "synaptics-mep.h" void power_init(void) { @@ -46,6 +47,27 @@ void power_init(void) GPIOE_OUTPUT_EN |= 0x40; GPIOE_OUTPUT_VAL &= ~0x40; /* off */ #endif + +#ifndef BOOTLOADER + /* enable touchpad here because we need it for + both buttons and button lights */ + GPO32_ENABLE |= 0x80; + GPO32_VAL &= ~0x80; + udelay(1000); + + GPIOD_ENABLE |= 0x80; /* enable ACK */ + GPIOA_ENABLE |= (0x10 | 0x20); /* enable DATA, CLK */ + + GPIOD_OUTPUT_EN |= 0x80; /* set ACK */ + GPIOD_OUTPUT_VAL |= 0x80; /* high */ + + GPIOA_OUTPUT_EN &= ~0x20; /* CLK */ + + GPIOA_OUTPUT_EN |= 0x10; /* set DATA */ + GPIOA_OUTPUT_VAL |= 0x10; /* high */ + + syn_init(); +#endif } unsigned int power_input_status(void) @@ -70,7 +92,6 @@ void ide_power_enable(bool on) /* We do nothing */ } - bool ide_powered(void) { /* pretend we are always powered - we don't turn it off */ -- cgit v1.2.3