Hi. I have a working robot project that uses Pololu micro serial servo controllers to control the servos. The poor robot has a tendency to get stuck in places, and when it does it can end up drawing a huge amount of current and damaging itself since the servos are unable to reach the position they are being controlled to.
Any advice? I would really like to limit the torque of the servos under most circumstances, only driving them to their maximum when it’s really needed.
Unfortunately, our servo controllers do not support torque limiting or current sensing. You might stick some resettable fuses in line with your servo power supply (you might need to put one on each servo individually if the normal operating current of the group is close to the stall current of one servo).
Why not do both! You could limit the current to each servo to protect them with individual polyfuses on their power lines, and limit the total current draw with a big main polyfuse to protect your power source.
Jameco has a nice little selection of polyfuses here, and no minimum order.
So what kind of servos are you using? And what kind of robot for that matter? Is it getting stuck in the mud, or like stuck in the fibers of your carpet? Both can be robot deadly!
Thanks for confirming what I was afraid of. It’s a snake robot getting stuck on bumpy foam terrain.
After burning out a few power supplies (cheap power supplies I guess) I’ve got a fuse on the main supply, so at least that issue seems to be taken care of. It still might be nice to have current sensing though, since part or all of the robot stopping is not the most desirable failure mode.
Any suggestions for adding current sensing? It seems like hall effect sensors would be one option, and measuring the voltage drop across a calibrated length of wire would be another. Either way it seems messy since I have 20 servos.
The typical approach to measuring the current drawn by a motor/servo/whatever is to put a low resistance, high precision “Current Sense” resistor in-line with the power for the device, usually between the device and ground. There is a minuscule voltage drop across this resistor, proportional to the current flowing through it. In most applications this voltage is too small to be directly measured by an analog input, so it has to be amplified through some sort of op-amp circuit.
You can get resistors and IC’s specifically meant for current sensing, just search on Digikey for “Current Sense Amplifier” and “Current Sense Resistor”. If you don’t have 20 free analog inputs lying around you’ll probably also want a few dedicated A/D converter chips. Search Digikey for “A/D Converters (A-D)” and choose whatever your most convenient interface is (serial, SPI, I2C, etc…). I wouldn’t call it messy, but it is certainly complex, especially if you ever want to transition to tetherless operation of your robot.
I’ve worked on a couple of snake-robot projects, one which was servo-based, and we investigated using current-sensing to measure the torque at each servo, partially for protection, but also for feedback for climbing algorithms. We ended up just getting better servos that could take the abuse without damaging themselves (physically or electrically) and it actually worked great! I think the HS-645MG was the cheapest indestructible servo we tested, and better servos saved us money in the long run because we never had to swap out broken ones, but spending $800 to replace all your servos may not be a good solution for you.
Can you post some pictures of your robot, or better yet, does it have a website?
Thanks for the advice. That definitely seems like a more sensible solution than what I was thinking about, and the total cost isn’t bad at all.
The robot is an inherited project, and I’m just trying to make sure that everything makes sense and sort out any rough edges I can at the beginning. The servos are HITEC HS5955TG, and as far as I can tell they are pretty indestructible (and are capable of impressive torque). It’s the rest of the structure of the robot that could use work, but my focus is on the control aspect not the physical design.
Current sense would be valuable in order to get that much more robot state information, though I think I will leave it be for the moment due to time constraints.
As of right now I don’t have any results, but I will be sure to post them when I have them. I think there may be some past results on this robot, but I don’t have them at the moment.
Yow, yeah, just about any other servo would be a serious downgrade for you. Let me know if you ever manage to damage one of the Hitec TG servos.
If you’re interested in getting information from your servos for control purposes, some (all?) of the Hitec digital servos support what they call the HMI protocol. Information about this is really hard to come by, especially with the current state of the Hitec website. Best description I can find online right now is here.
My understanding of it is that if you send the servo a 50 microsecond (not milisecond) pulse on the signal line, it will respond with a pulse width-proportional to its current position. I’m pretty sure this means its actual measured current position (as opposed to the last commanded position) because the Hitec software uses it to record poses of the Robonova-1 robot. If you want to use your own microcontroller to generate the servo position signals, you could periodically read back the actual servo position, and if the measured position is different from the commanded position for a period of time you would know that the servo was stuck. It’s not necessarily a less complicated idea, it’s just a different one.
So, fishing for more information, where and in what capacity are you doing this project? I.e. Student working at X research lab at Y university on project Z.
Good to know about, I hadn’t realized that capability was there, and it’s exactly the information I’d like to be able to get out of the servos. I will talk to some people who have more microcontroller experience than I do about how quickly things could be setup. I have 10 weeks for the project (it’s a summer thing), so I only want to spend a week or two messing around with the hardware before getting down to the meat of the project. Also the Hitec PDF quoted an error rate of 10%, which is a little higher than I might like, though it’s obviously way better than not having any feedback.
The project is to use a machine learning control approach to try to get the snake robot to cross rough terrain. What specifically will end up working I couldn’t tell you since I’m just getting started (here’s hoping something does). It’s a Stanford project under Andrew Ng, and I’m the student working on it over the summer. I’ve got a CS background, so I’m a bit out of my element with all this hardware stuff. Thanks for the help!
Yeah, 10% probably wouldn’t be good enough, plus they’re very vague about which servos have it. In the past I read on their website that all their digital servos had the HMI feature, then I saw something recently saying only the “Robot Servos” had it. I just found someone else’s website saying they called up Hitec and “only the 8498 robot servo supports the HMI protocol at this time.”