My Quadruped Project

Looking forward to seeing your 'bot!

You’ll like the '645s.

Alan KM6VV

Sorry for taking a while to post the video but I’ve been busy - anyway, here’s the video (it might be a bit noisy because the bottom of the feet haven’t got any rubber caps on them). The motion is the best I’ve managed to get so far and there are some problems (like the robot walking sideways) but I’m working on them :mrgreen:.

Also, here’s the code for making it walk:

[code];Set up initial stance
hservo [p0\2000\200,p1-3000\200,p2-3000\200,p3-2000\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9\2500\200,p10\3000\200,p11\3000\200]
pause 2500

main
;First Step - Top Right and Bottom Left
hservo [p0\2000\200,p1\3000\200,p2-3000\200,p3-2500\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9\2500\200,p10-3000\200,p11\3000\200]
pause 150
hservo [p0\4500\200,p1\3000\200,p2-3000\200,p3-2500\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9-2500\200,p10-3000\200,p11\3000\200]
pause 150
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3-2500\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9-2500\200,p10\3000\200,p11\3000\200]
pause 50
;End of first step

;Second Step - Top Left and Bottom Right
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3-2500\200,p4\3000\200,p5-3000\200,p6-2500\200,p7-3000\200,p8\3000\200,p9\5000\200,p10\3000\200,p11\3000\200]
pause 150
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3\4500\200,p4\3000\200,p5-3000\200,p6-4500\200,p7-3000\200,p8\3000\200,p9\5000\200,p10\3000\200,p11\3000\200]
pause 150
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3\4500\200,p4-3000\200,p5-3000\200,p6-4500\200,p7\3000\200,p8\3000\200,p9\5000\200,p10\3000\200,p11\3000\200]
pause 50
;End of second step

goto main[/code]

It’s Alive! :smiley:

The code is probably quite simple and “primitive” (because I’m not very good at programming and it hasn’t got any offset finder or anything - just simple angles and sequential motion) but I’m working on smoother movement. :mrgreen:

I’ve thought of a name for the robot as well. I call it - NEXUS! 8)

I’ve also been working on a head design for Nexus. What does everyone think of it (and the robot) so far?

P.S. The rectangle with the two holes on either side is the area where the SHARP IR sensor will go (I’m going to try to make it autonomous as well) :mrgreen:.
' Head.jpg

You might want two IR sensors, set looking slightly outward. This will allow generating a heading.

Alan KM6VV

Ok, I’ll do that. :mrgreen:

WOOHOO! 1000 views! :mrgreen:

Hi, um … I’ve got a bit of a problem - as you can see in the previous video, the bottom right leg of the quadrapod is lagging slightly and I’m not sure why. I’ve changed the legs and I’ll upload a video of the motion with the new legs and the code is the same as the one I posted before.

Could someone please provide some advice on the code (if that is the problem) or anything that will help the robot with smoother motion.

Thank you for the help! :mrgreen:

Here’s a video of the motion with the new legs:

What are you powering the 'bot from? A wall wart? make sure it can handle 3 or 4 amps.

Alan KM6VV

I’m using a bench power supply which can give out a maximum of 5 amps.

Slow the walking down quite a bit. Put the bot on a CD spindle and see what the legs are actually doing. :slight_smile:

Looks to me after swapped servo cables.

I tried the CD spindle idea to get it off the ground (well, I didn’t have the CD spindle so I used a vase instead - which worked equally well) and it seemed to be moving fine.

I then realised that I had my angles for the feet the wrong way around and instead of lifting the feet off the ground, it was keeping on the ground (which caused the dragging) so the problem is fixed - thank you for all the help! (The idea to lift it off the ground using the spindle was very helpful :mrgreen: !).

I’ll post a video of the new and improved motion shortly! :smiley:

Sorry for taking some time to post the video:

It’s still walking slightly diagonally but that’s not a major worry at the moment; I’m currently working on the tail and head. I cut out an extra foot for each leg (so there are now two feet per leg) and it helps with the stability of the robot during motion (thank you for that Robot Dude :smiley:!).

It might just be the wire carrying the power to the board adding a little pull as it shuffles along. Edit, no it looks like the rear left leg is moving more horizontally than the others. :frowning:

Please do a longer video, with straight runs, turns, etc., 5 seconds is not much time to evaluate!

(If I recall) Check the angles assigned to each of the legs. This determines (cos law) how much movement in the X-Y (horizontal) plane the legs get.

Alan KM6VV

I’ve been working on the code some more and I’ve also replaced the body servos from HS-645MG’s to HS-422’s and it seems to be working better. Does anyone have any suggestions on how to make the code better for improved movement? At the moment, I’m using simple angles to move the legs in a sequence but is there any other way (by using offset finders and the other stuff like servo positions, etc.)?

Thank you for the help! :smiley:

P.S. This is the current code I’m using:

[code]pause 5000
;Set up initial stance
hservo [p0\2000\200,p1-3000\200,p2-3000\200,p3-2000\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9\2500\200,p10\3000\200,p11\3000\200]
pause 2500

main
;First Step - Top Right and Bottom Left
hservo [p0\2000\200,p1\3000\200,p2\3000\200,p3-2500\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9\2500\200,p10-3000\200,p11-3000\200]
pause 175
hservo [p0\4500\200,p1\3000\200,p2\3000\200,p3-2500\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9-2500\200,p10-3000\200,p11-3000\200]
pause 175
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3-2500\200,p4-3000\200,p5-3000\200,p6-2500\200,p7\3000\200,p8\3000\200,p9-2500\200,p10\3000\200,p11\3000\200]
pause 50
;End of first step

;Second Step - Top Left and Bottom Right
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3-2500\200,p4\3000\200,p5\3000\200,p6-2500\200,p7-3000\200,p8-3000\200,p9\5000\200,p10\3000\200,p11\3000\200]
pause 175
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3\5000\200,p4\3000\200,p5\3000\200,p6-5000\200,p7-3000\200,p8-3000\200,p9\5000\200,p10\3000\200,p11\3000\200]
pause 175
hservo [p0\4500\200,p1-3000\200,p2-3000\200,p3\5000\200,p4-3000\200,p5-3000\200,p6-5000\200,p7\3000\200,p8\3000\200,p9\5000\200,p10\3000\200,p11\3000\200]
pause 50
;End of second step

goto main[/code]