This commit is contained in:
zvecr
2022-09-29 23:44:19 +01:00
parent 76a45a4e24
commit 1dbb4c0f96
12 changed files with 359 additions and 8 deletions
+4
View File
@@ -28,6 +28,10 @@ bool get_config_blob_chunk(uint16_t offset, uint8_t *data, uint8_t data_len) {
return true;
}
// TODO: return actual values
#define ENABLED_RGBLIGHT_EFFECTS 0xFFFFFFFF
#define ENABLED_RGB_MATRIX_EFFECTS 0xFFFFFFFF
#define QSTR2(z) #z
#define QSTR(z) QSTR2(z)
+17
View File
@@ -181,3 +181,20 @@ bool xap_respond_dynamic_encoder_set_keycode(xap_token_t token, const void *data
return true;
}
#endif
#if ((defined(RGBLIGHT_ENABLE)))
extern rgblight_config_t rgblight_config;
bool xap_respond_get_rgblight_config(xap_token_t token, const void *data, size_t length) {
xap_route_lighting_rgblight_get_config_t ret;
ret.enable = rgblight_config.enable;
ret.mode = rgblight_config.mode;
ret.hue = rgblight_config.hue;
ret.sat = rgblight_config.sat;
ret.val = rgblight_config.val;
ret.speed = rgblight_config.speed;
return xap_respond_data(token, &ret, sizeof(ret));
}
#endif