Fix blue light sticking and fixed delays
authorXpLoDWilD <xplodgui@gmail.com>
Thu, 14 Jun 2012 17:48:19 +0000 (19:48 +0200)
committerXpLoDWilD <xplodgui@gmail.com>
Thu, 14 Jun 2012 17:55:39 +0000 (19:55 +0200)
Change-Id: I1a9a92eaaf09f6a5524e0d08b4fdefa2b7ba000d

exynos4/exynos4x12/liblights/lights.c

index b59f8ec34ffe20d06efd7fc88a98b872097d5e1b..ba0f0fcd140f2c8cfa8a0fec1271b49df5d0a3c2 100644 (file)
@@ -169,14 +169,14 @@ static int set_light_leds(struct light_state_t const *state, int type)
             led.red = 0;
             led.green = 0;
             led.blue = 0;
-            snprintf(led.blink, MAX_WRITE_CMD, "0x00 0 0");
+            snprintf(led.blink, MAX_WRITE_CMD, "0x000000 0 0");
         break;
     case LIGHT_FLASH_TIMED:
     case LIGHT_FLASH_HARDWARE:
             led.red = (colorRGB >> 16) & 0xFF;
             led.green = (colorRGB >> 8) & 0xFF;
             led.blue = colorRGB & 0xFF;
-            snprintf(led.blink, MAX_WRITE_CMD, "0xFF 80 2000");
+            snprintf(led.blink, MAX_WRITE_CMD, "0x%x %d %d", colorRGB, state->flashOnMS, state->flashOffMS);
         break;
     default:
         return -EINVAL;