mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-11 18:35:28 +00:00
1dce89f8b40349ec4c76e62a7a0d3164d6ec113a
last_collection is used for sensor in forced mode to be sure we are not
calling the read routine too often. We should update last_collection even
when the reading fails, and not on the interrupt path.
For sensors that support interrupt, the new timing diagram is:
/-------- data rate period ---------\
--------------+------------------------------------+-----------------> t
| /\
read (sample request) |
| Interrupt (sample available)
\/ |
sensor
BUG=chrome-os-partner:59423
BRANCH=reef
TEST=Check the ALS read is not called too often even when the sensor
reports an error because the read value is not changed.
Change-Id: I2def7bbd5227cf373c1f613c9b70bc6215861008
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/424222
Reviewed-by: Randall Spangler <rspangler@chromium.org>
For an overview of the Embedded Controller firmware, refer to http://www.chromium.org/chromium-os/2014-firmware-summit For instructions on building from source, refer to http://www.chromium.org/chromium-os/ec-development/getting-started-building-ec-images-quickly
Description
Languages
C
64.7%
Lasso
20.7%
ASL
3.6%
JavaScript
3.2%
C#
2.9%
Other
4.6%