3 Simple Ways to
Share What You Make

With Instructables you can share what you make with the world — and tap into an ever-growing community of creative experts.

PhotosPhotos

Share one or more photos of a project, recipe, or whatever you've made, quickly and easily.

Step by StepStep-By-Step

Share your step-by-step photos with text instructions of what you made so others can do it too!

VideoVideo

Share your how-to video. You'll need your embed code from a video site such as YouTube.

Simple 2-way motor control for the arduino

Step 4How this works & more Ideas

How this works & more Ideas
How This Works:
When you make one pin HIGH & another LOW, the pin that is HIGH has a positive voltage & the pin that is LOW works like a ground(-).

Note: The rotation direction maybe different than below.

Pin 5: Pin 6: Rotates:
HIGH LOW CCW
LOW HIGH CW
PWM: 127 LOW CCW 1/2 Speed

CCW = Counter Clockwise
CW = Clockwise

Ideas:
Add a second motor. Sorry I don't have any code for this, But there is a schematic posted below.
« Previous StepDownload PDFView All StepsNext Step »
2 comments
Feb 16, 2011. 12:41 PMshortcircuitaz says:
I tried this and my motor must be too big or something.. do I need to send any information through the interface to the controller?
Nov 27, 2009. 5:20 PMdaltore says:
It seems to me like this would only be able to drive the motors at a maximum of 1/2 power each when they're reverse of each other.  You could get both to move full-power when they're going the same direction (they share either a common ground or common source), but when they're opposite, you're spending 1/2 of each PWM train on each motor (which at full power, is a 1/2 duty-cycle PWM wave).  Interesting idea though, it's crazy what you can do with microcontrollers these days.

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
43
Followers
15
Author:computergeek