View Single Post
Old 04-15-2014, 01:41 PM   #14
arcadesdude
Lexically Impaired
arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.arcadesdude ought to be getting tired of karma fortunes by now.
 
arcadesdude's Avatar
 
Posts: 28
Karma: 200518
Join Date: May 2008
Device: PW2
Cool

The only improvement I could suggest at this point would be reguarding this line of code in frontlightmaster.sh:

Code:
lipc-wait-event -s $MINIMUMBRIGHTNESSONSTARTTIME com.lab126.powerd goingToScreenSaver || true
which is after awakening from SS mode to and setting the minimum brightness.

If I'm correct, then that line of code waits until the $MINIMUMBRIGHTNESSONSTARTTIME has elapsed before continuing to process the next line of code. This means if the brightness is changed during that $MINIMUMBRIGHTNESSONSTARTTIME (10 seconds say) then there isn't any way of knowing if the brightness slider was changed and then set back to the $MINIMUMBRIGHTNESSONSTART level. So if you have the light off, and min brightness set to 5, when you turn it on the PW2 will be at brightness level 5 for 10 seconds during which if you increase and then decrease the brightness + 1 - 1 so it remains at 5 (or whatever $MINIMUMBRIGHTNESSONSTART is set to) then the light would go off since it didn't detect a change in brightness (manually changing the slider).

If that line of code was a do while loop of some sort that executed for $MINIMUMBRIGHTNESSONSTARTTIME then it could detect current brightness being different from $MINIMUMBRIGHTNESSONSTART at any point within the 10 seconds (MINIMUMBRIGHTNESSONSTARTTIME) and then chose not to reset the light to the former saved off value (off in my example above).

Any ideas on the above?
arcadesdude is offline   Reply With Quote