PDA

View Full Version : Hexapod in vertical surfaces



alvaromonty
04-10-2018, 05:07 AM
Hello,
I have a Phantom Ax hexapod Mark III and I am doing a project in which the robot need to walk vertically, I have solved the problem to fix to a surface. The problem is when the robot is going to move a coxa, there is a momentary time in which the servo lost the power and it falls, for that is not moving forward. Can somebody help me? best regards.

KevinO
04-10-2018, 01:20 PM
Are you sure it isn't an overload due to trying to support all that weight? Dynamixels shutdown if it exceededs its torque limit.

KurtEck
04-10-2018, 03:32 PM
I agree with Kevin... Also maybe power issue?

When you try to move it, do any of the servo LEDS light up?

Wonder if you might be able to do some query of the servo for error conditions? If you are using individual writes to the servos, than the status packet (assuming you have not disabled them), will have a status code, which includes information like torque error or overheat error... But if your code (like the Phoenix code base), is using SyncWrite to output all of the servos positions in one packet, than you would need to query the servos or the like to get this information.

alvaromonty
04-11-2018, 05:17 AM
Thank you for your quick response,
First of all, the code I'm using is the example code that comes in the guide, I think it's not the Phoneix.
I labeled the servos with the Dynamanager application, there is no error information coming in.
How can I see the errors or torque information?
Best regards.

KurtEck
04-11-2018, 06:25 PM
Which guide? Could you post a link or the like, so I have an idea of which code you are using...

Are you working off this page? http://www.trossenrobotics.com/phantomx-ax-hexapod.aspx

