From f32e4de84bc1fefac5528644a0c6d3cba8d98ff4 Mon Sep 17 00:00:00 2001 From: Wizmo2 Date: Sat, 16 Sep 2023 16:45:43 -0400 Subject: [PATCH] static declaration in function --- components/led_strip/led_vu.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/components/led_strip/led_vu.c b/components/led_strip/led_vu.c index f18f0738..3257551d 100644 --- a/components/led_strip/led_vu.c +++ b/components/led_strip/led_vu.c @@ -39,10 +39,6 @@ static const char *TAG = "led_vu"; #define max(a,b) (((a) > (b)) ? (a) : (b)) struct led_strip_t* led_display = NULL; -static EXT_RAM_ATTR struct led_strip_t led_strip_config = { - .rgb_led_type = RGB_LED_TYPE_WS2812, - .gpio = -1, -}; static EXT_RAM_ATTR struct { int gpio; @@ -94,6 +90,7 @@ void led_vu_init() strip.vu_odd = strip.length - 1; // create driver configuration + static struct led_strip_t led_strip_config = { .rgb_led_type = RGB_LED_TYPE_WS2812}; led_strip_config.access_semaphore = xSemaphoreCreateBinary(); led_strip_config.led_strip_length = strip.length; led_strip_config.led_strip_working = heap_caps_malloc(strip.length * sizeof(struct led_color_t), MALLOC_CAP_8BIT);