Skip to content

Commit 0b89351

Browse files
committed
feat(led_indicator): Update docs, examples and standardize comments
1 parent a1760b8 commit 0b89351

File tree

17 files changed

+38
-66
lines changed

17 files changed

+38
-66
lines changed

components/led/led_indicator/include/led_custom.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ typedef struct {
3434
/**
3535
* @brief Create a new custom LED indicator device.
3636
*
37-
* This function initializes a new LED indicator device using the provided LED configuration
38-
* and custom configuration parameters.
3937
*
4038
* @param led_config Pointer to the LED configuration structure.
4139
* @param custom_cfg Pointer to the custom configuration structure for the LED indicator.

components/led/led_indicator/include/led_gpio.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,6 @@ esp_err_t led_indicator_gpio_set_on_off(void *handle, bool on_off);
5858
/**
5959
* @brief Create a new LED indicator device using a GPIO pin.
6060
*
61-
* This function initializes a new LED indicator device based on the provided LED configuration
62-
* and GPIO configuration. It returns a handle to the created LED indicator device, which can be
63-
* used for further control and management.
6461
*
6562
* @param led_config Pointer to the LED configuration structure.
6663
* @param gpio_cfg Pointer to the GPIO configuration structure for the LED.

components/led/led_indicator/include/led_ledc.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,6 @@ esp_err_t led_indicator_ledc_set_brightness(void *ledc_handle, uint32_t brightne
6969
/**
7070
* @brief Create a new LED indicator device using the LEDC (LED Controller) peripheral.
7171
*
72-
* This function initializes a new LED indicator device with the specified configuration,
73-
* utilizing the ESP32's LEDC hardware for PWM control.
7472
*
7573
* @param led_config Pointer to the general LED configuration structure.
7674
* @param ledc_cfg Pointer to the LEDC-specific configuration structure.

components/led/led_indicator/include/led_rgb.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,6 @@ esp_err_t led_indicator_rgb_set_brightness(void *rgb_handle, uint32_t brightness
101101
/**
102102
* @brief Create a new RGB LED device instance.
103103
*
104-
* This function initializes a new RGB LED device using the specified LED configuration
105-
* and RGB-specific configuration parameters.
106104
*
107105
* @param led_config Pointer to the general LED configuration structure.
108106
* @param rgb_cfg Pointer to the RGB-specific configuration structure.

components/led/led_indicator/include/led_strips.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,8 +111,6 @@ esp_err_t led_indicator_strips_set_brightness(void *strips, uint32_t ibrightness
111111
/**
112112
* @brief Create a new LED indicator device using LED strips.
113113
*
114-
* This function initializes and returns a handle to a new LED indicator device
115-
* based on the provided LED configuration and LED strips configuration.
116114
*
117115
* @param led_config Pointer to the LED configuration structure.
118116
* @param strips_cfg Pointer to the LED strips specific configuration structure.

components/led/led_indicator/src/led_custom.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ led_indicator_handle_t iot_led_new_custom_device(const led_config_t *led_config,
1414
bool if_blink_default_list = false;
1515

1616
ESP_LOGI(TAG, "LED Indicator Version: %d.%d.%d", LED_INDICATOR_VER_MAJOR, LED_INDICATOR_VER_MINOR, LED_INDICATOR_VER_PATCH);
17-
LED_INDICATOR_CHECK(led_config != NULL, "invalid config pointer", return NULL);
1817
LED_INDICATOR_CHECK(custom_cfg != NULL, "invalid config pointer", return NULL);
1918
_led_indicator_com_config_t com_cfg = {0};
2019
_led_indicator_t *p_led_indicator = NULL;

components/led/led_indicator/src/led_gpio.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@ led_indicator_handle_t iot_led_new_gpio_device(const led_config_t *led_config, c
7777
bool if_blink_default_list = false;
7878

7979
ESP_LOGI(TAG, "LED Indicator Version: %d.%d.%d", LED_INDICATOR_VER_MAJOR, LED_INDICATOR_VER_MINOR, LED_INDICATOR_VER_PATCH);
80-
LED_INDICATOR_CHECK(led_config != NULL, "invalid config pointer", return NULL);
8180
LED_INDICATOR_CHECK(gpio_cfg != NULL, "invalid config pointer", return NULL);
8281
_led_indicator_com_config_t com_cfg = {0};
8382
_led_indicator_t *p_led_indicator = NULL;

components/led/led_indicator/src/led_ledc.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,6 @@ led_indicator_handle_t iot_led_new_ledc_device(const led_config_t *led_config, c
124124
bool if_blink_default_list = false;
125125

126126
ESP_LOGI(TAG, "LED Indicator Version: %d.%d.%d", LED_INDICATOR_VER_MAJOR, LED_INDICATOR_VER_MINOR, LED_INDICATOR_VER_PATCH);
127-
LED_INDICATOR_CHECK(led_config != NULL, "invalid config pointer", return NULL);
128127
LED_INDICATOR_CHECK(ledc_cfg != NULL, "invalid config pointer", return NULL);
129128
_led_indicator_com_config_t com_cfg = {0};
130129
_led_indicator_t *p_led_indicator = NULL;

components/led/led_indicator/src/led_rgb.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,6 @@ led_indicator_handle_t iot_led_new_rgb_device(const led_config_t *led_config, co
165165
bool if_blink_default_list = false;
166166

167167
ESP_LOGI(TAG, "LED Indicator Version: %d.%d.%d", LED_INDICATOR_VER_MAJOR, LED_INDICATOR_VER_MINOR, LED_INDICATOR_VER_PATCH);
168-
LED_INDICATOR_CHECK(led_config != NULL, "invalid config pointer", return NULL);
169168
LED_INDICATOR_CHECK(rgb_cfg != NULL, "invalid config pointer", return NULL);
170169
_led_indicator_com_config_t com_cfg = {0};
171170
_led_indicator_t *p_led_indicator = NULL;

components/led/led_indicator/src/led_strips.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,6 @@ led_indicator_handle_t iot_led_new_strips_device(const led_config_t *led_config,
196196
bool if_blink_default_list = false;
197197

198198
ESP_LOGI(TAG, "LED Indicator Version: %d.%d.%d", LED_INDICATOR_VER_MAJOR, LED_INDICATOR_VER_MINOR, LED_INDICATOR_VER_PATCH);
199-
LED_INDICATOR_CHECK(led_config != NULL, "invalid config pointer", return NULL);
200199
LED_INDICATOR_CHECK(strips_cfg != NULL, "invalid config pointer", return NULL);
201200
_led_indicator_com_config_t com_cfg = {0};
202201
_led_indicator_t *p_led_indicator = NULL;

0 commit comments

Comments
 (0)