options to access the Pocuter light sensor
More...
#include <PocuterLightSensor.h>
options to access the Pocuter light sensor
◆ lightEventHandler
| typedef void() PocuterLightSensor::lightEventHandler(LIGHTEVENT, void *) |
◆ LIGHTERROR
| Enumerator |
|---|
| LIGHTERROR_OK | |
| LIGHTERROR_UNKNOWN | |
◆ LIGHTEVENT
| Enumerator |
|---|
| LIGHT_ABOVE_LIMIT | |
| LIGHT_UNDER_LIMIT | |
| LIGHT_TOLLERANCE_CHANGED | |
◆ getValue()
| virtual uint16_t PocuterLightSensor::getValue |
( |
| ) |
|
|
pure virtual |
poll the light value
- Returns
- current light value
◆ registerEventHandler()
register an event callback
- Note
- the event handler is called every time a limit has been under or exceeded
- Parameters
-
| h | a pointer to the callback function |
| limit | the limit to call the eventhandler |
| tollerance | a tollerance for debouncing event handler requests. |
| u | a pointer to user data |
- Returns
- LIGHTERROR_OK
◆ unregisterEventHandler()
| virtual void PocuterLightSensor::unregisterEventHandler |
( |
| ) |
|
|
pure virtual |
unregister the event handler
The documentation for this class was generated from the following file: