0
Offline
Newbie
Karma: 0
Posts: 22
Arduino rocks
|
 |
« on: November 16, 2010, 01:19:12 pm » |
hi everybody, Like I said in the subject, I use pure data(pduino) with an arduino mega and I'd like to control +/- 24 servos for a big project, I want to control several robot musicians,here is a video of the work in progress http://www.dailymotion.com/video/xepro5_robot-drummer-work-in-progress-3_creation but I'm just able to control 14 servos, which is not so bad, but unfortunately not enough for my project, the pins that are working are 2,3,4,5,6,7,8,9,10,11,12,13,14 ....but I'm really frustrated when I see the number of pins on the mega board(more than 50..!!) or should I use two duemilanove? if it's the case, is it possible to use pduino with two duemilanove boards?? thanx manu
|
|
|
|
|
Logged
|
|
|
|
|
Seattle, WA USA
Offline
Brattain Member
Karma: 311
Posts: 35470
Seattle, WA USA
|
 |
« Reply #1 on: November 16, 2010, 03:53:34 pm » |
the pins that are working are 2,3,4,5,6,7,8,9,10,11,12,13,14 What happens on the other pins? What code do you have on the Arduino?
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 22
Arduino rocks
|
 |
« Reply #2 on: November 17, 2010, 07:48:28 am » |
hi, on the other pins, the servos don't move when I try to control them, but I' m able to control leds (switch on or off). the code on the arduino is the StandardFirmata from arduino 0021 Examples
|
|
|
|
|
Logged
|
|
|
|
|
Seattle, WA USA
Offline
Brattain Member
Karma: 311
Posts: 35470
Seattle, WA USA
|
 |
« Reply #3 on: November 17, 2010, 09:43:25 am » |
Perhaps you are not aware that Firmata is not fully supported on the Mega, because it is not aware of all the extra pins that the Mega has.
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 22
Arduino rocks
|
 |
« Reply #4 on: November 17, 2010, 09:57:18 am » |
...and do you know if it's possible to write something to make firmata aware of all the pins, or you think it's not possible to do it? and if it's not possible, do you know a way to control 24 servos with arduino and pure data? two boards synchronized?? :-/ thanx manu
|
|
|
|
|
Logged
|
|
|
|
|
Seattle, WA USA
Offline
Brattain Member
Karma: 311
Posts: 35470
Seattle, WA USA
|
 |
« Reply #5 on: November 17, 2010, 10:04:00 am » |
Firmata is just an interface that maps serial messages to actions on the Arduino. You don't really need to use it.
If you feel that it would make your life easier, you could be the one to step up and make Firmata Mega-compatible.
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 22
Arduino rocks
|
 |
« Reply #6 on: November 17, 2010, 10:13:05 am » |
When you say I don't really need it, you mean that I could use another code on the arduino? For sure it would make my life easier to have a Firmata Mega-compatible... I wish I could, but I'm not good enough...I tried but... :-/
|
|
|
|
|
Logged
|
|
|
|
|
Seattle, WA USA
Offline
Brattain Member
Karma: 311
Posts: 35470
Seattle, WA USA
|
 |
« Reply #7 on: November 17, 2010, 10:19:49 am » |
you mean that I could use another code on the arduino? Yes. You can write your own sketch to handle the messages sent by PD.
|
|
|
|
|
Logged
|
|
|
|
|
0
Online
Tesla Member
Karma: 50
Posts: 6536
Arduino rocks
|
 |
« Reply #8 on: November 18, 2010, 04:02:52 am » |
You could get a servo controller like the ssc-32 (~$40) to handle the servo operations and just control it from the arduino.
|
|
|
|
|
Logged
|
|
|
|
|
Greenwood, Indiana
Offline
God Member
Karma: 0
Posts: 508
Arduino rocks
|
 |
« Reply #9 on: November 20, 2010, 07:26:04 pm » |
You could use a demultiplexer to switch one PWM to many. You would be using it to pick which servo to send the pulses to. The only limit would be the time it takes to switch the chip to the servo and then to send the PWM to the servo. The downside is that you can not sustain a PWM, when you switch it to the next servo the previous servo will no longer be getting any PWM.
|
|
|
|
|
Logged
|
If it was designed by man it can be repaired by man.
|
|
|
|
|