diff options
author | Bill Richardson <wfrichar@chromium.org> | 2012-08-20 12:47:32 -0700 |
---|---|---|
committer | Gerrit <chrome-bot@google.com> | 2012-08-20 15:44:50 -0700 |
commit | ede77d7cac6a9730f706cb110da414748b45379e (patch) | |
tree | 75b1fb4650154518798a615835fc0bbfe8775113 /include/lightbar.h | |
parent | f229fabd8be499b45fbb801b1458f3dd2c58bd32 (diff) | |
download | chrome-ec-ede77d7cac6a9730f706cb110da414748b45379e.tar.gz |
Add "lightbar demo" mode for executive bikeshedding
I keep getting asked to build an EC image to manually control the lightbar
patterns so that the Powers That Be can look at it. This change just makes
it possible to turn that mode on and off for yourself. You'll need a root
shell or the EC console to do it, though.
BUG=chrome-os-partner:8039
BRANCH=link
TEST=manual
From the EC console, type
lightbar demo 1
OR from the root shell run
ectool lightbar demo 1
After that, these keys should change the lightbar appearance (transitions
may be slow and subtle - that's intended):
UP = battery is more fully charged
DOWN = battery is less fully charged
RIGHT = battery is charging
LEFT = battery is discharging
BRIGHT = increase lightbar brightness
DIM = decrase lightbar brightness
Note that this does not interfere with the normal function of any keys. It
only adds some additional EC behavior.
Change-Id: Ia1a9855188244d74b670f9dbfdf60e3ac0343460
Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/30899
Diffstat (limited to 'include/lightbar.h')
-rw-r--r-- | include/lightbar.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/lightbar.h b/include/lightbar.h index 395166191d..ea48314904 100644 --- a/include/lightbar.h +++ b/include/lightbar.h @@ -36,7 +36,13 @@ enum lightbar_command { LIGHTBAR_CMD_REG, LIGHTBAR_CMD_RGB, LIGHTBAR_CMD_GET_SEQ, + LIGHTBAR_CMD_DEMO, LIGHTBAR_NUM_CMDS }; +/* These are used for demo purposes */ +extern void demo_battery_level(int inc); +extern void demo_is_charging(int ischarge); +extern void demo_brightness(int inc); + #endif /* __CROS_EC_LIGHTBAR_H */ |