mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 05:05:20 -05:00
Make the Philips SA9200 port build again.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19464 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
c7c546cf59
commit
a742c3cd56
1 changed files with 7 additions and 17 deletions
|
|
@ -26,16 +26,9 @@
|
||||||
#include "ascodec.h"
|
#include "ascodec.h"
|
||||||
#include "as3514.h"
|
#include "as3514.h"
|
||||||
|
|
||||||
static unsigned short backlight_brightness = DEFAULT_BRIGHTNESS_SETTING;
|
|
||||||
|
|
||||||
void _backlight_set_brightness(int brightness)
|
void _backlight_set_brightness(int brightness)
|
||||||
{
|
{
|
||||||
backlight_brightness = brightness;
|
ascodec_write(AS3514_DCDC15, brightness);
|
||||||
|
|
||||||
if (brightness > 0)
|
|
||||||
_backlight_on();
|
|
||||||
else
|
|
||||||
_backlight_off();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void _backlight_on(void)
|
void _backlight_on(void)
|
||||||
|
|
@ -46,7 +39,10 @@ void _backlight_on(void)
|
||||||
#ifdef HAVE_LCD_ENABLE
|
#ifdef HAVE_LCD_ENABLE
|
||||||
lcd_enable(true); /* power on lcd + visible display */
|
lcd_enable(true); /* power on lcd + visible display */
|
||||||
#endif
|
#endif
|
||||||
ascodec_write(AS3514_DCDC15, backlight_brightness);
|
#ifndef USE_BACKLIGHT_SW_FADING
|
||||||
|
/* that part ain't useful when fading */
|
||||||
|
_backlight_set_brightness(backlight_brightness);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void _backlight_off(void)
|
void _backlight_off(void)
|
||||||
|
|
@ -62,16 +58,10 @@ void _backlight_off(void)
|
||||||
|
|
||||||
void _buttonlight_on(void)
|
void _buttonlight_on(void)
|
||||||
{
|
{
|
||||||
GPIO_SET_BITWISE(GPIOG_OUTPUT_VAL, 0x80);
|
/* TODO */
|
||||||
#ifdef SANSA_C200
|
|
||||||
GPIO_SET_BITWISE(GPIOB_OUTPUT_VAL, 0x10); /* The "menu" backlight */
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void _buttonlight_off(void)
|
void _buttonlight_off(void)
|
||||||
{
|
{
|
||||||
GPIO_CLEAR_BITWISE(GPIOG_OUTPUT_VAL, 0x80);
|
/* TODO */
|
||||||
#ifdef SANSA_C200
|
|
||||||
GPIO_CLEAR_BITWISE(GPIOB_OUTPUT_VAL, 0x10); /* The "menu" backlight */
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue