|
upm
0.3.1
Sensor/Actuator repository for libmraa (v0.7.2)
|
API for Grove light sensor. More...
The Grove light sensor detects the intensity of the ambient light. As the light intensity of the environment increases, the resistance of the sensor decreases. This means that the raw value from the analog pin will be larger in bright light and smaller in the dark. An approximate lux value can also be returned.
Public Member Functions | |
| GroveLight (unsigned int pin) | |
| ~GroveLight () | |
| float | raw_value () |
| int | value () |
Public Member Functions inherited from Grove | |
| std::string | name () |
Additional Inherited Members | |
Protected Attributes inherited from Grove | |
| std::string | m_name |
| GroveLight | ( | unsigned int | pin | ) |
Grove analog light sensor constructor
| pin | analog pin to use |
| ~GroveLight | ( | ) |
GroveLight Destructor
| float raw_value | ( | ) |
Get raw value from AIO pin
| int value | ( | ) |
Get the approximate light value, in lux, from the sensor


1.8.9.1