Go Down

Topic: My Hexapod walks! (Read 4728 times) previous topic - next topic

Federico

There is the possibility that I am the one that is not understanding :)
Looks like userful to have the possibility to reverse the direction and to trim the position of the servos, so I was wondering why this is not implemented by default...
Federico - Sideralis
Arduino &C: http://www.sideralis.org
Foto: http://blackman.amicofigo.com

mem

The modifications make the code more complicated, and as originally suggested, it doubles the RAM used for each servo.
The servo direction can be reversed without adding code to the library by using the map function in a sketch ( or something like servo.write( 180-pos)
Trim can be changed using the optional parameters that set min and max values to attach.

Vinceherman's modification to change trim is more convenient for him in his application but it may seem odd to some people to have a trim function that results in a command to send a 1500us pulse actually produce a pulse that is not 1500us.

A nice thing about having source code available is that it enables people to customize things to suit their needs. But making code bigger and more complicated by adding features that most people won't use is usually not a good thing to do.

That said, I am all for vinceherman posting his modifcations in a thread for people that want these features.

Federico

Thanks for the explanation, I understand now!
Federico - Sideralis
Arduino &C: http://www.sideralis.org
Foto: http://blackman.amicofigo.com

tarcardoso

I am trying to do one of this too. The objective is to stuty IA. I am thinking to use one arduino to control six servos.
But I am worry to burn the arduino by using 6 standard servo at once.

Could some one give me advice about it?

cr0sh

Quote
But I am worry to burn the arduino by using 6 standard servo at once.


You won't burn out the Arduino using six servos at once provided you give the servos their own independent power source (like a battery pack). Only if you try to pull the current needed completely from the Arduino can you possibly burn something out (which can happen with a -single- servo, depending on the servo's current requirements and load).
I will not respond to Arduino help PM's from random forum users; if you have such a question, start a new topic thread.

vinceherman

#20
Apr 14, 2010, 04:26 am Last Edit: Apr 14, 2010, 04:28 am by vinceherman Reason: 1
Quote
Could some one give me advice about it?


Like cr0sh said, use a separate power source for the servos.

Tie the ground to the board ground and to all the servo grounds.
Tie the hot to all the servo hots.
The data pins go to each servo signal.

This will work for any power source in the proper voltage range.

I used a Bigger Lithium Polymer battery and a voltage regulator to get proper voltage for my servos.  But it is pretty much the same as using 4 AA batteries.

Here is a thread with more info about how I did it.
http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1265626147/6#6

In the first picture, you can see the orange and green wires.  They carry the signal from the 18 pins to the servo plugs.  Power comes from the 2 wires running off the shield.

cr0sh

#21
Apr 14, 2010, 04:35 am Last Edit: Apr 14, 2010, 04:36 am by keeper63@cox.net Reason: 1
Quote
But it is pretty much the same as using 4 AA batteries.


Something else to keep in mind: If you use rechargeable batteries (NiCd, NiMh, LiPo, etc), each cell is usually 1.2 volts, so four AA cells in series will give you 4.8 volts.

Servos are generally designed to run on something like 4 to 6 volts, with their torque, of course, maxing out at 6 volts (don't run them on anything higher, though - you'll burn the driver circuitry and/or motors out).

Standard alkaline AA batteries are rated at 1.5 volts each; so 4 in series will give you 6 volts. If you want to use rechargeables, you will need to use 5 cells in series to get 6 volts, not 4 as with alkalines.

It may not seem like much, but that extra 1.2 volts equals a lot of torque gained or lost.

Unfortunately, I have yet to see a 5 cell AA battery holder...
I will not respond to Arduino help PM's from random forum users; if you have such a question, start a new topic thread.

vinceherman

And with my voltage regulator, I just turn the screw until I get the desired voltage.

tarcardoso

Thank you guys. It was a helpfull explanation

Go Up