Skip to content

Commit e42e72f

Browse files
committed
get_color
1 parent c7b8df2 commit e42e72f

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

src/Arduino_Alvik.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -574,6 +574,12 @@ uint8_t Arduino_Alvik::get_color_label(const float h, const float s, const float
574574
}
575575
}
576576

577+
uint8_t Arduino_Alvik::get_color_label(){
578+
float h,s,v;
579+
get_color(h, s, v, HSV);
580+
return get_color_label(h, s, v);
581+
}
582+
577583
void Arduino_Alvik::color_calibration(const uint8_t background){
578584
if ((background != BLACK)&&(background != WHITE)){
579585
return;

src/Arduino_Alvik.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ class Arduino_Alvik{
186186
void norm2hsv(const float r, const float g, const float b, float & h, float & s, float & v);
187187
void get_color(float & value0, float & value1, float & value2, const uint8_t format = RGB);
188188
uint8_t get_color_label(const float h, const float s, const float v);
189+
uint8_t get_color_label();
189190
void color_calibration(const uint8_t background = WHITE);
190191

191192
void get_orientation(float & roll, float & pitch, float & yaw);

0 commit comments

Comments
 (0)