summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmaury Pouly <pamaury@rockbox.org>2011-11-14 19:46:09 +0000
committerAmaury Pouly <pamaury@rockbox.org>2011-11-14 19:46:09 +0000
commit7fec08927bdca55a7b49d44fda6feb3952d4cf2d (patch)
treeee4f44a49be7ea79973c0e542cd827126fb020c5
parent2a45f7772bc00c7ae2ccbe482d1b00ce54e722e7 (diff)
downloadrockbox-7fec08927bdca55a7b49d44fda6feb3952d4cf2d.tar.gz
rockbox-7fec08927bdca55a7b49d44fda6feb3952d4cf2d.zip
fuze+: fix backlight to have a real zero
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30978 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--firmware/export/config/sansafuzeplus.h2
-rw-r--r--firmware/target/arm/imx233/sansa-fuzeplus/backlight-fuzeplus.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/firmware/export/config/sansafuzeplus.h b/firmware/export/config/sansafuzeplus.h
index 2d744125c6..8039b8699f 100644
--- a/firmware/export/config/sansafuzeplus.h
+++ b/firmware/export/config/sansafuzeplus.h
@@ -109,7 +109,7 @@
109#define HAVE_BACKLIGHT_BRIGHTNESS 109#define HAVE_BACKLIGHT_BRIGHTNESS
110 110
111/* Main LCD backlight brightness range and defaults */ 111/* Main LCD backlight brightness range and defaults */
112#define MIN_BRIGHTNESS_SETTING 1 112#define MIN_BRIGHTNESS_SETTING 0
113#define MAX_BRIGHTNESS_SETTING 80 113#define MAX_BRIGHTNESS_SETTING 80
114#define DEFAULT_BRIGHTNESS_SETTING 40 114#define DEFAULT_BRIGHTNESS_SETTING 40
115 115
diff --git a/firmware/target/arm/imx233/sansa-fuzeplus/backlight-fuzeplus.c b/firmware/target/arm/imx233/sansa-fuzeplus/backlight-fuzeplus.c
index 90bd8b556b..6e13c0419c 100644
--- a/firmware/target/arm/imx233/sansa-fuzeplus/backlight-fuzeplus.c
+++ b/firmware/target/arm/imx233/sansa-fuzeplus/backlight-fuzeplus.c
@@ -28,7 +28,8 @@
28 28
29void _backlight_set_brightness(int brightness) 29void _backlight_set_brightness(int brightness)
30{ 30{
31 brightness = 32 - (brightness * 32) / 100; 31 if(brightness != 0)
32 brightness = 32 - (brightness * 32) / 100;
32 imx233_set_gpio_output(1, 28, false); 33 imx233_set_gpio_output(1, 28, false);
33 udelay(600); 34 udelay(600);
34 while(brightness-- > 0) 35 while(brightness-- > 0)