Dezibot 4
ColorDetection.h
Go to the documentation of this file.
1 
15 #ifndef ColorDetection_h
16 #define ColorDetection_h
17 
18 #include <stdint.h>
19 #include <Wire.h>
20 #include <Arduino.h>
21 #include <veml6040.h>
22 
23 enum duration {
29  MS1280
30 };
31 
32 enum vemlMode {
34  MANUAL
35 };
36 
37 struct VEML_CONFIG {
38  // force mode
40 
41  // chip shutdown setting
42  bool enabled;
43 
44  // integration time
46 };
47 
48 enum color {
53 };
54 
56 public:
61  void beginAutoMode();
62 
68  void configure(VEML_CONFIG config);
69 
76  uint16_t getColorValue(color color);
77 
83  float getAmbientLight();
84 
85 protected:
86  VEML6040 rgbwSensor;
87 };
88 #endif //ColorDetection_h
color
@ VEML_GREEN
@ VEML_RED
@ VEML_BLUE
@ VEML_WHITE
duration
@ MS320
@ MS160
@ MS1280
@ MS40
@ MS80
@ MS640
vemlMode
@ MANUAL
@ AUTO
VEML6040 rgbwSensor
uint16_t getColorValue(color color)
Get color value of RGBW sensor.
float getAmbientLight()
Get the ambient light in lux.
void configure(VEML_CONFIG config)
Begin RGBW sensor with passed configuration values.
void beginAutoMode()
Start RBGW sensor with default configuration.
duration exposureTime
vemlMode mode