PWM Fan Controller

Because the fan might find the ground path via pwm or tach wire and cause unexpected behavior. Ideally you find the datasheet which describes how the fan is turned off.

1 Like

Well, that’s easy: https://cdn.noctua.at/media/Noctua_PWM_specifications_white_paper.pdf

I now directly connected the fan to 12V and the global GND and only connected the PWM signal for now. When there is 0% PWM, the fan turns off. So far so good. However, changing speed does not work and also if the fan is off, it won’t start and I just hear a “tak tak tak”.
I really don’t understand what the issue with this fan is? The other PWM fan I tested worked just fine. It can’t be an issue with the PWM voltage level, right? The spec says logic low is below 0.8V and max. voltage is 5.25V. Thus, the 3.3V level should read as “high”.
The only issue that is gone: The rpm sensor does now work. So that was very sensitive to the wrong GND.

So if you give it full speed from off it doesn’t start?

Following test procedure:

  • GND is always connected to the fan
  • Connecting 12V, nothing else → Fan starts (as expected)
  • First connecting PWM to GND, then connecting 12V → Fan does not start (as expected)
  • Connecting PWM to 3.3V, then connecting 12V → Fan makes “tak tak tak” and does not start
  • Connecting PWM to 5V, then connecting 12V → Fan makes “tak tak tak” and does not start
  • Connecting the PWM pin to GND on the running fan → fan stops (as expected)
  • Connecting the PWM pin to 5V on the running fan → fan keeps running (as expected)
  • Connecting the PWM pin to 3.3V on the running fan → fan starts stuttering and then turns off, then I only hear “tak tak tak”.

I guess - that against the datasheet - the fan needs a 5V PWM signal :confused: (but actually, then it should also start with 5V connected…)
I fear, that I may have damaged the PWM input somehow :cry:

edit: this is confusing. When the fan is running and I plug in the 3.3V PWM signal, the fan reduces the speed and can be controlled by PWM. Except I go to 100% PWM - then the fan goes into “tak tak tak” mode.

Doesn’t sound like normal behavior. On the other hand, trying randomly things can cause weird outcome.
Read the noctua whitepaper, it’s likely the best info you can find.

Capture from that says:
image

yes, I have done that before I started with the project and I was very careful to never let 12V near the PWM and tacho pins.

I’ll dig out an 5V Arduino and try with real 5V PWM… maybe that helps.

edit: I tested now with a 5V PWM on an Arduino and … it works. By default, the PWM frequency is 500Hz, and I also tested that with esphome, but same behavior. It looks like that this fan really needs a 5V signal, which is however contrary to the datasheet :person_shrugging:
The 5V signal on the ESP Board is actually only 4.5V which may further explain why it would not work.
But it is super interesting, that as long as the fan runs, it can be controlled via 3.3V PWM…
There is even a Noctua Guide for Microcontrollers: https://www.noctua.at/en/support/faqs/microcontroller-guide-pwm-setup-and-rpm-monitoring
They explicitly mention that 3.3V PWM does work… I wrote them now and asked if the industrialPPC work differently or if that indicates a fault.

Was there a bugfix in esphome 2026.3.3?! I updated it today and it suddenly just works… :exploding_head:

By the way, I checked with Noctua, and they confirmed me that it should work with 3.3V PWM signal.

edit: wait what?! There is something messed up with ESPhome. I had the ledc on GPIO14 for testing and changed it back to GPIO26. I had the fan still connected to GPIO14 though, and it still worked! So it did on GPIO26… How?!

No idea about bugfixes. But sounds more probable than noctua not working at 3v3 pwm.

No how. Duty cycle supposed to be independent on every ledc-pin. That doesn’t exclude that you have both pins high.

yes, I don’t understand that either. How should it be possible to have the same PWM signal on two GPIOs when not configured?
Is there a chance that an old configuration survives OTA updates and thus both outputs are active? I cleaned all data in esphome and downloading and compiling right now…

Not really.
Anyway, two ledc pins on same channel are running at same frequency/duty,