![]() |
How do you sync multiple motors?
Our team is playing around with parts from last years robot and have been experimenting with multiple motors and 4 wheel drive but we need to synchronize the motors.
Is there an easy way to do this so that the motors on each side are running at the same speed? We have one victor per motor and the victors per each side are sent the same PWM data. Is this just a matter of calibrating the victors? Please advise Thanks |
Re: How do you sync multiple motors?
Well if your willing to get more parts, encoders work wonders on syncing motors to run the same speed. As far as I know, if you don't buy any more parts, I don't think you can get them EXACTLY the same. because no motor is exactly the same.
Someone correct me if I'm wrong though :P |
Re: How do you sync multiple motors?
You could use encoders or a gyro to solve this problem and ensure that your drive straight.
|
Re: How do you sync multiple motors?
Quote:
This whitepaper from Team 33 provides an excellent guide to setting up a gyro. |
Re: How do you sync multiple motors?
I would definitally suggest the gryo. It is quite a bit easier to use becuase you don't need to use interupts in the programing.
However, either route will take a lot of programing to get to work correctly. Alex |
Re: How do you sync multiple motors?
Quote:
|
Re: How do you sync multiple motors?
If the motors that are on the same side are of the same type, and you are feeding them the same PWM values (you could use a Y-cable from a single PWM output to make sure of this), and your Victors are both calibrated properly, then any difference between the speeds of the motors can be considered negligible and won't have an impact on performance.
Clarification edit: This answer is assuming the original question is about synchronizing the speeds two motors on the same side of the robot. |
Re: How do you sync multiple motors?
Quote:
The solutions presented previously work great. Whether you use encoders or a gyro, they essentially provide feedback to your program on the speed each wheel is turning so that your program can dynamically adjust the pwm values to maintain a desired setting. In the case of going straight, your program would make sure that each wheel is turning the same speed which ultimately ensures you drive straight when you want to drive straight. Another sort of wacky way we've played with works, but is more useful as an exercise than a practical way of controlling your robot. After we put our robot together, we used a strobelight tachometer and got the wheel speed of each wheel at each PWM value. We input this data into a spread sheet and plotted the results to visualize the curve. These data form the power curve for each wheel and includes losses to the power train. From this you can calculate an equation for each side that coverts pwm value to speed so that each wheel recieves the appropriate pwm input for a desired wheel speed. While this worked and was interesting academically, it isn't likely to last for long. Changes in the drive train would eventually invalidate the curves. Feedback mechanisms (Gyro/encoders) coupled with PID code work the best because regardless of wear and tear on your drivetrain, or even replacing entire components, your program will still compensate dynamically. |
Re: How do you sync multiple motors?
Quote:
Alex |
Re: How do you sync multiple motors?
Quote:
Now, if it's two different motors on the same side, you've got about 30 days to start designing a gearbox so they'll be the same speed. |
Re: How do you sync multiple motors?
Quote:
We have two motors on the right side of the robot and two motors on the left side of the robot. This is a 4 wheel robot and each of the four wheels is driven by it's own motor. First we would like to make sure that the wheels on each side are operating at the same speed. We have seen that even though both motors operate from the same PWM values, each motor tends to have unique characteristics and can operate at slightly different speeds. This can cause slight binding when both wheels on one side of the robot are not "in sync" speed wise. We have calibrated the victors to our joysticks and this has helped tremendously. Second, we would like to ensure that both sides operate at as close to the same speed as possible so that the operator doesn't have to compensate much with relative joystick positioning to make the robot track straight and true... Hope that the above description is not too ambiguous... thanks |
Re: How do you sync multiple motors?
Ok so to recap what people more experienced than me said here:
Regarding syncing two wheels on the same side, you can:
Regarding syncing the left wheel set to the right wheel set, you can:
Good luck and don't hesitate to ask for clarification about anything or for more help! -Leav |
Re: How do you sync multiple motors?
Has anyone here tried using the current sensors to do load balancing? If so, did it work well?
The basic concept would be to pull current information off of each motor, and use it to approximate the torque per motor. Then adjust the voltage sent to the motors so that they are contributing equal torque. This only syncs the left side with itself and the right side with itself. It does not handle syncing left to right. For the experts here: Can you please comment on how this balancing scheme might be impacted by motor variation? drive train variation? phase of the moon? |
Re: How do you sync multiple motors?
I think this would fall under the calibration idea, since as time went by the coefficient between the current and the speed would change and the whole system would go out of sync...
but that just off the top of my head.. the whole "breaking in" and "wearing out" effect i'm considering might only be significant to change the whole system by 0.5%, which means that the system would actually stay in sync for a long time... unless someone did this before and tested in thoroughly there is no real way to know this but checking! -Leav p.s. you would need to check what happens when there is maximum current and zero speed (i.e. the motor stalled [e.g. a pushing match]) p.p.s don't you love recursive brackets? :) |
Re: How do you sync multiple motors?
Quote:
One of the most significant characteristics of any electric motor is its unloaded (free) speed at rated voltage. Let's take the CIM motor as an example: per its manufacturer's data sheet its shaft will spin freely at 5310 RPM when 12V dc is supplied to its electrical terminals. Zoom in to view the table in the lower left corner of the data sheet linked above, and you will see that the manufacturer also states that the variation on the given free speed is +/- 10%. This variation is caused by differing strengths of the motor's permanent magnet material from one batch to the next, and by angular misalignment of the motor's commutation brushes with respect to those magnets. The graphs shown next to the table on the data sheet linked above indicate that the CIM's current draw is proportional to the torque developed on its shaft. The constant of proportionality (i.e., the slope of the current vs. torque line on that graph) is determined by the same design factors, and the same variations, that determine the motor's free speed. So the stated +/- 10% free-speed variation applies to torque-per-Ampere also. Because the causes of the variation are the same, using current sensors to 'correct' for free speed variation is probably not going to be very effective. |
Re: How do you sync multiple motors?
Quote:
|
Re: How do you sync multiple motors?
Quote:
|
Re: How do you sync multiple motors?
just to reiterate what others have said above me...
if you know the left side wheels are spinning the same speed as the right side wheels, your robot is more than likely going straight how do you make sure your wheels are spinning at the exact same speed? richard made it clear that its almost guaranteed your motors will not be running at the same speed, so...using an encoder to check the wheels speed would most certainly make sure your robot is going straight. |
Re: How do you sync multiple motors?
Quote:
First assumption is that the floor (plane of travel) is perfectly flat, which will not happen on a carpeted arena surface. Second assumption is that all wheels on the robot are the exact same size. This also will not be true, as variation in tread, tread attachment, or runner molding will create variances. It gets even worse with pneumatic tires ;) If you intend on going only a short distance (under 10') then the error encountered by the above will probably not affect your performance, but going further will reduce your accuracy possibly to the point where you will miss your intended target zone. And none of this takes into account field obsticals(sp?), other robots, or wheel slippage. To ensure you are going in the direction you wish to go in, the best ways (IMHO) are a gyro, a compass, or something like an optical mouse. |
Re: How do you sync multiple motors?
Quote:
Thanks for the info... I have a power induction timing light that I use on timing automobile engines.... How might I connect this to the robot to measure/reference one of the wheels? Would I connect it to 12v & ground and place the induction pick up coil around the positive motor lead and then draw a line on one of the wheels and the chassis for a reference point? Please advise- any tips would be greatly appreciated thank you! |
Re: How do you sync multiple motors?
Quote:
294, and many other teams have used encoders to traverse in autonomous rather accurately; A gyro certainly helps, but it can be done without one. |
Re: How do you sync multiple motors?
Quote:
|
Re: How do you sync multiple motors?
Quote:
The best way I can think of to eliminate the most potential problems is to run encoders on a non-driven, relatively hard, wheel. Wheelspin is no longer much of an issue, hard tires wear slowly (and if they wear too much, a little math in the code can easily correct for them getting smaller), and backlash can be more easily minimized since you would have far fewer possible sources of it. |
Re: How do you sync multiple motors?
Quote:
Agreed. And as the design engineer you need to decide which (mix?) of sensors will provide the accuracy for the task at hand. My initial response was aimed at making sure that teams don't just "slap on" a few encoders and assume all will work. Design in the sensors you need for the task at hand, and understand where your innaccuracies will come from. From there it's just a matter of limiting those inaccuracies and determining if the system you designed is accurate enough for the task at hand. |
Re: How do you sync multiple motors?
Quote:
If you choose to use the timing light option, keep in mind that it is the least effective of all the options presented thus far for a variety of reasons (all discussed previously). I don't think an automotive timing light will work (I could be wrong) because it is typically triggered by the car's ignition system so that you get a flash every time the engine's #1 cylinder receives a spark. You need a strobe that is adjustable such that you can change the speed of the strobe to match the periodicity of the spinning object (the wheel). Step by step for each wheel; robot on blocks; repeat forward and reverse: 1. Send a PWM value to the motor. 2. Wait for equilibrium. 3. Adjust strobe light until wheel appears to "stop". Be aware of harmonic frequencies: If the wheel is spinning at 100 rpm, the strobe will freeze the scene at a number of other possible frequencies. A single mark on the wheel will help eliminate some of the possibilities. 3. Note the PWM/wheel RPM values on your favorite spread sheet. 4. Increase PWM value (say by 5) and repeat until you maximize/minimize. Once you have plotted the values for every wheel, you can now estimate how fast each wheel will turn for a given PWM value. In your program, you will take a joystick value to be a desired speed, then figure out what signal each wheel needs to match that speed. This will work for a little while, but the more you drive your robot, the more changes will occur in the drive train components, which will lead to decline in reliability. Also you can see it is labor intensive to use this method. You really should consider using a GYRO! Hope this helps. |
Re: How do you sync multiple motors?
Quote:
This will also help you figure out what actually needs to be fixed. List all of your error sources and their contribution. You will end up with something that says "I can afford N% error, and right now I have a maximum of M% error." Then start chipping away at the important ones. Don't compensate for Jupiter's gravitational pull before you make sure that your motors spin equally well forward and backward. Pots being affected by EM fields? Probably not a big deal. Getting hit by another robot? Probably a big deal. Lastly, always remember that physics is a cruel mistress. She is out to get you. She is a bully. However, you can deal with bullies in two ways: Confront or Ignore. Ignore her minor grievances, save your energy for when she gets really out of hand. |
Re: How do you sync multiple motors?
Our team approaches this problem in a different way, and we have never had a problem with it. It works kind of like this, put two motors on one wheel (use a gearbox) and then use chain or a timing belt to link the two wheels (or, if you are really fancy, tracks!). Do this on both sides and the two motors act like one super powerful motor.
If you've never heard of us, we're the team that can push everyone else (well, almost everyone) |
Re: How do you sync multiple motors?
As Pat stated above, when it comes to motors on the same side there is no need to worry. If the gearbox ratio from the motor to the wheel is the same for each wheel then they will end up going the same speed. Any slight differences will not cause any binding.
As for making the robot go straight by balancing the two sides. Our tried and true method is to throw the motors on, setup the joystick trims and let her rip. If the robot goes straight you are done! If it doesn't then you can start using the encoders and gyro that you have designed into your drivebase along with some fancy PID programming to make that robot go straight. If you don't need the encoders and gyro to make the robot go straight don't fret. Your time is not wasted. They will always come in handy when you start programming autonomous modes. Good Luck! |
Re: How do you sync multiple motors?
Quote:
|
Re: How do you sync multiple motors?
Japper,
In your original post you asked how to synchronize the motors on one side of the robot. In reality, if both front and back wheels on the same side are driven by similar motors with the same PWM value and both speed controllers are calibrated the same and the tread on similar sized wheels have a reasonable friction to the playing field surface, then the motors will drive the same speed. The only way they could not drive the same speed is for one of the wheels to be slipping. The next step in complexity would be to use wheel encoders at both wheels with some software loop that allows you to modify the PWM values sent to the respective wheels. If the desire is to run straight and have all four wheels in sync then know that this is a mutually exclusive result. Running straight and in sync rarely occurs. It is more accurate to use a gyro system to run straight. However, the gyro does not give you distance traveled, so some form of wheel rotation sensor is still needed to run straight and to a specified distance. Current monitoring on individual drive motors will give you no useful information unless you can correlate drive current and loaded speed on a motor by motor basis. The variations in motor construction (magnetic field, internal temperature, winding resistance, brush resistance, etc.) will affect the output loaded and unloaded speed of a motor. However, the transmission ratios will also be a determining factor in the wheel rotational speed. The inductive timing light is triggered by the high voltage pulse that feeds the sparkplug. The pickup is actually a transformer where the sparkplug wire is a half turn primary winding. Since you have nothing on the robot that is in the 30kV range, there is no way to trigger the timing light. The Banner sensors shining into a simple interuptor attached to the wheel make an excellent speed sensor. You can make a simple attachement for each wheel using a CAD program to draw a segmented circle with alternating light and dark areas. Divide your wheel into eight segments (four light and four dark) and you can get 16 transistions per rotation using this method. With a six inch wheel, this could give you resolution to a little over an inch of travel. Using two Banner sensors you can actually determine wheel direction as well. |
| All times are GMT -5. The time now is 22:51. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi