Posts: 33
Joined: Fri May 24, 2013 12:22 pm

Motor controller

Thu Sep 17, 2015 8:04 pm


Im looking for a motor controller that can control the direction and speed of 2 or 3 different DC motors. If I am right the PI only has 1 PWM pin. Most shields I found use PWM to control the speed of the motor. What is the best alternative? I would like to use a python library if possible to prevent i2c protocol difficulties.

User avatar
Posts: 15037
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Motor controller

Thu Sep 17, 2015 9:24 pm

The motor driver needs to be matched to the power needs of the motors you want to drive.

Simplest (but least powerful) are L9110S based modules (1GBP from eBay). Slightly more complicated but more powerful are the L298N based modules (4GBP from eBay). See if either of those is suitable for your motors. Each module typically drives 2 DC motors.

All the Python modules will provide PWM on all the user GPIOs on the expansion header. Some Python modules use software timing, some use hardware timing. Hardware timing is better but may not be necessary depending on what you are actually doing with the motors.

My pigpio Python module provides hardware timed PWM.

Return to “Automation, sensing and robotics”