Actuator

๐ŸŒฌ๏ธ Fan Module

๐Ÿ“Œ Description

The L9110 fan module is a small motor driver board that can control a DC motor or fan. It uses two pins to decide the direction of rotation. By switching signals, the fan can spin forward or backward.

๐ŸŽฏ Use

In our projects, the L9110 is used to:

  • Control cooling fans.
  • Spin small propellers or wheels.
  • Demonstrate motor direction control with simple code.

๐Ÿ‘‰ Think of the L9110 as the robotโ€™s wind machine โ€” it makes air flow or spins parts when commanded.

Module parameters

Pin name Description
G GND (Power Input Negative)
V VCC (Power Input Cathode)
INA Motor control signal pin A
INB Motor control signal pin B
  • Supply voltage: 3.3V/5V
  • Connection: PH2.0 terminal wire
  • Installation method: double screw fixing

๐Ÿ–ฅ๏ธ Code Explanation

f

import machine
import time

pin16 = machine.Pin(16, machine.Pin.OUT)   # Control pin A
pin17 = machine.Pin(17, machine.Pin.OUT)   # Control pin B

while True:
    pin16.value(1)     # Fan spins forward
    pin17.value(0)
    time.sleep(1)      # Keep spinning for 1 second

    pin16.value(0)     # Fan spins backward
    pin17.value(1)
    time.sleep(1)      # Keep spinning for 1 second

Step by Step

  1. import machine, time โ†’ Tools to control pins and add pauses.
  2. pin16 and pin17 โ†’ These two pins decide the fanโ€™s direction.
  3. while True: โ†’ Loop that repeats forever.
  4. pin16.value(1), pin17.value(0) โ†’ Fan spins forward for 1 second.
  5. pin16.value(0), pin17.value(1) โ†’ Fan spins backward for 1 second.
    ๐Ÿ‘‰ Together, the fan alternates between forward and backward rotation.

โœ… Conclusion of the Test

  • If the fan spins forward for 1 second, then backward for 1 second, the program is working correctly.
  • This test shows how the L9110 can control motor direction using two pins.
  • Later, you can adjust the timing or combine with sensors to make the fan react to temperature, motion, or other inputs.
On this page