summaryrefslogtreecommitdiff
path: root/common/lightbar.c
diff options
context:
space:
mode:
authorAlec Berg <alecaberg@chromium.org>2015-09-24 15:55:45 -0700
committerchrome-bot <chrome-bot@chromium.org>2015-09-25 09:13:34 -0700
commite5ec074dfafd75bb8df093e920d5bc47eff2b108 (patch)
tree672a0d401c295b7ed7b5550008844069ced4054d /common/lightbar.c
parentf4ef486fc21a655b75c928ed719d366c6e95a2d4 (diff)
downloadchrome-ec-e5ec074dfafd75bb8df093e920d5bc47eff2b108.tar.gz
ryu: fix max lightbar brightness
Fix max brightness for Ryu. The max brightness must be less than 0x80 because the top bit in the lightbar current registers is reserved. Writing the top bit seems to have undefined behavior. This fixes the hiccups in the tap for battery sequence which was ramping brightness to above 0x80 and producing weird results. BUG=chrome-os-partner:45835, chrome-os-partner:44029 BRANCH=smaug TEST=test tap for battery looks smooth. test that the google colors match the desired current levels: > lightbar ... 15 0f 06 16 0f 20 17 16 08 18 06 21 19 26 11 1a 1d 0b Change-Id: Iecf1c770f986064b9b4d2d3d54fab0ea1242af01 Signed-off-by: Alec Berg <alecaberg@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/302146 Reviewed-by: Vincent Palatin <vpalatin@chromium.org> Commit-Queue: Vincent Palatin <vpalatin@chromium.org> (cherry picked from commit 133dab0c36160d0e54820cce9e97071df34340f8) Reviewed-on: https://chromium-review.googlesource.com/302446
Diffstat (limited to 'common/lightbar.c')
-rw-r--r--common/lightbar.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/lightbar.c b/common/lightbar.c
index b7f7bcf680..e0f5afccac 100644
--- a/common/lightbar.c
+++ b/common/lightbar.c
@@ -134,10 +134,10 @@ static const struct lightbar_params_v1 default_params = {
.s5_idx = 5, /* flash red */
.color = {
#if defined(BOARD_RYU)
- {0x22, 0x17, 0x3b}, /* Segment0: Google blue */
- {0x3e, 0x10, 0x0c}, /* Segment1: Google red */
- {0x48, 0x3a, 0x0c}, /* Segment2: Google yellow */
- {0x1e, 0x2c, 0x1c}, /* Segment3: Google green */
+ {0x74, 0x58, 0xb4}, /* Segment0: Google blue */
+ {0xd6, 0x40, 0x20}, /* Segment1: Google red */
+ {0xfa, 0xe6, 0x20}, /* Segment2: Google yellow */
+ {0x66, 0xb0, 0x50}, /* Segment3: Google green */
#else
/*
* These values have been optically calibrated for the