Rockbox

  • Status Closed
  • Percent Complete
    100%
  • Task Type Patches
  • Category LCD
  • Assigned To No-one
  • Operating System Sansa e200
  • Severity Low
  • Priority Very Low
  • Reported Version Daily build (which?)
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by PhilippeLatulippe - 2009-02-06
Last edited by bluebrother - 2011-06-05

FS#9874 - sansa - Make lcd_sleep work

This patch allows “Sleep (After Backlight Off)” to work on sansa e200 targets. A change made in revision 13250, during the early days of Sansa development, prevented it from working by automatically turning off the LCD controller in conjunction with the backlight (to save power.)

This patch simply removes the line that turns the LCD controller off, and lets the newer LCD sleep timer to do its job. I’ve kept the call to turn it back on just in case. Wouldn’t want to accidentally keep the LCD controller turned off. It shouldn’t have any negative effect, as lcd_enable(true) immediately returns if the LCD is already powered.

I tested it on my sansa e250, but a simple change like this should work on all Sansa e200 & c200

Closed by  bluebrother
2011-06-05 09:35
Reason for closing:  Out of Date
Additional comments about closing:   Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407

"Sleep (After Backlight Off)" works on the e200 these days.

Just to be clear, you mean that presently we turn off the back light but not the LCD controller? Do you know how much this patch improves battery life?

The opposite actually. Currently when the backlight is turned off, so is the LCD controller. However, this is done in _backlight_off(), which shouldn’t be turning off the LCD controller, as it is already implemented in a non-target-specific part of the code.
Because backlight-c200_e200.c always turns off the LCD controller, it breaks the ability for the user to chose how long to wait before turning off the LCD controller.
So:
1. User sets backlight to turn off after 5 seconds of inactivity.
2. User sets LCD controller to sleep 5 seconds after backlight turns off.
5 seconds later:
4. The (non-target-specific) countdown timer calls the (target-specific) method to turn off the backlight.
5. On Sansa, the method to turn off the backlight also turns off the LCD controller.
Both the backlight and LCD are turned off.
5 seconds later:
6. The LCD sleep timer attempts to turn off the LCD controller. Nothing actually happens, as it has already been turned off previously!

The reason I actually care about this is because keeping the LCD on after the backlight shuts off allows me to read the screen when I’m outside and the sun illuminates the screen.

See some of the discussion in  FS#9890 . There it was decided that HAVE_LCD_ENABLE shouldn’t be defined if the LCD isn’t turned off with the backlight.
Is the Sansa LCD usable without the backlight?

Yes, it’s usable in direct sunlight, which is quite useful for me. I’m not completely certain what  FS#9890  would entail for my patch, as I only read part of it (the parts relevant to me are padded by a sea of battery benchmarks and unrelated problems), but I do beleive my patch is still valid. I don’t think the LCD controller should be shutdown in the target-specific _backlight_off(), as it is already done in non-target-specific code (even if taking  FS#9890  into consideration), and also renders the “Sleep (After Backlight Off)” option useless.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing