Add WS2812 status module and config
This commit is contained in:
20
main/ws2812_status.h
Normal file
20
main/ws2812_status.h
Normal file
@@ -0,0 +1,20 @@
|
||||
#pragma once
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stddef.h>
|
||||
|
||||
#include "esp_err.h"
|
||||
#include "sdkconfig.h"
|
||||
|
||||
#ifndef CONFIG_WATCH_WS2812_LED_COUNT
|
||||
#define CONFIG_WATCH_WS2812_LED_COUNT 5
|
||||
#endif
|
||||
|
||||
#define WS2812_STATUS_LED_COUNT CONFIG_WATCH_WS2812_LED_COUNT
|
||||
|
||||
esp_err_t ws2812_status_init(void);
|
||||
esp_err_t ws2812_status_set_channel_state(size_t channel, bool enabled);
|
||||
esp_err_t ws2812_status_mark_active(size_t channel);
|
||||
esp_err_t ws2812_status_clear_active(void);
|
||||
esp_err_t ws2812_status_set_error(bool has_error);
|
||||
esp_err_t ws2812_status_refresh_from_dcdc(void);
|
||||
Reference in New Issue
Block a user