summaryrefslogtreecommitdiff
path: root/firmware/target/coldfire/iaudio
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/coldfire/iaudio')
-rw-r--r--firmware/target/coldfire/iaudio/x5/backlight-x5.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/firmware/target/coldfire/iaudio/x5/backlight-x5.c b/firmware/target/coldfire/iaudio/x5/backlight-x5.c
index 667f4e7278..ebb28fbf2b 100644
--- a/firmware/target/coldfire/iaudio/x5/backlight-x5.c
+++ b/firmware/target/coldfire/iaudio/x5/backlight-x5.c
@@ -36,7 +36,9 @@ void _backlight_on(void)
36{ 36{
37 int level; 37 int level;
38 lcd_enable(true); 38 lcd_enable(true);
39#ifndef BOOTLOADER
39 _lcd_sleep_timer = 0; /* LCD should be awake already */ 40 _lcd_sleep_timer = 0; /* LCD should be awake already */
41#endif
40 level = set_irq_level(HIGHEST_IRQ_LEVEL); 42 level = set_irq_level(HIGHEST_IRQ_LEVEL);
41 pcf50606_write(0x38, 0xb0); /* Backlight ON, GPO1INV=1, GPO1ACT=011 */ 43 pcf50606_write(0x38, 0xb0); /* Backlight ON, GPO1INV=1, GPO1ACT=011 */
42 set_irq_level(level); 44 set_irq_level(level);
@@ -48,6 +50,7 @@ void _backlight_off(void)
48 pcf50606_write(0x38, 0x80); /* Backlight OFF, GPO1INV=1, GPO1ACT=000 */ 50 pcf50606_write(0x38, 0x80); /* Backlight OFF, GPO1INV=1, GPO1ACT=000 */
49 set_irq_level(level); 51 set_irq_level(level);
50 lcd_enable(false); 52 lcd_enable(false);
53#ifndef BOOTLOADER
51 /* Start LCD sleep countdown */ 54 /* Start LCD sleep countdown */
52 if (_lcd_sleep_timeout < 0) 55 if (_lcd_sleep_timeout < 0)
53 { 56 {
@@ -56,6 +59,7 @@ void _backlight_off(void)
56 } 59 }
57 else 60 else
58 _lcd_sleep_timer = _lcd_sleep_timeout; 61 _lcd_sleep_timer = _lcd_sleep_timeout;
62#endif
59} 63}
60 64
61/* set brightness by changing the PWM */ 65/* set brightness by changing the PWM */