mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-09 09:01:35 +00:00
ryu: re-calibrate lightbar colors for device.
Signed-off-by: Todd Broch <tbroch@chromium.org> BRANCH=smaug BUG=chrome-os-partner:44029 TEST=manual, 1. Boot device into S0 2. From EC console lightbar ... 15 0f 06 16 0f 20 17 16 08 18 06 21 19 26 11 1a 1d 0b These values match requested values. Change-Id: Ib65044510ac24bd41d63586534685f995fcb131d Reviewed-on: https://chromium-review.googlesource.com/294840 Reviewed-by: Bill Richardson <wfrichar@chromium.org> Tested-by: Todd Broch <tbroch@chromium.org> Commit-Queue: Todd Broch <tbroch@chromium.org>
This commit is contained in:
committed by
ChromeOS Commit Bot
parent
60ddfc8310
commit
f0a1e5dfd1
@@ -143,7 +143,7 @@ static inline uint8_t controller_read(int ctrl_num, uint8_t reg)
|
||||
#define MAX_GREEN 0x30
|
||||
#define MAX_BLUE 0x67
|
||||
#endif
|
||||
#if defined(BOARD_SAMUS) || defined(BOARD_RYU)
|
||||
#if defined(BOARD_SAMUS)
|
||||
/* Samus uses completely different LEDs, so the numbers are different. The
|
||||
* Samus LEDs can handle much higher currents, but these constants were
|
||||
* calibrated to provide uniform intensity at the level used by Link.
|
||||
@@ -152,6 +152,11 @@ static inline uint8_t controller_read(int ctrl_num, uint8_t reg)
|
||||
#define MAX_GREEN 0x2c
|
||||
#define MAX_BLUE 0x40
|
||||
#endif
|
||||
#if defined(BOARD_RYU)
|
||||
#define MAX_RED 0xb4
|
||||
#define MAX_GREEN 0xac
|
||||
#define MAX_BLUE 0xc0
|
||||
#endif
|
||||
#ifdef BOARD_HOST
|
||||
/* For testing only */
|
||||
#define MAX_RED 0xff
|
||||
|
||||
@@ -133,6 +133,12 @@ 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 */
|
||||
#else
|
||||
/*
|
||||
* These values have been optically calibrated for the
|
||||
* Samus LEDs to best match the official colors, described at
|
||||
@@ -143,6 +149,7 @@ static const struct lightbar_params_v1 default_params = {
|
||||
{0xbc, 0x50, 0x2c}, /* 1: Google red */
|
||||
{0xd0, 0xe0, 0x00}, /* 2: Google yellow */
|
||||
{0x50, 0xa0, 0x40}, /* 3: Google green */
|
||||
#endif
|
||||
/* These are primary colors */
|
||||
{0x00, 0x00, 0xff}, /* 4: full blue */
|
||||
{0xff, 0x00, 0x00}, /* 5: full red */
|
||||
|
||||
Reference in New Issue
Block a user