Page 1 of 1

Controlling PC fan speed

Posted: Tue Dec 10, 2019 12:41 pm
by ajocius
I would like to control PC fan speed using ESP32 adn Micropython. Fan will be cooling air in my mini greenhouse, once temperature reaches trigger level, measured by DHT22. It is 12V fan and I can run it on 100% speed by connecting two power cables. However, there is no need to run it on 100% of speed, might be too much of air movement, loud, etc
PC Fan has 4 connectors, two of which are 12V power supply. The other two are Signal (Fan RPM) and PWM (Digital control) according to google. Is there any way for me to connect one or both of those pins to ESP32 and control fan speed? If yes, would be great if you have link to some sample code. Is it controlled by sending RPM value? or percentage of maximum RPM? If this is not possible to control directly from ESP32, can this be done using some driver module attached to ESP32 ?

Re: Controlling PC fan speed

Posted: Tue Dec 10, 2019 2:27 pm
by DJShadow1966
Hello

Have a look at this post viewtopic.php?t=3224

Regards Mike

Re: Controlling PC fan speed

Posted: Tue Dec 10, 2019 3:37 pm
by ajocius
thanks, saw that one, but it didn't contain sample code, so not sure how to control PC fan...

Re: Controlling PC fan speed

Posted: Tue Dec 10, 2019 5:05 pm
by MostlyHarmless
ajocius wrote:
Tue Dec 10, 2019 3:37 pm
thanks, saw that one, but it didn't contain sample code, so not sure how to control PC fan...
If the fan is controlled by an actual PWM signal, then the esp32's PWM module should work.


Regards, Jan