You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
in my project I am using WS2812b mini V3 LEDs. I spent a lot of time trying to find out why the LEDs would not light up. After taking measurements and reading the datasheets, I discovered that the WS2812B Mini V3 LED has unusual timing for T1L.
I was unable to find an LED type included in FastLED that shares the same timings. Defining FASTLED_WS2812_T3, FASTLED_WS2812_T2 or FASTLED_WS2812_T1 only changes the high time.
Can someone help me get this LED type to work with FastLED?
Hey @zackees,
Thank you so much for this incredibly fast fix! I used the latest version and selected the 'WS2812BMiniV3' option.
However, after compiling, the LED is still dark. I measured the signal using an oscilloscope.
The T1L is 560ns for me. Unfortunately, this is still too short a time, but it is really close to the lower border.
Could you tell me which line I need to change, or could you possibly increase the value again?
Thank you very much for your suggestions. It must be something else.
I am running the serial connection at 115200 baud for my code, and it is working fine. I also printed the test code that you mentioned from ChatGPT, and it gave me F_CPU = 16000000 @ 115200 baud.
If there were an issue with the F_CPU, all the pulses would be half as slow, but they aren't.
These are the measurements timings I took:
This is the measurement:
I have also some DS18B20 temperatur sensors connected and some DHT22 humidity and temperatur sensors and the communication is working well.
Hey,
Thank you very much for investigating further!
I downloaded your latest code changes and implemented them in my project. However, after compiling and flashing, the LED is still off. I got the following timings:
T0H = 264 ns
T0L = 950 ns
T1H = 616 ns.
T1L = 568 ns.
It's close, but still too slow.
I will be travelling for one week. After that, I will change your values to see how it works. I will come back to this topic.
Could you explain how T1, T2 and T3 work? How do you calculate the expected timings?
Briefly speaking, these datasheet timings are asymettric. However all LED chipsets use symmetric timings where no matter what the bit is, (0 or 1) we end at the same time. Because of this symmetry it can be described in a more compact form called three phase symmetric timings which is what T1, T2, T3 represent.
Protocol Timing:
At T=0 : Line goes HIGH (start of bit)
At T=T1 : Line goes LOW (for '0' bit)
At T=T1+T2 : Line goes LOW (for '1' bit)
At T=T1+T2+T3 : Cycle complete (ready for next bit)
Here's an AI writeup describing this in more detail
LED Chipset Timing Formats: Datasheet vs 3-Phase
Overview
FastLED uses two different timing representations for addressable LED
chipsets (like WS2812B, SK6812, APA102, etc.):
1. Datasheet Format (T0H, T0L, T1H, T1L) - Standard LED manufacturer
specification
2. 3-Phase Format (T1, T2, T3) - FastLED's internal representation for
efficient bit-banging
Datasheet Format (T0H, T0L, T1H, T1L)
This is how LED manufacturers specify timing in their datasheets. Each bit
transmission consists of a HIGH pulse followed by a LOW pulse.
Timing Parameters:
- T0H: Time HIGH when sending a '0' bit (nanoseconds)
- T0L: Time LOW when sending a '0' bit (nanoseconds)
- T1H: Time HIGH when sending a '1' bit (nanoseconds)
- T1L: Time LOW when sending a '1' bit (nanoseconds)
Waveforms:
'0' bit: ___________
| T0H | T0L
HIGH─────────LOW──────────
'1' bit: _____________________
| T1H | T1L
HIGH────────────────LOW──
Example (WS2812B):
- T0H = 400ns (short high pulse for '0')
- T0L = 850ns (long low pulse for '0')
- T1H = 850ns (long high pulse for '1')
- T1L = 400ns (short low pulse for '1')
- Total cycle: 1250ns (both '0' and '1' bits)
3-Phase Format (T1, T2, T3)
FastLED's optimized representation reduces redundancy by recognizing that
both bits start HIGH and the difference is just when the line drops LOW.
Timing Parameters:
- T1: High time for '0' bit (shortest high pulse)
- T2: Additional high time for '1' bit (extension beyond T1)
- T3: Low tail duration (low time after '1' bit drops)
Protocol Timing:
At T=0 : Line goes HIGH (start of bit)
At T=T1 : Line goes LOW (for '0' bit)
At T=T1+T2 : Line goes LOW (for '1' bit)
At T=T1+T2+T3 : Cycle complete (ready for next bit)
Waveforms:
'0' bit: _____
| T1 | T2 | T3
HIGH──LOW─────────────────
'1' bit: ______________
| T1 | T2 | T3
HIGH──────────LOW─────────
Same Example (WS2812B in 3-Phase):
- T1 = 400ns (high time for '0')
- T2 = 450ns (additional high time for '1': 850ns - 400ns)
- T3 = 400ns (tail time after '1' drops)
- Total cycle: 1250ns
Conversion Algorithm
Datasheet → 3-Phase
duration = max(T0H + T0L, T1H + T1L)
T1 = T0H # High time for '0' bit
T2 = T1H - T0H # Additional time for '1' bit
T3 = duration - T1H # Tail time after '1' bit drops
Key insight: T1 is the transition point that distinguishes '0' from '1'.
3-Phase → Datasheet
This conversion is underdetermined (3 inputs → 4 outputs). The code
assumes symmetric cycle times:
duration = T1 + T2 + T3
T0H = T1
T1H = T1 + T2
T0L = duration - T0H # Assumes T0H+T0L = duration
T1L = duration - T1H # Assumes T1H+T1L = duration
Why 3-Phase Format?
Advantages:
1. Reduces redundancy - Both bits start HIGH, only transition timing
differs
2. Simpler state machine - Three distinct phases instead of four separate
timings
3. Better CPU efficiency - Easier to implement in bit-banging code
4. More intuitive - Directly maps to hardware timer comparisons
Used in: src/fl/chipsets/led_timing.h for FastLED's internal chipset
definitions
Practical Example
WS2812B V5 Override (from recent work):
// Datasheet: T0H=300ns, T0L=790ns, T1H=790ns, T1L=300ns
// Converts to:
T1 = 300 // '0' bit high time
T2 = 490 // Additional '1' bit high time (790-300)
T3 = 300 // Tail low time
This format allows hardware implementations (RMT, PIO, SPI) to efficiently
generate the correct waveforms with minimal CPU overhead.
now I tested your changes and measured again, because the LED is still off.
Here you can see T0H:
Here you can see T0L (close to the T0L max time [1µs]):
Here you can see T1H:
Here you can see T1L:
This is the whole signal:
I send it for testing every 50ms:
Everything should be correct now. I don´t understand what is wrong.
For this reason I ordered another WS2812B-mini-V3 from LCSC. The last I bought from aliexpress. Probably they send different LED type, I don´t know. When I received the LEDs I test again and come back.
Or did I missed something important in the pictures?
The new LEDs have arrived from LCSC, and I have soldered them to my test board.
It wasn't necessary to use the overclock feature. The LED is working now! That means that the LEDs I had before were not original Mini-V3s and that the software timing was not correct.
So finally, I can thank you very much for your support and for helping me with the code!
Activity
zackees commentedon Nov 5, 2025
Try this:
That chip you have is very long in the reset time.
So after FastLED.show()
delay(1); // 1000us is plenty for the reset
zackees commentedon Nov 5, 2025
https://github.com/FastLED/FastLED/blob/master/ci/tools/led_timing_conversions.py
zackees commentedon Nov 5, 2025
I just added this led timing to fastled. Download latest from this repo and declare your led strip like so:
Also fyi, this is identical to the new WS2812B-V5 chipset
fixes FastLED#2132
TPPTim commentedon Nov 5, 2025
Hey @zackees,
Thank you so much for this incredibly fast fix! I used the latest version and selected the 'WS2812BMiniV3' option.
However, after compiling, the LED is still dark. I measured the signal using an oscilloscope.
The T1L is 560ns for me. Unfortunately, this is still too short a time, but it is really close to the lower border.
Could you tell me which line I need to change, or could you possibly increase the value again?
Thank you!
zackees commentedon Nov 5, 2025
Sounds like F_CPU is set wrong. This is what FastLED uses to calculate the number of ticks -> nanoseconds in it's tight timing.
What device are you using?
TPPTim commentedon Nov 5, 2025
Hey,
I am using an Arduino Nano v3 with Arduino bootloader in Visual Studio Code PlatformIO.
Is there something I have to change?
Regards
Tim
zackees commentedon Nov 5, 2025
I think you're at 8mhz clock rate and the device thinks it's at 16mhz.
YOu are hitting at 560ns right?
220 x 2 = 440n + 1 extra cycle at a 120 ns, bringing you to 560ns.
Try this
https://chatgpt.com/s/t_690be0cc860881919f9a3b5d7cbf9a2a
TPPTim commentedon Nov 6, 2025
Thank you very much for your suggestions. It must be something else.
I am running the serial connection at 115200 baud for my code, and it is working fine. I also printed the test code that you mentioned from ChatGPT, and it gave me F_CPU = 16000000 @ 115200 baud.
If there were an issue with the F_CPU, all the pulses would be half as slow, but they aren't.
These are the measurements timings I took:

This is the measurement:

I have also some DS18B20 temperatur sensors connected and some DHT22 humidity and temperatur sensors and the communication is working well.
This is very strange for me...
TPPTim commentedon Nov 7, 2025
@zackees, can you propably change the value in the code a little, that the timing will get increased by 100ns for T1L?
Best Regards
zackees commentedon Nov 9, 2025
I added macros for the timing. Can you please test this out.
I'm looking into your picture
TPPTim commentedon Nov 9, 2025
Hey,
Thank you very much for investigating further!
I downloaded your latest code changes and implemented them in my project. However, after compiling and flashing, the LED is still off. I got the following timings:
T0H = 264 ns
T0L = 950 ns
T1H = 616 ns.
T1L = 568 ns.
It's close, but still too slow.
I will be travelling for one week. After that, I will change your values to see how it works. I will come back to this topic.
Could you explain how T1, T2 and T3 work? How do you calculate the expected timings?
Thank you.
Tim
zackees commentedon Nov 10, 2025
i didn't mean to close the bug
zackees commentedon Nov 10, 2025
Briefly speaking, these datasheet timings are asymettric. However all LED chipsets use symmetric timings where no matter what the bit is, (0 or 1) we end at the same time. Because of this symmetry it can be described in a more compact form called three phase symmetric timings which is what T1, T2, T3 represent.
Here's a calculator:
led_timing_conversions.py
Here's an AI writeup describing this in more detail
zackees commentedon Nov 10, 2025
Should be fixed now, final timings are:
T1=225, T2=355, T3=645
T0H: 225ns (high time for '0' bit)
T0L: 1000ns (low time for '0' bit)
T1H: 580ns (high time for '1' bit)
T1L: 645ns (low time for '1' bit)
led timing for WS2812 Vb, fixes: FastLED#2132
fixes FastLED#2132
TPPTim commentedon Nov 10, 2025
Thank you!
I will come back here after my vacation.
Best regards
TPPTim commentedon Nov 19, 2025
Hello @zackees,
now I tested your changes and measured again, because the LED is still off.
Here you can see T0H:

Here you can see T0L (close to the T0L max time [1µs]):

Here you can see T1H:

Here you can see T1L:

This is the whole signal:

I send it for testing every 50ms:

Everything should be correct now. I don´t understand what is wrong.
For this reason I ordered another WS2812B-mini-V3 from LCSC. The last I bought from aliexpress. Probably they send different LED type, I don´t know. When I received the LEDs I test again and come back.
Or did I missed something important in the pictures?
Regards
Tim
zackees commentedon Nov 20, 2025
We have an over/under clocking feature where you can try to bend the signal wave into tighter compliance, worth giving it a shot:
TPPTim commentedon Dec 5, 2025
Hello Zackees,
The new LEDs have arrived from LCSC, and I have soldered them to my test board.
It wasn't necessary to use the overclock feature. The LED is working now! That means that the LEDs I had before were not original Mini-V3s and that the software timing was not correct.
So finally, I can thank you very much for your support and for helping me with the code!
Regards, Tim
zackees commentedon Dec 7, 2025
That's great to hear! Glad everything works!