diff options
author | Travis Geiselbrecht <travisg@google.com> | 2012-06-25 13:19:37 -0700 |
---|---|---|
committer | Travis Geiselbrecht <travisg@google.com> | 2012-06-26 07:30:07 -0700 |
commit | 07f68d3d5d754c67198927c8da959aab18b5c09b (patch) | |
tree | 4845a152e9493f8aad1d03b7e72c496aa5e4ea49 | |
parent | dde6709434e5a379e5c923bd250c2cab46884695 (diff) | |
download | adk2012_demo-07f68d3d5d754c67198927c8da959aab18b5c09b.tar.gz |
fix slider bug + app problem
When the device is in the brightness panel, the slider value would tend
to override what is sent down by the app.
-rw-r--r-- | library/ADK2/examples/clock/clock.ino | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/library/ADK2/examples/clock/clock.ino b/library/ADK2/examples/clock/clock.ino index 909c72a..bc16a66 100644 --- a/library/ADK2/examples/clock/clock.ino +++ b/library/ADK2/examples/clock/clock.ino @@ -804,8 +804,8 @@ void loop(void) L.ledWrite(2, 0, 0, 0); slider = L.capSenseSlider(); + slider = ((((uint32_t)slider) * 191) >> 8) + 64; if(slider != briSlider){ - slider = ((((uint32_t)slider) * 191) >> 8) + 64; briSlider = slider; settings.bri = slider; } |