Add COSPAD to QMK and add functions to read HSV (#2156)

* Added functions to read HSV values

I have added three functions to rgb_light.c to be able to read the hue, saturation and value from other places.
They are rgblight_get_hue(), rgblight_get_sat(), adn rgblight_get_val().

* Create keymap.c

* Add COSPAD support to QMK

I have ported the COSPAD numpad to qmk.

* Update readme.md

* Update cospad.c
This commit is contained in:
kamisamamizu 2017-12-17 17:44:13 +01:00 committed by Jack Humbert
parent d91c9858c5
commit 12e66330c5
8 changed files with 401 additions and 0 deletions

View file

@ -370,6 +370,18 @@ void rgblight_sethsv(uint16_t hue, uint8_t sat, uint8_t val) {
}
}
uint16_t rgblight_get_hue(void) {
return rgblight_config.hue;
}
uint8_t rgblight_get_sat(void) {
return rgblight_config.sat;
}
uint8_t rgblight_get_val(void) {
return rgblight_config.val;
}
void rgblight_setrgb(uint8_t r, uint8_t g, uint8_t b) {
if (!rgblight_config.enable) { return; }