In this project, we wiill learn how to make a small fan.
The small fan uses a 130 DC motor and safe fan blades. You can use PWM output the fan speed.
Fan.Two pins are required to control the motor of the fan, one for INA and two for INB. The PWM value range is 0~255. When the PWM output of the two pins is different, the fan can rotate.
Value | Action |
---|---|
INA - INB <= -45 | Rotate clockwise |
INA - INB >= 45 | Rotate anticlockwise |
INA == 0, INB == 0 | Stop |
Pin | ID |
---|---|
INA | 19 |
INB | 18 |