upm  0.1.8
Sensor/Actuator repository for libmraa (v0.4.5)
 All Data Structures Files Functions Variables Macros Pages
Public Member Functions
GroveLight Class Reference

C++ API for Grove light sensor. More...

Detailed Description

Very basic UPM module for grove Light sensor on analog

int lightValue = light->value();
delete light;

Public Member Functions

 GroveLight (unsigned int pin)
 
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
 

Member Function Documentation

float raw_value ( )

Get raw value from AIO pin

Returns
the raw value from the ADC
int value ( )

Get the light value from the sensor

Returns
the normalised light reading
Inheritance diagram for GroveLight:
Inheritance graph
[legend]
Collaboration diagram for GroveLight:
Collaboration graph
[legend]

The documentation for this class was generated from the following files: