logo elektroda
logo elektroda
X
logo elektroda

WS2812B LED not working with ESP32 CP2102 on GPIO2/5/13/35 – wiring or code issue?

cototo1991 3822 20
Best answers

Why won’t a WS2812B LED work with my ESP32 on GPIO2/5/13/35, and is the problem in the wiring, level shifting, or code?

Your setup ended up being a mix of code and hardware issues: after fixing the LED indexing in the code and using the level shifter correctly, the strip started working [#21624203][#21624307] The working FastLED test used `leds[0]`, not `leds[1]`, and `COLOR_ORDER` was `GRB` with the first LED toggled on the chosen GPIO [#21623929][#21624098][#21624307] The ESP32’s 3.3 V output can be marginal for WS2812B at 5 V because the logic-high level should be at least 0.7·Vdd, so the 74AHCT125 is a valid fix; alternatively, lowering LED supply to about 4.4 V can make 3.3 V logic work without a converter [#21622606][#21624440] The thread also suggests the “sacrificed” LED may have been damaged during probing, since touching the data pin with a meter caused random weak lighting and odd behavior [#21624028][#21624203][#21624440] Once the corrected code and shifter were in place, the LEDs worked, so the final diagnosis was not just wiring but also an indexing/code mistake and possibly a harmed LED [#21624307][#21624440]
Generated by the language model.
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #1 21622472
    cototo1991
    Level 3  
    Posts: 10
    Good,

    I started to make myself an "automatic vodka dispenser" and I have almost everything ready, only I have a problem with the leds (WS2812 Link to ali ), neither chinese nor american AI could help me so I decided to create an account here and ask, maybe someone will have an idea. I did something similar on tinkercad.com (the same leds I also tried on my esp32 cp2102). Exactly the same wired leds, the only difference is in esp I tried GPIO2, 5, 13 and 35 no and only one led and on tinkercad it works.... I tried through the capacitor and resistor alone, then through the 74AHCT125 hoping it would work but to no avail, the diode only lit up when I shorted the DIN to GND or when I quickly switched from gnd to din at the diode itself, the faster I did it the brighter it lit up (different colour but still) and I have no idea, maybe someone here can help 🤮.

    admittedly, the project works well without leds, but still, it would be nice if there was such a signalling...


    Wiring diagram of WS2812B LED strip to Arduino with 5V power, capacitor, and resistor .

    AI: How exactly do you power these leds? From what voltage, is the ground of the ESP32 and the leds definitely common, and do you power them directly from the ESP or from a separate power supply? .
    everything as in the picture
    AI: What code/library are you using to control these WS2812B? Can you throw in the code snippet you are trying to fire them with? .
    #include <Adafruit_NeoPixel.h>
    
    #define LED_PIN    2
    #define LED_COUNT  1
    
    Adafruit_NeoPixel strip(LED_COUNT, LED_PIN, NEO_GRB + NEO_KHZ800);
    
    void setup() {
      strip.begin();
      strip.show(); // Wyłącz wszystkie LED-y na start
      delay(1000);
    
      // Test kolorów po kolei
      strip.setPixelColor(0, strip.Color(255, 0, 0)); // Czerwony
      strip.show();
      delay(1000);
    
      strip.setPixelColor(0, strip.Color(0, 255, 0)); // Zielony
      strip.show();
      delay(1000);
    
      strip.setPixelColor(0, strip.Color(0, 0, 255)); // Niebieski
      strip.show();
      delay(1000);
    
      strip.setPixelColor(0, strip.Color(255, 255, 0)); // Żółty
      strip.show();
      delay(1000);
    
      strip.setPixelColor(0, strip.Color(0, 0, 0)); // Wyłącz
      strip.show();
    }
    
    void loop() {
    }
    
    LUB:
    #include <Adafruit_NeoPixel.h>
    
    #define LED_PIN 13
    #define LED_COUNT 1
    
    Adafruit_NeoPixel strip(LED_COUNT, LED_PIN, NEO_GRB + NEO_KHZ800);
    
    void setup() {
      Serial.begin(115200);
      strip.begin();
      strip.show(); // Wyłącz wszystkie LED
      delay(1000);
    
      strip.setPixelColor(0, strip.Color(255, 0, 0)); // Czerwony
      strip.show();
    }
    
    void loop() {}
    .
  • ADVERTISEMENT
  • #2 21622516
    tos18
    Level 42  
    Posts: 7022
    Help: 1089
    Rate: 1811
    I once wrote something like this on esp32 - it worked.

    In your program there is a definition
    Code: Arduino
    Log in, to see the code


    it means that you have a strip with one led !
    Enter there the number of leds in the bar
    Attachments:
    • neopixel32.rar (1.4 KB) You must be logged in to download this attachment.
  • ADVERTISEMENT
  • #3 21622564
    cototo1991
    Level 3  
    Posts: 10
    Thanks, I threw in, changed to 1 diode and a total of 3 different pins (2, 4 and 15) and also zero response, I switched everything on short (burble I know)
    Close-up of loosely connected wires, resistor, and jumper connectors on a work surface .
    The only response is when I unplug and plug it in again, it lights up very faintly, but that too is rare
    Close-up of LED strip connector with provisional wiring and labeled pins .
    I have checked other LEDs from the strip and they respond in the same way
  • #4 21622570
    tos18
    Level 42  
    Posts: 7022
    Help: 1089
    Rate: 1811
    Strange things a colleague is doing
    how many leds are there in the strip/circuit ?
    which gpio is the control pin connected to ?

    Don't connect in the middle of the circuit only at the beginning - hope you didn't damage the diode.
    The diodes are connected by a single wire data bus in series so you need to connect to the first diode in the circuit.
  • #5 21622584
    cototo1991
    Level 3  
    Posts: 10
    tos18 wrote:
    how many leds are all in the strip/circuit ?
    .
    There is one led on the strip I'm testing (I've cut it off), but overall there are 60 in 1m.
    tos18 wrote:
    Which gpio is the control pin connected to ?
    .
    Currently in GPIO4 (D4).
    tos18 wrote:
    Don't connect in the middle of the circuit just at the beginning - hope you didn't damage the diode.
    .
    So just put the resistor into the GPIO? I've already tried giving the resistor itself between D4 and DIN (without wires), but same thing.
    PS. I don't give to the contact board because I have all the other parts there, I just don't want to unplug it 🤐.
  • #6 21622606
    tos18
    Level 42  
    Posts: 7022
    Help: 1089
    Rate: 1811
    Maybe your LEDs don't want to work with 3.3V logic - my strip worked normally powered from 5V and controlled from the esp32 pin (logic3.3V) without a resistor.

    If you have an arduino uno or something else with 5V logic on hand then try it on that. Alternatively try with a 3.3V-5V converter
    or
    https://hackaday.com/2017/01/20/cheating-at-5v-ws2812-control-to-use-a-3-3v-data-line/
  • #7 21622608
    cototo1991
    Level 3  
    Posts: 10
    I also tried with something like this: 74AHCT125
    and I had it wired up like this, the effect was the same as without this 🤷‍♂️

    🟢 ESP32 (signal):
    GPIO5 (D5) → pin 1A (input) on 74AHCT125
    pin 1Y (output) → via 330 Ω resistor → DIN WS2812B

    🔴 Power supply to 74AHCT125:
    VCC (pin 14) → 5 V from LM2596
    GND (pin 7) → GND (common with ESP and LED)
    1OE (pin 1) → GND (to activate the 1A/1Y buffer)

    🟡 WS2812B power supply:
    VCC LED → 5 V from LM2596
    GND LED → GND common
    DIN LED → from 1Y 74AHCT125 via 330 Ω
  • #8 21622618
    tos18
    Level 42  
    Posts: 7022
    Help: 1089
    Rate: 1811
    Try using my program.
    is set to 30 led and gpio14
  • #9 21622621
    cototo1991
    Level 3  
    Posts: 10
    tos18 wrote:
    Try using my program.
    It is set to 30 LEDs and GPIO14
    .
    "Thanks, I've uploaded, changed to 1 LED and a total of 3 different pins (2, 4 and 15) and also zero response, I've switched everything on short (burble I know)" I've tried, I've switched myself to 1 LED and GPIO4 (then put it on 14) but I know it works for sure because on Tinkercad it worked. I'll check this "Cheating At 5V" and let you know.

    Unfortunately it didn't work either, now I tried it with the whole tape ....
    WS2812 LED module wired on a work mat with jumper cables .
  • ADVERTISEMENT
  • #10 21623040
    gps79
    Level 37  
    Posts: 2178
    Help: 494
    Rate: 779
    The pin numbers are not the same as their names in Arduino. You want to use D5, then declare it that way:
    Code: C / C++
    Log in, to see the code
    .
    If this is not enough, then reduce the data rate to the LEDs as follows:
    Code: C / C++
    Log in, to see the code
    .
    A series resistor on the data line is recommended. It must not have too high a value. 100-500Ohm should be OK.

    If this does not help, for analysis:
    1. send a clear photo of the microcontroller board so we know exactly what model you have.
    2. additionally, we don't know which platform (in Arduino) you are building your code from and which LED library you are using. Enable the Arduino IDE to print additional build and upload information:

    Arduino IDE settings window with “compile” and “upload” options checked .
    and paste us the build and upload log.
  • #11 21623261
    cototo1991
    Level 3  
    Posts: 10
    gps79 wrote:
    Pin numbers are not the same as their names in Arduino. You want to use D5, then declare it this way:
    Code: C / C++ Expand Select All Copy to clipboard#define LED_PIN D5
    .
    compiler doesn't move on because D is not valid
    gps79 wrote:
    1. send a clear photo of the microcontroller board so we know exactly what model you have.
    2. additionally, we don't know which platform (in Arduino) you are building your code from and which LED library you are using. Enable the Arduino IDE to print additional build and upload information:


    and paste the build and upload log for us.

    arduino-builder -dump-prefs -logger=machine -hardware /usr/share/arduino/hardware -hardware /home/darkmix/.arduino15/packages -tools /usr/share/arduino/hardware/tools/avr -tools /home/darkmix/.arduino15/packages -libraries /home/darkmix/Arduino/libraries -fqbn=esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=115200,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none,ZigbeeMode=default -vid-pid=10C4_EA60 -ide-version=10819 -build-path /tmp/arduino_build_385637 -warnings=none -build-cache /tmp/arduino_cache_950965 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.xtensa-esp-elf-gdb.path=/home/darkmix/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.xtensa-esp-elf-gdb-14.2_20240403.path=/home/darkmix/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.mkspiffs.path=/home/darkmix/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.mkspiffs-0.2.3.path=/home/darkmix/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.esp32-arduino-libs.path=/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1 -prefs=runtime.tools.esp32-arduino-libs-idf-release_v5.4-2f7dcd86-v1.path=/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1 -prefs=runtime.tools.riscv32-esp-elf-gdb.path=/home/darkmix/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.riscv32-esp-elf-gdb-14.2_20240403.path=/home/darkmix/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.esp-rv32.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-rv32/2411 -prefs=runtime.tools.esp-rv32-2411.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-rv32/2411 -prefs=runtime.tools.mklittlefs.path=/home/darkmix/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 -prefs=runtime.tools.mklittlefs-3.0.0-gnu12-dc7f933.path=/home/darkmix/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 -prefs=runtime.tools.esp-x32.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411 -prefs=runtime.tools.esp-x32-2411.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411 -prefs=runtime.tools.openocd-esp32.path=/home/darkmix/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20241016 -prefs=runtime.tools.openocd-esp32-v0.12.0-esp32-20241016.path=/home/darkmix/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20241016 -prefs=runtime.tools.esptool_py.path=/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3 -prefs=runtime.tools.esptool_py-4.9.dev3.path=/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3 -prefs=runtime.tools.dfu-util.path=/home/darkmix/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 -prefs=runtime.tools.dfu-util-0.11.0-arduino5.path=/home/darkmix/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 -verbose /tmp/arduino_modified_sketch_460535/strandtest.ino
    arduino-builder -compile -logger=machine -hardware /usr/share/arduino/hardware -hardware /home/darkmix/.arduino15/packages -tools /usr/share/arduino/hardware/tools/avr -tools /home/darkmix/.arduino15/packages -libraries /home/darkmix/Arduino/libraries -fqbn=esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=115200,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none,ZigbeeMode=default -vid-pid=10C4_EA60 -ide-version=10819 -build-path /tmp/arduino_build_385637 -warnings=none -build-cache /tmp/arduino_cache_950965 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.xtensa-esp-elf-gdb.path=/home/darkmix/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.xtensa-esp-elf-gdb-14.2_20240403.path=/home/darkmix/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.mkspiffs.path=/home/darkmix/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.mkspiffs-0.2.3.path=/home/darkmix/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.esp32-arduino-libs.path=/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1 -prefs=runtime.tools.esp32-arduino-libs-idf-release_v5.4-2f7dcd86-v1.path=/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1 -prefs=runtime.tools.riscv32-esp-elf-gdb.path=/home/darkmix/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.riscv32-esp-elf-gdb-14.2_20240403.path=/home/darkmix/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/14.2_20240403 -prefs=runtime.tools.esp-rv32.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-rv32/2411 -prefs=runtime.tools.esp-rv32-2411.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-rv32/2411 -prefs=runtime.tools.mklittlefs.path=/home/darkmix/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 -prefs=runtime.tools.mklittlefs-3.0.0-gnu12-dc7f933.path=/home/darkmix/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 -prefs=runtime.tools.esp-x32.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411 -prefs=runtime.tools.esp-x32-2411.path=/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411 -prefs=runtime.tools.openocd-esp32.path=/home/darkmix/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20241016 -prefs=runtime.tools.openocd-esp32-v0.12.0-esp32-20241016.path=/home/darkmix/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20241016 -prefs=runtime.tools.esptool_py.path=/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3 -prefs=runtime.tools.esptool_py-4.9.dev3.path=/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3 -prefs=runtime.tools.dfu-util.path=/home/darkmix/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 -prefs=runtime.tools.dfu-util-0.11.0-arduino5.path=/home/darkmix/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 -verbose /tmp/arduino_modified_sketch_460535/strandtest.ino
    Using board 'esp32' from platform in folder: /home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0
    Using core 'esp32' from platform in folder: /home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0
    UWAGA: Kategoria 'Sound' w bibliotece ESP_I2S jest nieprawidłowa. Ustawiono na 'Uncategorized'
    UWAGA: Kategoria 'Sensor' w bibliotece ESP_NOW jest nieprawidłowa. Ustawiono na 'Uncategorized'
    UWAGA: Kategoria 'Sound' w bibliotece ESP_SR jest nieprawidłowa. Ustawiono na 'Uncategorized'
    UWAGA: Kategoria '' w bibliotece ESP Insights jest nieprawidłowa. Ustawiono na 'Uncategorized'
    UWAGA: Kategoria '' w bibliotece ESP RainMaker jest nieprawidłowa. Ustawiono na 'Uncategorized'
    UWAGA: Kategoria '' w bibliotece TFLite Micro jest nieprawidłowa. Ustawiono na 'Uncategorized'
    UWAGA: Kategoria '' w bibliotece WiFiProv jest nieprawidłowa. Ustawiono na 'Uncategorized'
    /usr/bin/env bash -c "[ ! -f "/tmp/arduino_modified_sketch_460535"/partitions.csv ] || cp -f "/tmp/arduino_modified_sketch_460535"/partitions.csv "/tmp/arduino_build_385637"/partitions.csv"
    /usr/bin/env bash -c "[ -f "/tmp/arduino_build_385637"/partitions.csv ] || [ ! -f "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32"/partitions.csv ] || cp "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32"/partitions.csv "/tmp/arduino_build_385637"/partitions.csv"
    /usr/bin/env bash -c "[ -f "/tmp/arduino_build_385637"/partitions.csv ] || cp "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0"/tools/partitions/default.csv "/tmp/arduino_build_385637"/partitions.csv"
    /usr/bin/env bash -c "[ -f "/tmp/arduino_modified_sketch_460535"/bootloader.bin ] && cp -f "/tmp/arduino_modified_sketch_460535"/bootloader.bin "/tmp/arduino_build_385637"/strandtest.ino.bootloader.bin || ( [ -f "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32"/bootloader.bin ] && cp "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32"/bootloader.bin "/tmp/arduino_build_385637"/strandtest.ino.bootloader.bin || "/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3"/esptool --chip esp32 elf2image --flash_mode dio --flash_freq 80m --flash_size 4MB -o "/tmp/arduino_build_385637"/strandtest.ino.bootloader.bin "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32"/bin/bootloader_qio_80m.elf )"
    esptool.py v4.8.1
    Creating esp32 image...
    Merged 2 ELF sections
    Successfully created esp32 image.
    /usr/bin/env bash -c "[ ! -f "/tmp/arduino_modified_sketch_460535"/build_opt.h ] || cp -f "/tmp/arduino_modified_sketch_460535"/build_opt.h "/tmp/arduino_build_385637"/build_opt.h"
    /usr/bin/env bash -c "[ -f "/tmp/arduino_build_385637"/build_opt.h ] || : > "/tmp/arduino_build_385637"/build_opt.h"
    /usr/bin/env bash -c ": > '/tmp/arduino_build_385637/file_opts'"
    /usr/bin/env bash -c "cp -f "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32"/sdkconfig "/tmp/arduino_build_385637"/sdkconfig"
    Detecting libraries used...
    "/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411/bin/xtensa-esp32-elf-g++"   -c "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/cpp_flags" -w -Os -Werror=return-type -w -x c++ -E -CC -DF_CPU=240000000L -DARDUINO=10819 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 -DARDUINO_BOARD="ESP32_DEV" -DARDUINO_VARIANT="esp32" -DARDUINO_PARTITION_default -DARDUINO_HOST_OS="linux" -DARDUINO_FQBN="esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=115200,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none,ZigbeeMode=default" -DESP32=ESP32 -DCORE_DEBUG_LEVEL=0 -DARDUINO_RUNNING_CORE=1 -DARDUINO_EVENT_RUNNING_CORE=1  -DARDUINO_USB_CDC_ON_BOOT=0  "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/defines" "-I/tmp/arduino_modified_sketch_460535" -iprefix "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/include/" "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/includes" "-I/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/qio_qspi/include" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/cores/esp32" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32" "@/tmp/arduino_build_385637/build_opt.h" "@/tmp/arduino_build_385637/file_opts" "/tmp/arduino_build_385637/sketch/strandtest.ino.cpp" -o "/dev/null"
    "/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411/bin/xtensa-esp32-elf-g++"   -c "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/cpp_flags" -w -Os -Werror=return-type -w -x c++ -E -CC -DF_CPU=240000000L -DARDUINO=10819 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 -DARDUINO_BOARD="ESP32_DEV" -DARDUINO_VARIANT="esp32" -DARDUINO_PARTITION_default -DARDUINO_HOST_OS="linux" -DARDUINO_FQBN="esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=115200,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none,ZigbeeMode=default" -DESP32=ESP32 -DCORE_DEBUG_LEVEL=0 -DARDUINO_RUNNING_CORE=1 -DARDUINO_EVENT_RUNNING_CORE=1  -DARDUINO_USB_CDC_ON_BOOT=0  "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/defines" "-I/tmp/arduino_modified_sketch_460535" -iprefix "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/include/" "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/includes" "-I/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/qio_qspi/include" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/cores/esp32" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32" "-I/home/darkmix/Arduino/libraries/Adafruit_NeoPixel" "@/tmp/arduino_build_385637/build_opt.h" "@/tmp/arduino_build_385637/file_opts" "/tmp/arduino_build_385637/sketch/strandtest.ino.cpp" -o "/dev/null"
    Using cached library dependencies for file: /home/darkmix/Arduino/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp
    Using cached library dependencies for file: /home/darkmix/Arduino/libraries/Adafruit_NeoPixel/Adafruit_Neopixel_RP2.cpp
    Using cached library dependencies for file: /home/darkmix/Arduino/libraries/Adafruit_NeoPixel/esp.c
    Using cached library dependencies for file: /home/darkmix/Arduino/libraries/Adafruit_NeoPixel/esp8266.c
    Using cached library dependencies for file: /home/darkmix/Arduino/libraries/Adafruit_NeoPixel/kendyte_k210.c
    Generating function prototypes...
    "/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411/bin/xtensa-esp32-elf-g++"   -c "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/cpp_flags" -w -Os -Werror=return-type -w -x c++ -E -CC -DF_CPU=240000000L -DARDUINO=10819 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 -DARDUINO_BOARD="ESP32_DEV" -DARDUINO_VARIANT="esp32" -DARDUINO_PARTITION_default -DARDUINO_HOST_OS="linux" -DARDUINO_FQBN="esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=115200,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none,ZigbeeMode=default" -DESP32=ESP32 -DCORE_DEBUG_LEVEL=0 -DARDUINO_RUNNING_CORE=1 -DARDUINO_EVENT_RUNNING_CORE=1  -DARDUINO_USB_CDC_ON_BOOT=0  "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/defines" "-I/tmp/arduino_modified_sketch_460535" -iprefix "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/include/" "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/includes" "-I/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/qio_qspi/include" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/cores/esp32" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32" "-I/home/darkmix/Arduino/libraries/Adafruit_NeoPixel" "@/tmp/arduino_build_385637/build_opt.h" "@/tmp/arduino_build_385637/file_opts" "/tmp/arduino_build_385637/sketch/strandtest.ino.cpp" -o "/tmp/arduino_build_385637/preproc/ctags_target_for_gcc_minus_e.cpp"
    "/usr/bin/arduino-ctags" -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives "/tmp/arduino_build_385637/preproc/ctags_target_for_gcc_minus_e.cpp"
    Kompilowanie szkicu...
    "/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411/bin/xtensa-esp32-elf-g++"  -MMD -c "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/cpp_flags" -w -Os -Werror=return-type -DF_CPU=240000000L -DARDUINO=10819 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 -DARDUINO_BOARD="ESP32_DEV" -DARDUINO_VARIANT="esp32" -DARDUINO_PARTITION_default -DARDUINO_HOST_OS="linux" -DARDUINO_FQBN="esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=115200,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none,ZigbeeMode=default" -DESP32=ESP32 -DCORE_DEBUG_LEVEL=0 -DARDUINO_RUNNING_CORE=1 -DARDUINO_EVENT_RUNNING_CORE=1  -DARDUINO_USB_CDC_ON_BOOT=0  "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/defines" "-I/tmp/arduino_modified_sketch_460535" -iprefix "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/include/" "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/includes" "-I/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/qio_qspi/include" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/cores/esp32" "-I/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/variants/esp32" "-I/home/darkmix/Arduino/libraries/Adafruit_NeoPixel" "@/tmp/arduino_build_385637/build_opt.h" "@/tmp/arduino_build_385637/file_opts" "/tmp/arduino_build_385637/sketch/strandtest.ino.cpp" -o "/tmp/arduino_build_385637/sketch/strandtest.ino.cpp.o"
    Compiling libraries...
    Compiling library "Adafruit_NeoPixel"
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/esp.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/esp8266.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/kendyte_k210.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/Adafruit_Neopixel_RP2.cpp.o
    Compiling core...
    /usr/bin/env bash -c "echo -DARDUINO_CORE_BUILD > '/tmp/arduino_build_385637/file_opts'"
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/ColorFormat.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-adc.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-bt.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-cpu.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-dac.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-gpio.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-i2c-ng.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-i2c-slave.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-i2c.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-ledc.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-matrix.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-misc.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-periman.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-psram.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-rgb-led.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-rmt.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-sigmadelta.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-spi.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-time.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-timer.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-tinyusb.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-touch-ng.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-touch.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/esp32-hal-uart.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/firmware_msc_fat.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/stdlib_noniso.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/wiring_pulse.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/wiring_shift.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/libb64/cdecode.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/libb64/cencode.c.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/Esp.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/FirmwareMSC.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/FunctionalInterrupt.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/HEXBuilder.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/HWCDC.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/HardwareSerial.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/IPAddress.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/MD5Builder.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/MacAddress.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/Print.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/SHA1Builder.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/Stream.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/StreamString.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/Tone.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/USB.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/USBCDC.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/USBMSC.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/WMath.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/WString.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/base64.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/cbuf.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/chip-debug-report.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/freertos_stats.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/main.cpp.o
    Użycie wcześniej skompilowanego pliku: /tmp/arduino_build_385637/core/core.a
    Archiving built core (caching) in: /tmp/arduino_cache_950965/core/core_esp32_esp32_esp32_JTAGAdapter_default,PSRAM_disabled,PartitionScheme_default,CPUFreq_240,FlashMode_qio,FlashFreq_80,FlashSize_4M,UploadSpeed_115200,LoopCore_1,EventsCore_1,DebugLevel_none,EraseFlash_none,ZigbeeMode_default_a52bcb3f3beca066e01b260aaf12dfa7.a
    /usr/bin/env bash -c ": > '/tmp/arduino_build_385637/file_opts'"
    Linking everything together...
    "/home/darkmix/.arduino15/packages/esp32/tools/esp-x32/2411/bin/xtensa-esp32-elf-g++" "-Wl,--Map=/tmp/arduino_build_385637/strandtest.ino.map" "-L/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/lib" "-L/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/ld" "-L/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/qio_qspi" "-Wl,--wrap=esp_panic_handler" "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/ld_flags" "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/ld_scripts"  -Wl,--start-group "/tmp/arduino_build_385637/sketch/strandtest.ino.cpp.o" "/tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/esp.c.o" "/tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/esp8266.c.o" "/tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/kendyte_k210.c.o" "/tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp.o" "/tmp/arduino_build_385637/libraries/Adafruit_NeoPixel/Adafruit_Neopixel_RP2.cpp.o" "/tmp/arduino_build_385637/core/core.a"   "@/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32/flags/ld_libs"  -Wl,--end-group -Wl,-EL -o "/tmp/arduino_build_385637/strandtest.ino.elf"
    "/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3/esptool" --chip esp32 elf2image --flash_mode "dio" --flash_freq "80m" --flash_size "4MB" --elf-sha256-offset 0xb0 -o "/tmp/arduino_build_385637/strandtest.ino.bin" "/tmp/arduino_build_385637/strandtest.ino.elf"
    esptool.py v4.8.1
    Creating esp32 image...
    Merged 2 ELF sections
    Successfully created esp32 image.
    python3 "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/tools/gen_esp32part.py" -q "/tmp/arduino_build_385637/partitions.csv" "/tmp/arduino_build_385637/strandtest.ino.partitions.bin"
    /usr/bin/env bash -c "[ ! -d "/tmp/arduino_build_385637"/libraries/Insights ] || python3 "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0"/tools/gen_insights_package.py /tmp/arduino_build_385637 strandtest.ino "/tmp/arduino_modified_sketch_460535""
    /usr/bin/env bash -c "[ ! -d "/tmp/arduino_build_385637"/libraries/ESP_SR ] || [ ! -f "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32"/esp_sr/srmodels.bin ] || cp -f "/home/darkmix/.arduino15/packages/esp32/tools/esp32-arduino-libs/idf-release_v5.4-2f7dcd86-v1/esp32"/esp_sr/srmodels.bin "/tmp/arduino_build_385637"/srmodels.bin"
    "/home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3/esptool" --chip esp32 merge_bin -o "/tmp/arduino_build_385637/strandtest.ino.merged.bin" --fill-flash-size 4MB --flash_mode keep --flash_freq keep --flash_size keep 0x1000 "/tmp/arduino_build_385637/strandtest.ino.bootloader.bin" 0x8000 "/tmp/arduino_build_385637/strandtest.ino.partitions.bin" 0xe000 "/home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/tools/partitions/boot_app0.bin" 0x10000 "/tmp/arduino_build_385637/strandtest.ino.bin"
    esptool.py v4.8.1
    Wrote 0x400000 bytes to file /tmp/arduino_build_385637/strandtest.ino.merged.bin, ready to flash to offset 0x0
    Użycie biblioteki Adafruit_NeoPixel w wersji 1.15.1 z folderu: /home/darkmix/Arduino/libraries/Adafruit_NeoPixel 
    Szkic używa 300742 bajtów (22%) pamięci programu. Maksimum to 1310720 bajtów.
    Zmienne globalne używają 21396 bajtów (6%) pamięci dynamicznej, pozostawiając 306284 bajtów dla zmiennych lokalnych. Maksimum to 327680 bajtów.
    /home/darkmix/.arduino15/packages/esp32/tools/esptool_py/4.9.dev3/esptool --chip esp32 --port /dev/ttyUSB0 --baud 115200 --before default_reset --after hard_reset write_flash -z --flash_mode keep --flash_freq keep --flash_size keep 0x1000 /tmp/arduino_build_385637/strandtest.ino.bootloader.bin 0x8000 /tmp/arduino_build_385637/strandtest.ino.partitions.bin 0xe000 /home/darkmix/.arduino15/packages/esp32/hardware/esp32/3.2.0/tools/partitions/boot_app0.bin 0x10000 /tmp/arduino_build_385637/strandtest.ino.bin 
    esptool.py v4.8.1
    Serial port /dev/ttyUSB0
    Connecting......
    Chip is ESP32-D0WDQ6 (revision v1.0)
    Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
    Crystal is 40MHz
    MAC: 3c:61:05:17:55:c0
    Uploading stub...
    Running stub...
    Stub running...
    Configuring flash size...
    Flash will be erased from 0x00001000 to 0x00007fff...
    Flash will be erased from 0x00008000 to 0x00008fff...
    Flash will be erased from 0x0000e000 to 0x0000ffff...
    Flash will be erased from 0x00010000 to 0x00059fff...
    Compressed 24976 bytes to 15972...
    Writing at 0x00001000... (100 %)
    Wrote 24976 bytes (15972 compressed) at 0x00001000 in 1.8 seconds (effective 112.9 kbit/s)...
    Hash of data verified.
    Compressed 3072 bytes to 146...
    Writing at 0x00008000... (100 %)
    Wrote 3072 bytes (146 compressed) at 0x00008000 in 0.1 seconds (effective 474.3 kbit/s)...
    Hash of data verified.
    Compressed 8192 bytes to 47...
    Writing at 0x0000e000... (100 %)
    Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.1 seconds (effective 821.6 kbit/s)...
    Hash of data verified.
    Compressed 300880 bytes to 161601...
    Writing at 0x00010000... (10 %)
    Writing at 0x0001bfb0... (20 %)
    Writing at 0x00029079... (30 %)
    Writing at 0x0002e62d... (40 %)
    Writing at 0x00033fa8... (50 %)
    Writing at 0x000392aa... (60 %)
    Writing at 0x0003e86a... (70 %)
    Writing at 0x00043ea6... (80 %)
    Writing at 0x0004b0a2... (90 %)
    Writing at 0x00054422... (100 %)
    Wrote 300880 bytes (161601 compressed) at 0x00010000 in 14.5 seconds (effective 166.3 kbit/s)...
    Hash of data verified.
    
    Leaving...
    Hard resetting via RTS pin...
    .
    ESP32 development board with labeled pins and micro USB port .
    tried adafruit and fastled[/img].

    maybe i'll just give up on them and put in the usual 4 pins (5v, g, b, r) because these at least work
  • ADVERTISEMENT
  • #12 21623346
    DJ_KLIMA
    Level 25  
    Posts: 659
    Help: 67
    Rate: 216
    Eh, in loop every 1 second send to the strip, it will work with a kick. And if it doesn't work, then an analyser or oscilloscope on the tip, I did 1000 different flickers on ESP32, ESP8266, DMX, ArtNet, WiFi, it sat for a while, but the strips always lit up on the 1st try with the library from Adafruit, over time I started adding a 3.3 V converter -> 5 V, because it was a problem if you mixed LEDs from different manufacturers, 74HCT1G125 under A signal from ESP, OE+GND to GND, VCC to +5 V and Y on DIN of the strip.
  • #13 21623369
    cototo1991
    Level 3  
    Posts: 10
    DJ_KLIMA wrote:
    Eh, in loop every 1 second send to the strip, it will work with a kick. And if it doesn't work, then an analyser or oscilloscope on the tip, I did 1000 different flickers on ESP32, ESP8266, DMX, ArtNet, WiFi, it sat for a while, but the strips always lit up on the 1st try with the library from Adafruit, over time I started adding a 3.3 V converter -> 5 V, as it was a problem when mixing LEDs from different manufacturers, 74HCT1G125 under A signal from ESP, OE+GND to GND, VCC to +5 V and Y on DIN of the strip.
    .
    I also tried but tried not with HTC but AHCT like this:
    "ESP32 (signal):
    GPIO5 (D5) → pin 1A (input) on 74AHCT125
    pin 1Y (output) → via 330 Ω resistor → DIN WS2812B

    🔴 Power supply to 74AHCT125:
    VCC (pin 14) → 5 V from LM2596
    GND (pin 7) → GND (common with ESP and LED)
    1OE (pin 1) → GND (to activate the 1A/1Y buffer)

    🟡 WS2812B power supply:
    VCC LED → 5 V from LM2596
    GND LED → GND common
    DIN LED → from 1Y 74AHCT125 via 330 Ω".

    I still had the "LED box ambilight" it has the same leds in it, it under the LED box driver started but under ESP32b not either 🤮 I will try later this loop every 1 sec

    nothing worked either, I've tried every way, even 100% working, attached a picture of how it's all connected together (ugly but everything except the leds works, in the middle is this 74AHCT125) it's a bit good that I forgot about them altogether and finished them, because I probably would have given up because of the leds and now it's a pity
    Attachments:
    • WS2812B LED not working with ESP32 CP2102 on GPIO2/5/13/35 – wiring or code issue? 2025-08-01-20-13-58-707.jpg (604.68 KB) You must be logged in to download this attachment.
    • WS2812B LED not working with ESP32 CP2102 on GPIO2/5/13/35 – wiring or code issue? 2025-08-01-20-13-15-373.jpg (660.61 KB) You must be logged in to download this attachment.
    • WS2812B LED not working with ESP32 CP2102 on GPIO2/5/13/35 – wiring or code issue? 2025-08-01-20-13-07-145.jpg (665.89 KB) You must be logged in to download this attachment.
    • WS2812B LED not working with ESP32 CP2102 on GPIO2/5/13/35 – wiring or code issue? 2025-08-01-20-10-40-867.jpg (665.6 KB) You must be logged in to download this attachment.
  • #14 21623839
    DJ_KLIMA
    Level 25  
    Posts: 659
    Help: 67
    Rate: 216
    Do you have an analyser or oscilloscope of some kind? Even a soapbox? Show if anything is being sent from the GPIO, because this is some kind of sorcery. Are you selecting the right configuration from the menu? LED flashing on the GPIO is working? Do some simple counter program with serial so you know the program is working stably.
  • #15 21623929
    efi222
    Level 21  
    Posts: 655
    Help: 12
    Rate: 1057
    The pictures are not very clear with regard to the connections. What is connected to the ESP there besides the WS control? Three wires are sufficient to drive the WS. Below is the code that works 100% on the ESP32. Tested on GPIO4 and GPIO14. Works on core 1.0.4 to 3.0.0, ESP32 Dev Module board. It sends a message every second on the UART.
    Once uploaded, the first LED lights up white, the second red. For testing (no oscilloscope), instead of the WS, you can connect a regular LED to the GPIO output of the ESP. Cathode to ground , anode via 330R resistor to GPIO. It should blink weakly every second. If the LED flashes, it should work when the WS is connected. You can also lower the WS supply to 4V and dispense with the driver. It probably can't be any simpler :) .
    Code: Arduino
    Log in, to see the code
  • #16 21624028
    cototo1991
    Level 3  
    Posts: 10
    DJ_KLIMA wrote:
    Have you got some kind of analyser or oscilloscope? Even a soapbox? Show if anything is being sent from the GPIO, because that's some sorcery. Are you selecting the right configuration from the menu? LED flashing on the GPIO is working? Do some simple counter program with serial so you know the program is working stably.
    .
    I just don't have one normal LED
    for the esp there is 3 x FSR, potentiometer, stepper motor, peristaltic pump, flow meter, 1.3" oled, start button (self reset)
    but i also tried the esp led alone (above picture was) also here it doesn't matter what is connected because it doesn't work as well without it as with all this.
    I am using 3.2.0 it can go lower (also esp32 dev module)
    Screenshot of ESP32 version 3.2.0 installed in Arduino IDE package manager

    i uploaded your code, initially 1 led lit white, 2 green but they only lit when i checked the connection with a meter then i changed leds[1] = CHSV(0, 255, 255); to (0,255,0) I restarted esp, they didn't light up at all, but I started checking again with the multimeter and 12 leds lit up white and in the video I connected again and also some random stuff, as I turned off and put the meter to GND > DIN or but




    but after the recording i tried to repeat it i shorted everything with no effect until one time 1 led lit up green 🤮 it's all messed up .... unless if it worked on this try unplugging this "sacrificed" diode?
  • #17 21624098
    efi222
    Level 21  
    Posts: 655
    Help: 12
    Rate: 1057
    efi222 wrote:
    #define COLOR_ORDER GRB
    .
    If the second LED glows green change "GRB" to "RGB" in this line and I suggest going lower with the core version on 3.0.0
    On 3.3.0 it does not work. On 3.2.0 I have not checked.

    cototo1991 wrote:
    then I changed leds[1] = CHSV(0, 255, 255); to (0,255,0)
    .
    With these values, the second LED will go out, as this is the value parameter for the CHSV colour space.
    CHSV (colour, saturation, value) (translated into EN.)
    Changing the values blindly is the wrong way....
  • #18 21624184
    cototo1991
    Level 3  
    Posts: 10
    I corrected as you wrote (I thought the 255 was RGB, that's why I changed it that way), but still the only thing it does is that it only lights the LEDs when I put the meter to the DIN of the "sacrificed" LED and DO the "sacrificed" LED.
    Get rid of it and just leave it:
    5V - LED 5V
    GND - GND 5V
    DIN - D4


    .
  • Helpful post
    #19 21624203
    efi222
    Level 21  
    Posts: 655
    Help: 12
    Rate: 1057
    This 'dedicated' LED should also light up. In code leds[0].
    For testing, there is nothing stopping you from powering all LEDs through the rectifier diode. They will glow a little weaker.
    The driver is then unnecessary.
    I have run out of ideas. This circuit should work from the "kick" :) .
    Touching the WS pins with probes generates some interference and random glow.
    WS2812 LED strip with white and red LEDs on, powered via a rectifier diode
  • #20 21624307
    cototo1991
    Level 3  
    Posts: 10
    I did exactly as you showed in the picture, corrected in the code and it worked, then plugged back in everything and it works, even left the shifter of that ahct


    .
    Only question now, since it works with the shifter, leave it as it is already? The GPIO then goes as if through two 330 ohm resistors,
    but I think it was a code issue, although I tested on this one: thanks a lot for the help🫡.
    #include <FastLED.h>
    #define LED_PIN     2      // Twój pin, np. D2
    #define NUM_LEDS    30     // Liczba diod
    #define BRIGHTNESS  100
    #define LED_TYPE    WS2812B
    #define COLOR_ORDER GRB
    CRGB leds[NUM_LEDS];
    void setup() {
      FastLED.addLeds<LED_TYPE, LED_PIN, COLOR_ORDER>(leds, NUM_LEDS);
      FastLED.setBrightness(BRIGHTNESS);
    }
    void loop() {
      leds[0] = CRGB::Red;
      FastLED.show();
      delay(500);
      leds[0] = CRGB::Black;
      FastLED.show();
      delay(500);
    }
    
    .
  • Helpful post
    #21 21624440
    efi222
    Level 21  
    Posts: 655
    Help: 12
    Rate: 1057
    cototo1991 wrote:
    Only question now, since it works with shifter, leave it as is?
    .
    The WS2812B specification states that the control logic level should not be lower than 0.7 Vdd.
    5V x 0.7 = 3.5V. The level from the ESP = 3.3V, so slightly below the requirements.
    If the WS is supplied by a diode, it is about 4.4V.
    4.4 x 0.7 = 3.08. In this case a level converter is not needed.

    On the other hand, I have not yet encountered a WS supplied with 5V that could not be driven at 3.3V. Maybe you are dealing with a very demanding device.

    My code and the last one are correct.
    Why didn't it work before?
    I would bet on that single WS ("sacrificed") which may have gone to the land of eternal darkness during the experiments.... ;)

Topic summary

✨ The user is developing an automatic vodka dispenser using an ESP32 CP2102 microcontroller and WS2812B LEDs but faces issues with the LEDs not functioning on GPIO pins 2, 5, 13, and 35. The LEDs work correctly in a Tinkercad simulation but fail in the physical setup despite attempts with different wiring configurations, including adding a capacitor, resistor, and a 74AHCT125 level shifter. The LED diode only lights briefly when the data input (DIN) is shorted to ground or toggled rapidly, indicating possible signal or wiring issues. The project operates correctly without the LEDs, but the user seeks advice on proper wiring or code adjustments to enable LED signaling.
Generated by the language model.

FAQ

TL;DR: 0.7×Vdd logic-high means a 5 V WS2812B needs ~3.5 V, but ESP32 outputs 3.3 V; "control logic level should not be lower than 0.7 Vdd." Use an AHCT/HCT level shifter or drop LED Vdd to ~4.4 V, and test on GPIO4/14 with FastLED. [Elektroda, efi222, post #21624440]

Why it matters: For ESP32 Dev Module/CP2102 users, this fixes WS2812B “not working on GPIO2/5/13/35” by clarifying levels, pins, wiring, and code.

Quick Facts

What’s the fastest way to bring up a WS2812B on an ESP32 CP2102?

Load a minimal FastLED sketch, set NUM_LEDS to 1, and use GPIO4 or GPIO14. Wire 5 V and GND to the strip, and DATA from the chosen GPIO. Ensure a common ground between ESP32 and LEDs. If colors look off, try GRB then RGB. Once LED 0 blinks, expand to more LEDs. This exact approach lit the strip in the thread. [Elektroda, efi222, post #21623929]

Is GPIO35 okay for driving WS2812B?

No. GPIO34–GPIO39 on ESP32 are input-only and cannot drive the WS2812B data line. Choose an output-capable pin, like GPIO4 or GPIO14. Verify your board’s pin capabilities and avoid input-only pins for LED control. Using an input-only pin results in no signal transmission to the LEDs. [Espressif, 2023]

Do I need a 3.3 V to 5 V level shifter for WS2812B?

Often yes. WS2812B expects a HIGH ≥0.7×Vdd. At 5 V that’s ~3.5 V, while ESP32 outputs 3.3 V. You can add a 74AHCT/74HCT level shifter, or drop LED Vdd to ~4.4 V so 3.3 V meets the threshold. "The control logic level should not be lower than 0.7 Vdd." [Elektroda, efi222, post #21624440]

How do I wire a 74HCT1G125/74AHCT125 as a level shifter for the data line?

Connect ESP32 GPIO to A, tie OE to GND, power the chip at 5 V, and take Y to the strip’s DIN. Share GND between ESP32, the driver, and the LED strip. This simple buffer provides a solid 5 V data signal and improves compatibility across LED batches. [Elektroda, DJ_KLIMA, post #21623346]

What series resistor value should I put on the WS2812B data line?

Use a 100–500 Ω resistor in series with the data line. A 330 Ω value is a widely used default. It helps tame ringing and reduces overshoot on longer leads. Place it close to the LED DIN side. [Elektroda, gps79, post #21623040]

Why do LEDs react only when I touch them with a multimeter or short DIN to GND?

Your probing injects noise or changes impedance, accidentally creating a detectable edge. That indicates marginal signal integrity, wrong levels, or grounding issues. Ensure a firm common ground, proper data routing, and correct logic level. "Touching the WS pins with probes generates interference and random glow." [Elektroda, efi222, post #21624203]

Could a single bad LED block the whole strip?

Yes. If the first LED is damaged, it can swallow or corrupt the data, leaving all following LEDs dark. Swap in another first segment or drive the next LED’s DIN directly to test. A failed “sacrificed” first LED caused symptoms in the thread. [Elektroda, efi222, post #21624440]

Which library and ESP32 core version should I use?

Adafruit_NeoPixel and FastLED both work. In the thread, FastLED with GPIO4/14 worked. If you hit issues on ESP32 Arduino core 3.3.0, try core 3.0.0. Also set COLOR_ORDER correctly (GRB or RGB) to match your LEDs. [Elektroda, efi222, post #21624098]

Why does #define LED_PIN D5 fail on my ESP32 sketch?

Many ESP32 board cores use plain GPIO numbers, not D-labels. Defining D5 can cause a compile error because D5 is undefined. Use the numeric GPIO like 5, 4, or 14 in your code. [Elektroda, cototo1991, post #21623261]

How can I test the ESP32 output without an oscilloscope?

Blink a regular LED first. Connect an LED’s anode via a 330 Ω resistor to the chosen GPIO and the cathode to GND. Run a simple sketch that toggles the pin once per second. If it blinks, your code and pin work. Then reconnect the WS2812B. [Elektroda, efi222, post #21623929]

My colors look wrong. How do I fix the WS2812B color order?

Change the color order in your library setup. Try GRB first, then RGB if greens and reds swap. In FastLED, update COLOR_ORDER. In Adafruit_NeoPixel, set NEO_GRB or NEO_RGB. Test with a simple two-LED pattern to verify. [Elektroda, efi222, post #21624098]

Why did it work in Tinkercad but not on hardware?

Simulations ignore physical thresholds and line integrity. Real strips enforce the 0.7×Vdd logic-high requirement. With a 5 V strip and 3.3 V data, add a level shifter or lower Vdd to ~4.4 V. Then retest with known-good code. [Elektroda, efi222, post #21624440]

Can I test with a single LED segment, and how dense are typical strips?

Yes, testing a single cut LED is ideal. It simplifies power and wiring during bring-up. The user’s strip was 60 LEDs per meter, a common density. Start with NUM_LEDS=1 in code, then scale after success. [Elektroda, cototo1991, post #21622584]

How do I bring up WS2812B on ESP32 step-by-step?

  1. Wire 5 V and GND to the strip; connect DATA from GPIO4 or GPIO14; share GND.
  2. Load the posted FastLED sketch, set NUM_LEDS=1, and COLOR_ORDER=GRB; upload and test.
  3. If no light, power LEDs near 4 V–4.4 V to skip a driver, then retry. [Elektroda, efi222, post #21623929]
Generated by the language model.
ADVERTISEMENT