PIC PWM Fan controller

Hélio Pereira   consola.repair@gmail.com   http://www.umodding.info  
44

photo_01

Description

This project it´s based on a PIC18F25K20, with the purpose of control a FAN with PWM (Pulse with Modulation). It offers a variable speed control, low acoustic noise, reliability, long lifetime, low power consumption, protection features. The MCU get the temperature from the sensor (D18B20), and after will do a conversion Celsius degrees and then it´s generated a PWM on PORTC.2 with 6 different levels.

PWM

TEMPERATURE

15%

<= 49°

30%

50°

40%

51°

50%

52°

75%

53°

100%

>54°

After the signal goes to Q1 (BC338) in order to control the duty cycle in the fan. I had to use two transistors to have an Ic on Q2 to be enough to activate the fan. Because the MCU only generate a maxim of 3.6V on which output, and 15% of 3.6V is 0.5V to polarize Q1 we need 0.7V.

How to calculate the Q1 and Q2:

formula

You will be able to control the FAN between 5V and +/-12V.The BC338 have a current load of 800mA that is value of a fan can have, you can use two or more fans as long the current load isn´t more than 800mA. The output of MCU connect to the Q1 and Q2 it works like a switch, the D3 it´s for protection from the magnetic field in the inductors from the FAN, without the D3 when you turn off the system the current will be discharge to the Q2 and could damage it.

Connectors

J1 Expansions PORTS
Source 12V
Sensor D18B20
FAN Connect the FAN
ICSP To program with PICKIT2

photo_02

Photo of the prototype on perfboard

Schematic

Schematic

PCB

Leave a Reply

Your email address will not be published. Required fields are marked *