Add RGB light as a device.
This commit is contained in:
@@ -10,5 +10,17 @@
|
||||
#include <stdbool.h>
|
||||
#include <esp_err.h>
|
||||
|
||||
#define RGB_POWER_DEFAULT false
|
||||
#define RGB_HUE_DEFAULT 180
|
||||
#define RGB_SATURATION_DEFAULT 100
|
||||
#define RGB_BRIGHTNESS_DEFAULT 25
|
||||
|
||||
extern esp_rmaker_device_t *light_device;
|
||||
|
||||
void app_driver_init(void);
|
||||
esp_err_t app_driver_set_gpio(const char *name, bool state);
|
||||
esp_err_t app_light_set(uint32_t hue, uint32_t saturation, uint32_t brightness);
|
||||
esp_err_t app_light_set_power(bool power);
|
||||
esp_err_t app_light_set_brightness(uint16_t brightness);
|
||||
esp_err_t app_light_set_hue(uint16_t hue);
|
||||
esp_err_t app_light_set_saturation(uint16_t saturation);
|
||||
Reference in New Issue
Block a user