L298N + raspberry pi + 3V DC motor

Thread Starter

cfg83

Joined Oct 16, 2020
5
Hello -

I just watched this on YouTube :

Raspberry Pi How to Control a DC Motor With an L298N Driver

The L298N would be perfect for me, except I would be driving a crummy little 3V DC "hobby motor" in forward/reverse.

Question: Will the L298N work for a 3V DC motor, or do I need an "L298N Wimpy" equivalent?

Thank You,
cfg83
 

ronsimpson

Joined Oct 7, 2019
1,024
Will the L298N work for a 3V DC motor
The L298 will work with a 3V supply. It was designed to work at higher voltages. Here will be some voltage loss depending on motor current. You might connect to a 5V supply and the motor will see just above 3V.

I would connect a good 3V to the motor and listen to the sound. Then connect to a L298 on 5V and run at 80 or 90% duty cycle and see if it sounds the same as 3V. Or measure the average voltage across the motor.

Watch what current the motor is rated for.
 

Thread Starter

cfg83

Joined Oct 16, 2020
5
The L298 will work with a 3V supply. It was designed to work at higher voltages. Here will be some voltage loss depending on motor current. You might connect to a 5V supply and the motor will see just above 3V.

I would connect a good 3V to the motor and listen to the sound. Then connect to a L298 on 5V and run at 80 or 90% duty cycle and see if it sounds the same as 3V. Or measure the average voltage across the motor.

Watch what current the motor is rated for.
Ok, this is even better news than I hoped for because I can use the example video as a template for what I try to do.

THANK YOU!!!!

cfg83
 

ronsimpson

Joined Oct 7, 2019
1,024
I like running the motor from a different 5V supply than the Pi lives on. Connect the two grounds together. If the motor stalls it will pull much power and you don't want the supply to collapse and reset the computer. Motors are big hungry power monsters and the Pi (also hungry) should be separated.
 

Thread Starter

cfg83

Joined Oct 16, 2020
5
I like running the motor from a different 5V supply than the Pi lives on. Connect the two grounds together. If the motor stalls it will pull much power and you don't want the supply to collapse and reset the computer. Motors are big hungry power monsters and the Pi (also hungry) should be separated.
Yes, the pi will have a separate power source. I am trying to "intersect" an existing DC motor that runs in one direction only from a 3V power supply. I am sure the motor *will* stall because it runs a toy on the floor that is good at getting stuck, :) :

KidzRobotix SMART CLEANER - YouTube

cfg83
 

Thread Starter

cfg83

Joined Oct 16, 2020
5
Hello -

I couldn't get the L298N to work for this project. I think the 3 volts coming from the motor batteries was too wimpy for the L298N or I failed to duplicate the examples that I studied. I switched to an MX1508 motor driver module. It's simpler to hook up, uses fewer GPIO pins, and is much smaller.

This is a messy picture, but I wanted to hook everything up for testing :

baby_roomba_3a.jpg

And here is the Youtube video of the gizmo in action :

Baby Roomba IoT Proof of Concept

Now I need to clean it up. The long term goal is to control it over a web page with the option to randomize the direction of the motor so that it can escape (most but not all) traps ... Baby Roomba lives!

Parts :

Toy = Smart Cleaner - 4m
https://www.4m-ind.com/product/smart-cleaner/

CPU SOC = NanoPi NEO2 - FriendlyARM WiKi
http://wiki.friendlyelec.com/wiki/index.php/NanoPi_NEO2

Motor controller = h bridge - MX1508 motor driver module - Electrical Engineering Stack Exchange
https://electronics.stackexchange.com/questions/411667/mx1508-motor-driver-module

CPU Power Supply = 5V power supply / 3.7v battery charger culled from cheap USB power brick that features Micro USB for easy connection to Nanopi.

CPU Battery : 3.7v @ 650 MaH battery.
 
Top