Close
0%
0%

Halloween Hex

A large hexapod using a frame from ebay, HXT12K servos from HobbyKing and a Parallax Propeller as the controller.

Similar projects worth following
After seeing Bill Henning and Bajdi on Let's Make Robots build hexapods using kits from ebay, I decided to purchase one myself.
I started building this robot in the early fall of 2014. When my wife initially saw the robot's limbs move, she suggested we place our treat bowl on the robot and use it to serve treats to the neighborhood children.
The robot was not completed in time for Halloween of 2014 but we do plan to use it in 2015.
The video of the test walk shows the robot is currently more of a "bucking bronco" than a food service device. I still have some work to do before Halloween 2015.
I've read many horror stories of voltage regulators burning out with these hexapods. This is why I went with two 15 Amp regulators. With two of these large regulators neither one should get very hot.

Here's a video of the hexapod with its newly working eyes.

I used pre-existing "objects" (Propeller version of libraries) for the servo pulse generation (produced by one cog). I also used the super awesome "F32" floating point object. This object runs in its own cog (one of the eight processors on the Propeller) and acts as a floating point coprocessor. I ended up using two instances of the F32 code (each in its own cog) in order to keep the IK calculations running fast enough to generate the 18 servo angles each 20ms control cycle.I have a smaller hexapod which I had previously writing code for. I used this same code on the larger hexapod but found the large servos don't move the same as the small servos. Apparently the different servos have a different angular range giving identical pulse signals. Obviously the code needs some tuning.

Using the IK formulas posted by a member of Let's Make Robots, I wrote my own inverse kinematics algorithms. It turned out generating the IK angles for the various servos was relatively straight forward, what gave me trouble was calculating the location each foot should occupy based on the input from the wireless Wii Nunchuck. This is why I needed two instances of the floating point coprocessor. One would calculate the angles of the servos while the other would calculate the desired location of each foot.

The only processor used on this robot is the Parallax Propeller. The extra PCBs used with the servos are passive and are used as a way to conveniently add power to the servos. The Propeller microcontroller is directly controlling all 22 (18 + 4) servos.

The present code uses seven of the Propeller's eight cogs (processors). All but 588 bytes of the 32K RAM have been used. There are several ways I could reclaim some of this memory so I believe I could still add some obstacle avoiding algorithms to the program.

I think this is a great project to show what the Propeller can do but I think I'm getting close to maxing out the microcontroller's resources.

I personally really enjoy this sort of programming (inverse kinematics) but I will confess to feeling like my brain was about to explode on more than one occasion.

This has been in immensely fun project so far. I have had other commitments which have lately prevented my completing the programming this robot deserves. I hope to make time to complete the programming soon.

Update of sorts (30 January 2015): This project has been screaming for attention since I've uploaded it to hackaday.io. I thought I'd add a check list to this section of the project.

1. Animate eyes (a bunch of tasks involving the eyes).

1a. Code to allow arrays to display the eye images and animations. Done 15.01.29 (year.month.day)

1b. Code to drive eye servos aligned with walk direction. Done 15.01.31

1c. Code to add random behavior to eye movement (servos).

1d. Code to add random behavior to eye animations. Done 15.01.31

1e. Code to control eye expressions from Nunchuck. Progress 15.01.31

2. Loctite screws.

2a. The screws holding the servo horns to the servos keep coming loose. The need Loctite.

3. Find place for wireless Wii Nunchuck receiver.

3a. The Nunchuck receiver needs a home. The receiver needs to be accessible since the I2C signals can interfere with loading code to the Propeller's EEPROM (which shares the I2C bus).

4. Install switch securely.

4a. The power switch presently dangles from the back of the hexapod. I'd like to find a good place to mount the switch. The switch should be easy to access so the hexapod can be powered off quickly.

5. Improve general behavior.

5a. Tame the bucking bronco gait. (Some progress has been made on this as of 15.01.29.)

