MotorShield with PWM

Adafruit Ethernet, Motor, Proto, Wave, Datalogger, GPS Shields - etc!

Moderators: adafruit_support_bill, adafruit

MotorShield with PWM

Postby longkmt » Mon Mar 11, 2013 10:18 pm

Hi,

I have the same motorshield from adafruit:
Image

For now the motor shield can control up to 4 DC motors, but I need to control two more DC motors. As I know the shield is using 4 PWM signals from 4 out of 6 PWM output pins from the Arduino Uno. Is there anyway we can use the other 2 remaining PWM to control 2 motors using an additional H-bridge circuit?
longkmt
 
Posts: 4
Joined: Mon Mar 11, 2013 10:06 pm

Re: MotorShield with PWM

Postby adafruit_support_bill » Tue Mar 12, 2013 5:24 am

There are a couple of approaches to this:

If you do not need direction control for some motors, those motors can be controlled with just a PWM pin and a transistor.
If you do need both direction and speed on all motors, you could hook up another H-bridge chip with some of the unused pins. Or you could look into some of the serial motor control modules from Pololu.
User avatar
adafruit_support_bill
 
Posts: 15990
Joined: Sat Feb 07, 2009 9:11 am

Re: MotorShield with PWM

Postby longkmt » Tue Mar 12, 2013 1:41 pm

Which PWM pins on the Arduino will connect to the Servo pins on the shield? Are they pin 9 and 10?
longkmt
 
Posts: 4
Joined: Mon Mar 11, 2013 10:06 pm


Re: MotorShield with PWM

Postby longkmt » Tue Mar 12, 2013 4:40 pm

Great, I am using L293d H-Bridge. 2 PWM signals from the Servo will go to pin 1(EN) and Motor Logic 2A (pin 7), I still need one digital pin which will go to Motor Logic 1A (pin 2). I guess I can use pin 4,7,8 or 12 from the Arduino, but I don't know how they are connected to the shield. In other words, I want to know which pins on the shield are connected to pin 4,7,8,12 on the Arduino?!

Image

Thanks!
longkmt
 
Posts: 4
Joined: Mon Mar 11, 2013 10:06 pm

Re: MotorShield with PWM

Postby adafruit_support_bill » Tue Mar 12, 2013 5:27 pm

In other words, I want to know which pins on the shield are connected to pin 4,7,8,12 on the Arduino?!

It's in the FAQ: http://learn.adafruit.com/adafruit-motor-shield/faq
User avatar
adafruit_support_bill
 
Posts: 15990
Joined: Sat Feb 07, 2009 9:11 am

Re: MotorShield with PWM

Postby longkmt » Tue Mar 12, 2013 5:52 pm

Oh thanks a lot!
longkmt
 
Posts: 4
Joined: Mon Mar 11, 2013 10:06 pm

Re: MotorShield with PWM

Postby Zenock » Tue Mar 12, 2013 6:09 pm

Hi:

Would it be correct to assume that all motors, DC and Stepper, must use the save voltage? For instance I couldn't use a 24 V power supply and a 24 volt motor and a 6 volt motor?

Or is there a way one could do this?

Z
Zenock
 
Posts: 3
Joined: Tue Mar 12, 2013 6:06 pm

Re: MotorShield with PWM

Postby adafruit_support_bill » Tue Mar 12, 2013 6:21 pm

@Zenock: All would need to use the same voltage.
User avatar
adafruit_support_bill
 
Posts: 15990
Joined: Sat Feb 07, 2009 9:11 am

Re: MotorShield with PWM

Postby Zenock » Tue Mar 12, 2013 7:53 pm

Could I cut the lead to PIN 8 on one of the chips and wire in a voltage regulator?

Also, If I understand correctly, the servos runs off 5 V even if I'm running the motors off 24 volts? Is this correct?
Zenock
 
Posts: 3
Joined: Tue Mar 12, 2013 6:06 pm

Re: MotorShield with PWM

Postby adafruit_support_bill » Tue Mar 12, 2013 8:49 pm

Could I cut the lead to PIN 8 on one of the chips and wire in a voltage regulator?

Yes. That is possible.
Also, If I understand correctly, the servos runs off 5 V even if I'm running the motors off 24 volts? Is this correct?

Normally true. Although a separate supply for servos is possible as described in the FAQ: viewtopic.php?f=31&t=26873
User avatar
adafruit_support_bill
 
Posts: 15990
Joined: Sat Feb 07, 2009 9:11 am

Re: MotorShield with PWM

Postby Zenock » Tue Mar 12, 2013 9:06 pm

Thank you so much. You are AWESOME.
Zenock
 
Posts: 3
Joined: Tue Mar 12, 2013 6:06 pm


Return to Arduino Shields from Adafruit

Who is online

Users browsing this forum: Google [Bot] and 3 guests

Stuff to buy from the Adafruit store and links to product documentation!


New Products [102]

Raspberry Pi[80]
 
FLORA[23]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[11]
Arduino[60]
 
NETduino[14]
 
BeagleBone[24]
 
Android[6]
 
XBee[10]
More Dev Boards[30]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[33]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[8]


 
Breakout Boards[33]
LCDs & Displays[48]
Components & Parts[69]
Batteries & Power[49]
EL Wire/Tape/Panel[52]
LEDs[109]
 
Wireless[14]
Cables[60]
 
Lasers[6]
Sensors/Parts[145]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[70]
 
iDevices[13]
Tools[71]
 
Wearables[39]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[24]


 
Stickers[41]
 
Skill badges[55]
 
Books[25]
 
Circuit Playground[7]
 
Gift Certificates[4]