summaryrefslogtreecommitdiff
path: root/firmware/backlight.c
diff options
context:
space:
mode:
authorHristo Kovachev <bger@rockbox.org>2005-12-22 13:31:14 +0000
committerHristo Kovachev <bger@rockbox.org>2005-12-22 13:31:14 +0000
commitb1a230353e81863189e0be1603c1ee6fa653485d (patch)
tree8a6ff80d5c5d0913032762858071aa40ac120d7f /firmware/backlight.c
parent9b83c6c4bddca41411d31b8aab17ecc577b37eb4 (diff)
downloadrockbox-b1a230353e81863189e0be1603c1ee6fa653485d.tar.gz
rockbox-b1a230353e81863189e0be1603c1ee6fa653485d.zip
Oops:) Make the brightness setting purely numerical
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8281 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/backlight.c')
-rw-r--r--firmware/backlight.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/firmware/backlight.c b/firmware/backlight.c
index d118830721..740acd1d82 100644
--- a/firmware/backlight.c
+++ b/firmware/backlight.c
@@ -548,6 +548,8 @@ void backlight_set_brightness(int val)
548 /* set H300 brightness by changing the PWM 548 /* set H300 brightness by changing the PWM
549 accepts 0..15 but note that 0 and 1 give a black display! */ 549 accepts 0..15 but note that 0 and 1 give a black display! */
550 unsigned char ucVal = (unsigned char)(val & 0x0F); 550 unsigned char ucVal = (unsigned char)(val & 0x0F);
551 if(val<MIN_BRIGHTNESS_SETTING)
552 val=MIN_BRIGHTNESS_SETTING;
551 pcf50606_set_bl_pwm(ucVal); 553 pcf50606_set_bl_pwm(ucVal);
552} 554}
553#endif 555#endif