5b. Improve the way the robot waits for commands. Presently the robot robot will sit with legs raised in the air until a command to continue to move is given.

5c. Code transitions to and from an "at ease" state.

5d. Code transition to and from a low power state. Have the robot pull its legs in and rest the majority of the robot's weight on the...

Read more »

View all 16 components

  • Moved "First Walk" Video Here

    Duane Degn03/06/2015 at 20:49 0 comments

    I want to replace the video under the project "DETAILS" with a more recent video so I'm moving the "First Walk" video here.

    I've been working on the programming of the hexapod a lot lately but I don't have anything to show for my efforts yet.

    One thing I've learned it I need to use locktite on nuts and bolts holding this thing together. It doesn't take long for the machine screws to come loose as the hexapod walks.

  • Eyes are Working (Mostly)

    Duane Degn02/01/2015 at 05:42 1 comment

    My robot finally has eyes!

    There were several additions to the code I needed to make to get the eyes to work the way I wanted. One challenge was coding the four servos. The servos pretty much point the eyes in the direction the robot is walking. The eyes initially start looking up but as they move to the side they also move down a bit.

    This video is also used in the "DETAILS" section.

    Besides controlling four more servos, I also needed to write code to display the eyes on the LED arrays. The LED arrays are from ICStation. The LED arrays use a MAX7219 controller.

    The time between blinks is a random about between set maximum and minimum times. The speed of the blink is also random. There's a 10% chance a blink will be a double blink.

    I'd really like to get the eyes to respond to the environment. Ideally, I'd like a sensor which could detect the location of humans and have the robot respond to the humans' presence. I have a couple ideas on how to do this.

    As I mention in the video, I need to get the switch and battery tucked away into better locations.

    I think the eyes give the robot a lot more personality and I like how they look so far. I got the idea of using the LED arrays as eyes from a fellow member of Let's Make Robots, Dickel.

  • Back On the Front Burner

    Duane Degn01/30/2015 at 08:22 0 comments

    I've started working on this project again.

    I just added a long list of tasks towards building the robot.

    I made some progress on getting the eyes to display eye animations. The eye servos are connected and are powered but so far they are held in their center position.

    I've made some progress towards taming the "bucking" observed in the first walk video.

    I'm hopeful I'll have this robot in a "presentable" state within a few days.

View all 3 project logs

Enjoy this project?

Share

Discussions

de∫hipu wrote 09/20/2015 at 08:24 point

Ouch, that's unfortunate. Removing all your content is always a drastic step, and it's difficult to find the proper reaction for that, especially when you just got a whole community on your hands that you have no idea about. Personally, I hope that the new management will straighten some things that made myself remove my content from that forum a year ago.

  Are you sure? yes | no

[deleted]

[this comment has been deleted]

Duane Degn wrote 02/02/2015 at 19:37 point

Thanks. I'm glad you like the eyes. I'm hoping the ability to change the eyes' shape and behaviour, will allow the robot to take on various apparent personalities.

While I think it would be fun to have the robot look scary and threatening, I also want the option of having the robot look friendly and non-threatening.

There's no fun (or humanity) in scaring a two year old child with a robot. I'm hoping the big "puppy" eyes will put small children at ease around the robot. (Not that I want kids physically interacting with the robot. I know from personal experience, the robot's servos are strong enough to hurt a person.)

The threatening eyes will be used with teenagers and adults.

Hopefully I'll be able to program some "personality" into this robot. Having the ability to animate the eyes both with the LEDs and with the servos should make the task of adding personality easier.

  Are you sure? yes | no

de∫hipu wrote 01/23/2015 at 20:29 point

Nice to see the project progressing slowly but surely!

  Are you sure? yes | no

Duane Degn wrote 01/23/2015 at 20:53 point

Thanks. I'm very anxious to get back to work on this project.

Those LEDs NEED animated eyes.

I hope to work on this robot this week.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates