(inverse)-kinematics

Post all your hardware and software upgrades/projects here.

(inverse)-kinematics

Postby rpcook » Mon Jan 07, 2013 9:29 pm

My brain's getting itself in gear to make my Hexy do some awesome things, but I don't have any experience programming robots. I'm hoping that my Engineering Mechanics/ Dynamics lectures should suffice to walk me through the kinematic side of things (determining where limbs/feet will be for a given set of control inputs), but I'm going into totally new ground with inverse-kinematics (determining the control inputs necessary for a given position of limb/foot).

Two branches here then:
Kinematics
  • What are the centres of rotation for the "hips" of a Hexy (ideally from an obvious point on the body) in Cartesian co-ordinates (in mm if possible)?
  • How long are each of the sections of the legs (from centre of rotation to centre of rotation)?
  • What have I forgotten to ask regarding making a kinematic model of a Hexy?
Inverse-Kinematics
  • What are good online resources for learning about inverse-kinematics?
  • Does anyone have any clever ideas for algorithms to determine an exact solution to the problem, given the non-trivial nature of this beastie?
  • What have I forgotten to ask regarding making an inverse-kinematic model of a Hexy?
Rob
A record of my exploits and musings with Hexy and Sparki: http://robcook.eu, content available under a Creative Commons license.
rpcook
 
Posts: 121
Joined: Tue Sep 04, 2012 6:42 pm
Location: Luton, UK

Re: (inverse)-kinematics

Postby ss023459 » Tue Jan 08, 2013 3:59 am

I was going to take a relatively simple approach by using this simple example for the ankle and knee http://www.openprocessing.org/sketch/553. This will place the foot in a plane of x & z dimensions (or y & z depending on how you view the hexapod I guess). Then all you have to do is calculate the angle for the hip (using atan) to place in the y (or x) dimension.

If you play with the simple model from the URL above you get a sense of how the restricted movement of the servos (say +- 80degrees) will limit the points that the foot can reach. i.e. in the plane defined by x & z you will loose a lot of freedom to hit points in the upper right and lower left quadrants. However I think I only care about the lower left quadrant for placing a foot accurately.

This I believe will be a good enough approach to get hexy moving about using inverse kinematics....

Like the original post requested it would be good to get accurate dimensions for the legs and centers of rotations.
Could someone at arcbotics deliver these?
ss023459
 
Posts: 11
Joined: Thu Dec 27, 2012 2:46 am

Re: (inverse)-kinematics

Postby alanford » Tue Jan 08, 2013 3:09 pm

As for dimensions, I believe the STL files are available on Github. With Meshlab you can make fairly accurate measurements
of the dimensions you want. I've used calipers on my hexy and matched up well with the STL files (to within ~0.2 mm, if that's good enough for what you need). If all else fails, it looks like Github (https://github.com/ArcBotics/Hexy) also has CAD files,
although they may not be compatible with your specific CAD software. A CAD package should be able to pull any dimension you want from the files.
alanford
 
Posts: 9
Joined: Fri Dec 14, 2012 10:23 pm

Re: (inverse)-kinematics

Postby rpcook » Fri Jan 18, 2013 1:24 pm

I've made my first steps along the road to getting some Inverse-Kinematics going for Hexy (credit for the closed-form solution goes to one of my work colleagues with a giant space brain). I've written a post here. Not yet implemented this in a Hexy controller, but it looks like we're snowed in this weekend, so I've got time to fiddle :)
Rob
A record of my exploits and musings with Hexy and Sparki: http://robcook.eu, content available under a Creative Commons license.
rpcook
 
Posts: 121
Joined: Tue Sep 04, 2012 6:42 pm
Location: Luton, UK

Re: (inverse)-kinematics

Postby LuisSala » Sat Jan 19, 2013 2:39 am

The approach I've been mulling around is to port the Phoenix Hexapod code over to either Servotor or a standalone library in either C, Objective-C (for iOS) or JavaScript (which I would use with Node and/or Phonegap)...

Phoenix already has all the complex maths figure out and seems to allow you to define parameters such as leg position, segment lengths and so-forth...

Might be worth exploring.
-- Luis
LuisSala
 
Posts: 61
Joined: Mon Dec 17, 2012 6:23 pm

Re: (inverse)-kinematics

Postby yugpmoc » Sat Jan 19, 2013 3:17 am

This is my first walker, does anyone put swiches on the bottom of the feet? It seems like that would be a handy way to smooth the gait and would make a nice don't walk off the ledge safety amongst other things...
yugpmoc
 
Posts: 2
Joined: Sat Jan 19, 2013 2:00 am

Re: (inverse)-kinematics

Postby TooManySecrets » Sat Jan 19, 2013 8:19 am

I am working on pressure sensors on the feet to be able to walk anywhere.
For this im still waiting for the 2nd batch of my metal gear servos and im allready working on the arduino code for it to walk around using the ping sensor.
Image
TooManySecrets
 
Posts: 79
Joined: Mon Jan 14, 2013 5:02 pm

Re: (inverse)-kinematics

Postby distantcam » Sun Jan 20, 2013 4:45 am

Ok, so after finishing my hexy and playing with him yesterday, today I sat down to do some kinematics.

I measured the pieces in the shape files and came up with the following measurements.

Image

There's a tool for Windows called RoboAnalyzer that I used to play around with the values.

The Denavit-Hartenberg parameters for the arm are as follows:

Image

And the details for the inverse kinematics screen are:

Image
distantcam
 
Posts: 26
Joined: Thu Oct 18, 2012 2:25 am

Re: (inverse)-kinematics

Postby rpcook » Sun Jan 20, 2013 9:47 pm

I've implemented the IK solution (in a Python PoMoCo move) for the lower two leg joints and taken some measurements here. Problem seems to be with non-linear servo positioning, perhaps this could be calibrated out?

Given this success I'm pretty confident that you can get a closed form solution for positioning the whole leg, given that the hip joint is orthogonal to the other two servos. My interest here is a learning perspective, so I'm keen to get to these answers from first principles. How's anyone else doing implementing some IK control?
Rob
A record of my exploits and musings with Hexy and Sparki: http://robcook.eu, content available under a Creative Commons license.
rpcook
 
Posts: 121
Joined: Tue Sep 04, 2012 6:42 pm
Location: Luton, UK

Re: (inverse)-kinematics

Postby rpcook » Fri Feb 08, 2013 10:02 pm

I rather pleased to say that I have finished my (initial) IK code project. I'll write it up shortly and post the maths and code for people to get their teeth into. What this enables is placement of the feet into any position as defined in a hexy-body centric co-ordinate system. I've added some code to allow Hexy to move his body in the x, y and z directions about a fixed set of feet positions on the ground. I haven't gotten around to including any body rotation yet, but this is just some 3D co-ordinate transforms.

All of these functions are currently in a Moves file, rather than having the functions built into the robot.py hexapod class. A project for another day I feel.
Rob
A record of my exploits and musings with Hexy and Sparki: http://robcook.eu, content available under a Creative Commons license.
rpcook
 
Posts: 121
Joined: Tue Sep 04, 2012 6:42 pm
Location: Luton, UK

Next

Return to Projects and Upgrades

Who is online

Users browsing this forum: No registered users and 4 guests

cron