]> www.fi.muni.cz Git - bike-lights.git/commitdiff
control.c: brighter lights in ambient zone 0
authorJan "Yenya" Kasprzak <kas@fi.muni.cz>
Thu, 18 Jul 2013 20:12:20 +0000 (22:12 +0200)
committerJan "Yenya" Kasprzak <kas@fi.muni.cz>
Thu, 18 Jul 2013 20:12:20 +0000 (22:12 +0200)
firmware/control.c

index d8cd698fb0a11f2a8f158b08fb377be97e6a7cc2..c351ca80b0fef5a386ce493a866dc65c98a0bb70 100644 (file)
@@ -185,7 +185,12 @@ void pwmled_select_brightness()
 
        if (battery_critical) {
                brightness = PWMLED_BRIGHTNESS(0, 0, 0, 0, 0);
-       } else if (ambient_zone < 2) {
+       } else if (ambient_zone == 0) {
+               if (dim_mode)
+                       brightness = PWMLED_BRIGHTNESS(0, 1, 0, 0, 1);
+               else
+                       brightness = PWMLED_BRIGHTNESS(1, 3, 2, 1, 3);
+       } else if (ambient_zone == 1) {
                if (dim_mode)
                        brightness = PWMLED_BRIGHTNESS(0, 1, 0, 0, 1);
                else