Introduction: Make a Robot With Camera Color Recognition

Hello! This is for group 18+.

This instructable will walk you through building a robot with color recognition using a camera and a servo. The robot i will build has servos for arms also, but they aren't necessary. Use your imagination on how you want to build your robot.

You may not be able to find the same shell. So I suggest visiting a thrift store and find a robot to use as a shell. Pick one that will suit your needs.

Here are the parts used in this robot:

The software is EZ-Builder, available here: http://www.ez-robot.com/EZ-Builder

I suggest watching the video before attempting to build your robot. That will give you an idea of what to expect in the next steps.

 

Step 1: Get the Hardware

I always hook up the hardware to the circuit board to verify it works before i build a robot. In this step, i connect the servos to the board, and simply make them move.

Yay it works!

 

Step 2: Take Apart Your Webcam

The webcam will need to be taken apart and inserted into the head.



Step 3: Take Apart Your Robot Shell

The robot shell will need to be disassembled to fit the parts.

Step 4: Attach Camera Into Head

Use a hot glue gun and secure the camera inside the head of the robot. Be sure to cut a hole in the plastic for the camera to see through.

The head servo can also be fitted. This servo will allow the head to turn side to side.
 

Step 5: Fit Arms (optional)

I attached servo peices to the arms.

The servos will need to be fitted for the arms also 

Step 6: Assemble the Robot

Put the robot back together and plug the servos into your robot board

Step 7: Setup the Source Code

In this robot, I am using the EZ-B Robot Controller with the EZ-Builder software. The software is available for free at http://www.ez-robot.com/EZ-Builder

Optionally, if you are an advanced user, you can download the EZ-SDK: http://www.ez-robot.com/SDK

If you are not using an EZ-B, then check out its documentation to see how to control the hardware.

The EZ-Builder has built in color recognition, which makes it easy to use for this application.

 

  1.  Download and install EZ-Builder
  2. Select Add Control
  3. Add a  Camera Control
  4. Select Config
  5. Select the Servo Port that your Neck servo (The one that moves the camera) is connected
  6. Select Servo Tracking
  7. Press the Save button
  8. Select the camera choice from the dropdown
  9. Select the Color that you would like to recognize

You should now see a vision of your camera's view. 

When you move your colored object, the servo will move the camera (head) to follow the object.


 

Comments

author
LiveCrafts made it!(author)2015-09-17

Thanks for the links! I LOVE it when people do that!

author
123ralph123 made it!(author)2011-07-08

OKE 100%

author
mary+candy made it!(author)2011-03-27

cool !
voted to you.

About This Instructable

20,774views

29favorites

License:

Bio: I build robots to encourage others to do the same. I believe the future is in robotics and playing a part for the future is ... More »
More by djsures:Control Robot From Android Mobile DeviceBrookstone RoverColor Following AR Parrot Drone
Add instructable to: