16 namespace duds {
namespace hardware {
namespace devices {
namespace instruments {
28 std::unique_ptr<duds::hardware::interface::I2c>
com;
55 ISL29125(std::unique_ptr<duds::hardware::interface::I2c> &c);
65 void init(
bool wide =
true);
87 std::uint16_t
red()
const {
93 std::uint16_t
blue()
const {
100 #endif // #ifndef ISL29125_HPP void init(bool wide=true)
Configures for continuous 16-bit sampling of all colors.
std::unique_ptr< duds::hardware::interface::I2c > com
The I2C communication interface.
ISL29125(std::unique_ptr< duds::hardware::interface::I2c > &c)
Prepares to communicate with the device, but does not initalize the device.
~ISL29125()
Calls suspend().
duds::hardware::interface::Conversation initialize
Output used to initialize the device.
A quick try at supporting ISL29125 RGB sensor; will change significantly in the future.
void suspend()
Suspends operation by putting the device into a low-power mode.
std::uint16_t b
Blue brightness.
std::uint16_t red() const
std::uint16_t g
Green brightness.
std::uint16_t blue() const
Header for Conversarion; includes ConversationVector.hpp and ConversationExternal.hpp.
void sample()
The device takes about 101ms to produce a 16-bit sample per color.
std::uint16_t r
Red brightness.
void resume()
Resumes operation after a call to suspend().
std::uint16_t green() const
duds::hardware::interface::Conversation input
Used to read in the sampled data.
Represents a two-way conversation with a device.