commit | ba9dbf825c3dd58747f77b699ccbee8489257a9e | [log] [tgz] |
---|---|---|
author | hscham <hscham@chromium.org> | Thu Mar 17 05:32:12 2022 |
committer | Copybara-Service <copybara-worker@google.com> | Thu Apr 07 09:50:42 2022 |
tree | d8078a3e7335d1c3c339a5a155463861b58b94c6 | |
parent | 69141d56e44d96f7298bc38a2e5dba1a82f204cc [diff] |
platform2: remove unused base/macro.h base/macros.h will be removed in r941411 (crrev.com/c/3279210). All usages of DISALLOW_* macros have been migrated to delete ctors and ignore_result to std::ignore so it is safe to remove the include. See LSC proposal: go/chromeos-lsc-libchrome-remove-base-macro BUG=b:211560276 TEST=CQ Change-Id: Ia8a34295fa11c7c2bc88f37394f8855c67dace80 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/3531653 Owners-Override: Dominick Ng <dominickn@google.com> Reviewed-by: Hidehiko Abe <hidehiko@chromium.org> Commit-Queue: Grace Cham <hscham@chromium.org> Tested-by: Grace Cham <hscham@chromium.org> NOKEYCHECK=True GitOrigin-RevId: 59189cee984506c11969e028f2a520fbecebbda6
Project goal and motivation
This library provides a set of wrapper and test helpers around libiio.
It is meant to provide a common foundation for Chrome OS to access and interface IIO sensors, with:
At the root of the hierarchy, there exists the IioContext
, which represents the IIO devices currently available on the system. These can be retrieved by name and inspected, via instances of IioDevice
.
An IioDevice
allows reading and writing attributes of an IIO device via type-safe helper APIs. It also offers support for configuring the buffer and trigger of an IIO device, which we use in order to allow the Chrome UI to read accelerometer data and support screen rotation.
An IioDevice
also exposes a list of IioChannel
s, which can individually be enabled and disabled.
Useful mocks for the core classes are provided, such that a test author can focus on the logic of the unit tests and share a common testing language with other engineers working in this space. Sharing the foundation of testing IIO sensor access helps ensure that any improvement in this area can benefit all clients.