[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4756: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3891)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4758: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3891)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4759: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3891)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4760: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3891)
Hacker.instanet.net • View topic - L298N Motor Drive Board

L298N Motor Drive Board

Anything Arduino

L298N Motor Drive Board

Postby Tim Laren » Sun Nov 27, 2011 6:51 pm

Image
Tim Laren
Site Admin
 
Posts: 137
Joined: Thu Mar 04, 2010 8:25 pm

Re: L298N Motor Drive Board

Postby Tim Laren » Sun Nov 27, 2011 11:02 pm

Image
Tim Laren
Site Admin
 
Posts: 137
Joined: Thu Mar 04, 2010 8:25 pm

Re: L298N Motor Drive Board

Postby hseidema » Mon Feb 04, 2013 10:41 pm

For anyone who wants to use this for 4 pin stepper motors, and is frustrated by the availability of info on the internet for this board, it's very simple:

Leave all breakers pins connected (ENA and ENB automatically tied to 5V).
Connect 5V and Ground from your Arduino to the 5V and GND pins on the main header row.
Connect the IN1 IN2 IN3 and IN4 pins on the main header row to any 4 digital pins on the arduino board.
Supply your supply voltage to to the VCC screw header (or 5V if you're using a 5V power supply or supplying from the arduino), and probably a good idea to connect the supply ground to the arduino ground as well.
Connect your 4 pins of the stepper to the A1, A2, B1, B2 pins on the board, and make sure that your motor leads are connected to the matching headers on the board.

Now that you're all hooked up, you can use the built in Stepper library on the arduino. Instructions for that can be found here: http://arduino.cc/en/Reference/StepperConstructor

Like I said, pretty simple, but if, like me, you still would like to have had a really quick and easy how-to: there it is.

Cheers
hseidema
 
Posts: 1
Joined: Mon Feb 04, 2013 10:31 pm

Re: L298N Motor Drive Board

Postby llb@knightscope.com » Wed Jul 23, 2014 4:36 pm

Hi, and thanks for the code above! It's awesome

So I am using the L298N to drive two linear HAD1 linear actuators (12V each and a no-load drive current of ~950mA each)
http://www.alibaba.com/showroom/mini-li ... -had1.html

I am also using a current sensor per motor to get feedback of what the motor is doing (only sensors I have available, but I can detect of the motors are moving or stopped). I am using two ACS714 current sensors. The supply voltage for each is 4.5V to 5.5V and Supply Current is 10mA to 13ma:
http://www.pololu.com/product/1187/specs

And Here is the circuit diagram that I made for my actual setup (an Arduino UNO, two current sensors, to linear actuators, and one motor drive):
https://www.dropbox.com/s/ouxfrcutw5lcj6a/Actuator.jpeg


Will this setup work? Will I have enough current/power coming out of the 5V of the arduino to power both the L298N logic and the two ACS714 sensors?
llb@knightscope.com
 
Posts: 1
Joined: Wed Jul 23, 2014 4:04 pm

Re: L298N Motor Drive Board

Postby Tim Laren » Wed Jul 23, 2014 11:20 pm

The L298N Modules I have have an integrated 5V Regulator that will supply about an Amp. You can run the Arduino and all your sensors off that.
If you are not using that board and using the Arduino to supply the current then you are limited to less than 500 ma including the UNO itself.
Either way I think you are safe.
Image
Tim Laren
Site Admin
 
Posts: 137
Joined: Thu Mar 04, 2010 8:25 pm

Re: L298N Motor Drive Board

Postby jerryleblanc56 » Tue Jun 23, 2015 1:15 pm

I am building a project with the Tamiya dual-drive geared motors and they cannot handle much power.
You're only supposed to drive them with 3V
You suggested speed control via the Arduino PWM but it's not clear if I can set a lower limit on the voltage.
Should I look for a different motor controller to avoid burning my puny motors?
jerryleblanc56
 
Posts: 1
Joined: Tue Jun 23, 2015 1:09 pm

Re: L298N Motor Drive Board

Postby Tim Laren » Tue Jun 23, 2015 4:44 pm

What PWM does is turn on and off the voltage very fast. The ratio of that on to off period changes the voltage 'seen' by the load (motor). If you have the PWM set at 10% then the motor will 'see' .5 Volts. If you set in software the max PWM value at 153 then the motor should never see more than 3 Volts.

The LandShark kit I have was originally designed to use 4 AA batteries or 6 Volts. I have tested it with two 3.7 V LiPo batteries and just limit the top motor speed/power and have run the two test cars for several hours with no sigh of motor damage. The motors on the LandShark are rated at 3-6V.

Tim
Image
Tim Laren
Site Admin
 
Posts: 137
Joined: Thu Mar 04, 2010 8:25 pm


Return to Arduino

Who is online

Users browsing this forum: No registered users and 2 guests

cron