Pages: [1]   Go Down
Author Topic: Inverse Kinematics for Hexapod  (Read 2170 times)
0 Members and 1 Guest are viewing this topic.
India
Offline Offline
Newbie
*
Karma: 1
Posts: 42
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello everyone,

        I'm making a hexapod with 3-DOF leg, i have made the mechanical assemblies. But the confusion is that ho to implement the Kinematics, I searched a lot, bt since i don't have a basic knowledge in kinematics, i'm not getting understood it even i have spent a lot of time for it.  please help me with a code or something like that to make my hexapod work.
Thank you
Logged

the land of sun+snow
Offline Offline
Faraday Member
**
Karma: 159
Posts: 2916
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Start simple. Forget IK, just implement a simple tripod gait to get it to walk. You can
find dozens of examples of tripod gaits on the internet with a search. Once you do
that, you can worry about IK later on, but probably 99% of hexapod builders don't
use IK.
Logged

Belgium
Offline Offline
Sr. Member
****
Karma: 1
Posts: 281
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I recently built a hexapod, well it took me many months to program it smiley I used inverse kinematics, I found the following site helpful -> http://www.engineer-this.com/IK.shtml The IK wasn't that hard to figure out. The biggest problem for me was coding the whole walking gait based on a timer (millis). I didn't want to use the delay function as I wanted to let the micro controller do lots of other things.
You can read about my hexapod on my blog: http://www.bajdi.com/category/bajdupod-996r/
Logged


the land of sun+snow
Offline Offline
Faraday Member
**
Karma: 159
Posts: 2916
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Months? I would think you could get a basic tripod gait going in a day or so. All the legs do exactly
the same thing, just two groups of 3, timed 180 deg out of phase.
Logged

Belgium
Offline Offline
Sr. Member
****
Karma: 1
Posts: 281
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Programming a basic walking gait using servo.write(angle) and then a delay is very easy.
Then you get something like this: https://vimeo.com/61460555

I'm not much of a programmer, the challenge for me was to program it using inverse kinematics and using a timer. That's a lot harder for someone that is new to programming.
A couple of months later I ended up with this:
https://vimeo.com/67994924 
I can now remote control (by using another Arduino as a remote and 2 nRF24L01 modules) it, and make it walk in every direction. With the remote I can let it do preprogrammed "moves". Also has an autonomous obstacle avoiding mode using ultrasonic sensors and with the WiiCamera sensor it can track IR light. I also added 18 leds, 16 of them controlled by 2 shift registers. Mixing all those things in one sketch took me a lot of time to get right. My last sketch is over 1500 lines of code. But I'm sure someone with better programming skills could do it a lot simpler. 
Logged


the land of sun+snow
Offline Offline
Faraday Member
**
Karma: 159
Posts: 2916
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I would always recommend doing the easy thing first, and then try the harder stuff.
Logged

Southeast US
Offline Offline
God Member
*****
Karma: 15
Posts: 683
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Inverse Kinematics can be rather difficult to figure out.  There is usually a significant amount of difficult math involved.  Though you might be able to look it up online as I'm sure someone has worked out at least the basics (Though it might be different with your particular style of servo).

However it is quite easy to approximate them, just by thinking through the basics of how the robot moves and implementing it using basic commands.

If you don't want to use delays, you can set up a scheduler instead and have the software execute that way.  This way you can do other things at the same time.
Logged

Pages: [1]   Go Up
Jump to: