mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-07-02 22:18:56 -07:00
Cleanup and fixes
This commit is contained in:
@@ -53,12 +53,7 @@ static struct {
|
||||
.last_brightness = 0,
|
||||
.last_color = {0, 0, 0},
|
||||
.rainbow_timer = NULL,
|
||||
.rainbow_hsv =
|
||||
{
|
||||
.h = 0,
|
||||
.s = 255,
|
||||
.v = 255,
|
||||
},
|
||||
.rainbow_hsv = {0, 255, 255},
|
||||
};
|
||||
|
||||
static void rainbow_timer(void* ctx) {
|
||||
|
||||
@@ -2,11 +2,11 @@
|
||||
|
||||
#include "colors.h"
|
||||
|
||||
inline int rgbcmp(RgbColor* a, RgbColor* b) {
|
||||
inline int rgbcmp(const RgbColor* a, const RgbColor* b) {
|
||||
return memcmp(a, b, sizeof(RgbColor));
|
||||
}
|
||||
|
||||
inline int hsvcmp(HsvColor* a, HsvColor* b) {
|
||||
inline int hsvcmp(const HsvColor* a, const HsvColor* b) {
|
||||
return memcmp(a, b, sizeof(HsvColor));
|
||||
}
|
||||
|
||||
|
||||
@@ -19,9 +19,9 @@ typedef struct HsvColor {
|
||||
uint8_t v;
|
||||
} HsvColor;
|
||||
|
||||
int rgbcmp(RgbColor* a, RgbColor* b);
|
||||
int rgbcmp(const RgbColor* a, const RgbColor* b);
|
||||
|
||||
int hsvcmp(HsvColor* a, HsvColor* b);
|
||||
int hsvcmp(const HsvColor* a, const HsvColor* b);
|
||||
|
||||
RgbColor hsv2rgb(HsvColor hsv);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user