If so again there are links to the Phoenix code here (Personally wish they would go to my Phantom_Phoenix project instead of the Phoenix in Parts project...

Or are you going to the PyPose type code... It has been a long time since I looked at the pypose code... So not sure what way they do it.

How to get the error information, depends on which library and how you do the code...

That is if the code individually sets the goal position for each servo, than likely these set commands will generate a response packet.

The information is in the different manuals for the Servos... That is the list of registers of the AX servo is shown in:
http://support.robotis.com/en/techsupport_eng.htm#product/dynamixel/ax_series/dxl_ax_actuator.htm

The actual format of the packets (protocol 1) is shown in: http://support.robotis.com/en/product/actuator/dynamixel/communication/dxl_packet.htm

The response packet, shown in the 2nd link, is typically sent back from the servo whenever you do something like set a register or registers. One of the fields in the response is an error byte, which has information like overheat...
How to retrieve depends on the code being run. That is many places that set a register throw away the response packet... Others might save the error value into some global variable, which you can query...

alvaromonty
04-12-2018, 03:13 AM
The code that I am using is https://github.com/Interbotix/HexapodMKIICommander/tree/master/Hexapod_Mark_II .
I am going to try to look for the errors fllowing your links.

Thanks.

KurtEck
04-12-2018, 08:44 AM
Ok that Is some of the original Nuke code base...

The code all flows to using the bioloid library to do the step interpolation... It looks like it has not been touched up on Github since Andrew added it 5 years ago...

So my guess is you are running this on Arduino 1.0.6? With probably the hardware and library in the github arbotix library?

Then the moves funnel down to: https://github.com/Interbotix/arbotix/blob/master/libraries/Bioloid/BioloidController.cpp#L83

If you look at the writePose function, it is doing one broadcast SyncWrite message to update the position of all of the servos. This is also what I normally do (I have my own version of libraries). But if you look at the links above, you will notice that you do not receive back a response packet on broadcast messages.

If I remember correctly these are the only messages sent during the walking, the code will loop in interpolateStep function (https://github.com/Interbotix/arbotix/blob/master/libraries/Bioloid/BioloidController.cpp#L124) for each part of when it tries to move the servos from one position to the next (Each calculated position).

That is if you look at your main loop function of your sketch, you will see that it checks for any new messages from the commander, it then checks to see if it is currently interpolating (if no, calculate new positions and start that move)... But the more interesting part is the last line that does the call to interpolateStep.

Now how to get the state of the servos? You might get away with adding in a servo value just before or after the call interpolateStep... Maybe setup to rotate through each of the coxa servos... Could for example check the current voltage on that servo...
If my old copy of their code is correct they don't have any table of servo ids, but instead hard code the IK one leg at a time... So I am just
showing for RF_COXA...


uint8_t current_voltage = ax12GetRegister(RF_COXA, AX_PRESENT_VOLTAGE, 1);
uint8_t error_code = ax12GetLastError();

In here you might check the current voltage, if it is too low, you know there may be an issue. When the getRegister completes it stores any error code byte in to a variable that the get last error function returns...

You may also or instead may want to look at the temperature of the servo: AX_PRESENT_TEMPERATURE

As these two registers are consecutive, you might read both One read starting at VOLTAGE, for 2 bytes. It will return the registers into 16 byte value assuming that the first byte is LOW value and 2nd byte is HIGH value (like goal positions...) so you can the byte values from the return value...

But again, if this is a metal MK3 with probably the large battery... I again am with Kevin, I doubt that the AX12 (or AX18) servos have enough torque to be able to lift the hexapod up vertically.

alvaromonty
04-17-2018, 09:01 AM
I have seen that when the robot stay some time walking, the led of the servos blink and the robot fall down. I have checked it with thermography and the servo heat a little. I don't know if it's normal behavior.

KurtEck
04-17-2018, 10:11 AM
Again it sounds like thermal shutdown... Luckily with AX servos I think most of the time the servos are not damaged... But I believe that may not always be the case with some other higher priced versions.

As I mentioned, I am surprised it works at all. Would be interesting to see picture/video.

Also before you get errors, you might also again look at the AX_PRESET_TEMPERATURE of the servos and see what they say they are hitting.

Not sure how much it would help, but I remember seeing some threads, where people did some different things to cool some servos. This included things like tying to add a heatsink or adding a fan... But of course each thing you add, adds weight, which also makes it harder.

Also don't know what form of walking gait you are using. Maybe some are better than others to help minimize the stress on the coxas. That is maybe having most if not all legs on ground before it moves the coxas as to hopefully distribute the load.

KevinO
04-17-2018, 11:52 AM
I believe the problem is on a vertical surface ALL the weight is on the coxa's including the legs themselves. Where on horizontal that load is supported by multiple servos.

hoanglanjvb
04-21-2018, 04:46 AM
Wonder if you might be able to do some query of the servo for error conditions? If you are using individual writes to the servos, than the status packet (assuming you have not disabled them),

KurtEck
04-23-2018, 09:16 AM
Again I am guessing that there is a thermal shutdown of the servo.

As Kevin mentioned, when you are in a vertical position the Coxa servos are having to support all of the weight.

My (ex)Math skills are really rusty, but have you calculated how much torque you are needing these servos to support?

Things like center of gravity or ... I would probably start off doing some simple calculations, like weigh the whole robot and then maybe divide that by 6 (all legs on the ground) and maybe 5 (one leg off the ground). Then I believe there is a simple calculation to take this and also use the calculated leg length (how far is the tip of the foot away from the servo) and calculate the torque.

Then look at the specifications of the servos, example AX-12 says it has a stall Torque(Nm) 1.5 at 12v... (And a stall Current of 1.5 amps).
How close are you to these maximums?

I believe that it is recommended that you do not typically exceed 1/5 of the stall torque. Hopefully there are others up here who know more about these limits.

Also depending on your setup, I don't know if maybe adding something to relieve the stress on these servos like Springs would help? Again others may be able to help if they saw more of your design. But maybe assuming standard(ish) hexapod, adding springs that are above the servos (when going in the up position), might relieve some of the pressure. May have to be careful on how much spring, as what happens when the foot leaves the ground?

Again it would help verify the thermal issues if you had the code try to read the servo current temp during the loops and maybe see what they are doing.

A I mentioned, highly probable that you are overheating the servos and they are going into thermal shutoff. But could also be power issues.

That is if all of the servos are running at maximum stall torque, maybe your power source is being strained, the voltage drops, and one or more processors reboot...

alvaromonty
04-26-2018, 03:41 AM
Ok, thanks for your answer, I will check your advices. The thin is why the leg fall down before up, the five legs that are in contact with the surface support the weight, and the leg that is going to move is able to move up an down.